-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile.in
More file actions
101 lines (73 loc) · 2.61 KB
/
Makefile.in
File metadata and controls
101 lines (73 loc) · 2.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
PACKAGE_NAME = @PACKAGE_NAME@
HELPER = private
ENCODER = tools/encoder
TESTPROG = tests/test
CC = @CXX@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
MKDIR_P = @MKDIR_P@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @exec_prefix@/lib
docdir = @docdir@
datarootdir = @datarootdir@
mandir = @mandir@
CFLAGS = @OPENSSL_CFLAGS@ @CURL_CFLAGS@ -Wall -O2 -std=c++2a
LFLAGS = @OPENSSL_LIBS@ @CURL_LIBS@
TESTCFLAGS = @CHECK_CFLAGS@ $(CFLAGS)
TESTLFLAGS = @CHECK_LIBS@ $(LFLAGS)
OBJECTS = private-method.o acquire-method.o stanza.o config-file.o \
uri.o hash.o hex.o fetch.o filter.o cipher.o origin.o random.o
TESTSOURCES = $(wildcard tests/*.cpp)
TESTOBJECTS = $(OBJECTS) $(TESTSOURCES:%.cpp=%.o)
MAN_PAGES = man/apt-private-prepare.1.gz man/apt-transport-private.8.gz \
man/private.conf.5.gz
AUX_FILES = Makefile configure aclocal.m4 install-sh config.h* *.log \
*.status *.cache
all: $(HELPER) $(TESTPROG) $(ENCODER) $(MAN_PAGES)
include $(wildcard *.d */*.d)
$(HELPER): main.o $(OBJECTS)
$(QUIET_LD) $(CC) $^ -o $@ $(LFLAGS)
$(ENCODER): tools/encoder.o $(OBJECTS)
$(QUIET_LD) $(CC) $^ -o $@ $(LFLAGS)
%.o: %.cpp
$(QUIET_CC) $(CC) -MMD -MP -c $< -o $@ $(CFLAGS)
tests/%.o: tests/%.cpp
$(QUIET_CC) $(CC) -MMD -MP -c $< -o $@ $(TESTCFLAGS)
$(TESTPROG): $(TESTOBJECTS)
$(QUIET_LD) $(CC) $^ -o $@ $(TESTLFLAGS)
test: $(TESTPROG)
$(TESTPROG)
man/%.gz: man/%
$(QUIET_GEN) cat $< | gzip -f >$@
install: install-man-pages
$(MKDIR_P) $(bindir) $(libdir)/apt/methods $(docdir)/$(PACKAGE_NAME)/example
$(INSTALL_PROGRAM) tools/encoder -T $(bindir)/apt-private-prepare
$(INSTALL_PROGRAM) private $(libdir)/apt/methods
$(INSTALL_DATA) tests/files/private.conf $(docdir)/$(PACKAGE_NAME)/example
install-man-pages:
$(MKDIR_P) $(mandir)/man1 $(mandir)/man5 $(mandir)/man8
$(INSTALL_DATA) man/apt-private-prepare.1.gz $(mandir)/man1
$(INSTALL_DATA) man/private.conf.5.gz $(mandir)/man5
$(INSTALL_DATA) man/apt-transport-private.8.gz $(mandir)/man8
uninstall: uninstall-man-pages
$(RM) $(bindir)/apt-private-prepare
$(RM) $(libdir)/apt/methods/private
$(RM) $(docdir)/example
uninstall-man-pages:
$(RM) $(mandir)/man1/apt-private-prepare.1.gz
$(RM) $(mandir)/man5/private.conf.5.gz
$(RM) $(mandir)/man8/apt-transport-private.8.gz
clean:
$(RM) $(HELPER) $(ENCODER) $(TESTPROG) *.o *.d */*.o */*.d man/*.gz
clean-aux:
$(RM) -r $(AUX_FILES)
distclean: clean clean-aux
ifndef V
QUIET_CC = @echo " CC $@";
QUIET_LD = @echo " CCLD $@";
QUIET_AR = @echo " AR $@";
QUIET_GEN = @echo " GEN $@";
endif