~ubuntu-branches/ubuntu/saucy/ccache/saucy

« back to all changes in this revision

Viewing changes to Makefile.in

  • Committer: Bazaar Package Importer
  • Author(s): Loïc Minier
  • Date: 2010-10-13 17:14:13 UTC
  • mfrom: (5.1.1 sid)
  • Revision ID: james.westby@ubuntu.com-20101013171413-4ehrj1y89huf069u
Tags: 3.0.1-1ubuntu1
* Merge with Debian; remaining changes:
  - Add gcc/g++-4.4 and -4.5 symlinks.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
srcdir=@srcdir@
2
 
VPATH=@srcdir@
3
 
 
4
 
prefix=@prefix@
5
 
exec_prefix=@exec_prefix@
6
 
bindir=@bindir@
7
 
mandir=@mandir@
8
 
INSTALLCMD=@INSTALL@
9
 
 
10
 
CC=@CC@
11
 
CFLAGS=@CFLAGS@ -I.
12
 
EXEEXT=@EXEEXT@
13
 
 
14
 
OBJS= ccache.o mdfour.o hash.o execute.o util.o args.o stats.o \
15
 
        cleanup.o snprintf.o unify.o
16
 
HEADERS = ccache.h mdfour.h
17
 
 
 
1
srcdir = @srcdir@
 
2
VPATH = @srcdir@
 
3
 
 
4
prefix = @prefix@
 
5
exec_prefix = @exec_prefix@
 
6
bindir = @bindir@
 
7
mandir = @mandir@
 
8
datarootdir = @datarootdir@
 
9
installcmd = @INSTALL@
 
10
 
 
11
CC = @CC@
 
12
CFLAGS = @CFLAGS@
 
13
CPPFLAGS = @CPPFLAGS@ -I.
 
14
LDFLAGS = @LDFLAGS@
 
15
EXEEXT = @EXEEXT@
 
16
 
 
17
libs = @LIBS@ -lm
 
18
 
 
19
sources = \
 
20
    ccache.c mdfour.c hash.c execute.c util.c args.c stats.c version.c \
 
21
    cleanup.c snprintf.c unify.c manifest.c hashtable.c hashtable_itr.c \
 
22
    murmurhashneutral2.c hashutil.c getopt_long.c
 
23
all_sources = $(sources) @extra_sources@
 
24
 
 
25
headers = \
 
26
    ccache.h hashtable.h hashtable_itr.h hashtable_private.h hashutil.h \
 
27
    manifest.h mdfour.h murmurhashneutral2.h getopt_long.h
 
28
 
 
29
objs = $(all_sources:.c=.o)
 
30
 
 
31
generated_docs = ccache.1 INSTALL.html manual.html NEWS.html README.html
 
32
 
 
33
files_to_clean = $(objs) ccache$(EXEEXT) *~
 
34
 
 
35
.PHONY: all
18
36
all: ccache$(EXEEXT)
19
37
 
20
 
docs: ccache.1 web/ccache-man.html
21
 
 
22
 
ccache$(EXEEXT): $(OBJS) $(HEADERS)
23
 
        $(CC) $(CFLAGS) -o $@ $(OBJS)
24
 
 
25
 
ccache.1: ccache.yo
26
 
        -yodl2man -o ccache.1 ccache.yo
27
 
 
28
 
web/ccache-man.html: ccache.yo
29
 
        mkdir -p man
30
 
        yodl2html -o web/ccache-man.html ccache.yo
31
 
 
32
 
install: ccache$(EXEEXT) ccache.1
33
 
        ${INSTALLCMD} -d $(DESTDIR)${bindir}
34
 
        ${INSTALLCMD} -m 755 ccache$(EXEEXT) $(DESTDIR)${bindir}
35
 
        ${INSTALLCMD} -d $(DESTDIR)${mandir}/man1
36
 
        ${INSTALLCMD} -m 644 ${srcdir}/ccache.1 $(DESTDIR)${mandir}/man1/
37
 
 
 
38
.PHONY: docs
 
39
docs: $(generated_docs)
 
40
 
 
41
ccache$(EXEEXT): $(objs)
 
42
        $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(objs) $(libs)
 
43
 
 
44
.PHONY: install
 
45
install: all
 
46
        $(installcmd) -d $(DESTDIR)$(bindir)
 
47
        $(installcmd) -m 755 ccache$(EXEEXT) $(DESTDIR)$(bindir)
 
48
        $(installcmd) -d $(DESTDIR)$(mandir)/man1
 
49
        -$(installcmd) -m 644 $(srcdir)/ccache.1 $(DESTDIR)$(mandir)/man1/
 
50
 
 
51
.PHONY: clean
38
52
clean:
39
 
        /bin/rm -f $(OBJS) *~ ccache$(EXEEXT)
40
 
 
41
 
test: test.sh
42
 
        CC='$(CC)' ./test.sh
43
 
 
 
53
        rm -f $(files_to_clean)
 
54
 
 
55
.PHONY: perf
 
56
perf: ccache$(EXEEXT)
 
57
        $(srcdir)/perf.py --ccache ccache$(EXEEXT) $(CC) $(CFLAGS) $(CPPFLAGS) $(srcdir)/ccache.c
 
58
 
 
59
.PHONY: test
 
60
test: ccache$(EXEEXT)
 
61
        CC='$(CC)' $(srcdir)/test.sh
 
62
 
 
63
.PHONY: check
44
64
check: test
45
65
 
 
66
.PHONY: distclean
46
67
distclean: clean
47
 
        /bin/rm -f Makefile config.h config.sub config.log build-stamp config.status
48
 
 
49
 
# FIXME: To fix this, test.sh needs to be able to take ccache from the
50
 
# installed prefix, not from the source dir.
51
 
installcheck: 
52
 
        @echo "WARNING!  This is not really \"installcheck\" yet."
53
 
        $(MAKE) check
 
68
        rm -rf Makefile dev.mk config.h config.log config.status .deps version.c
 
69
 
 
70
.PHONY: installcheck
 
71
installcheck:
 
72
        CCACHE=$(bindir)/ccache $(srcdir)/test.sh
 
73
 
 
74
.c.o:
 
75
        $(CC) $(CFLAGS) $(CPPFLAGS) -c -o $@ $<
 
76
 
 
77
@include_dev_mk@