]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/console/Makefile.in
- Add Scratch to PoolType in PostgreSQL make...tables and do not
[bacula/bacula] / bacula / src / console / Makefile.in
1 #
2 #  Version $Id$
3 #
4 @MCOMMON@
5
6 srcdir =        .
7 VPATH =         .
8 .PATH:          .
9
10 # one up
11 basedir = ..
12 # top dir
13 topdir = ../..
14 # this dir relative to top dir
15 thisdir = src/console
16
17 DEBUG=@DEBUG@
18
19 first_rule: all
20 dummy:
21
22 #
23 CONSSRCS = console.c console_conf.c authenticate.c @CONS_SRC@ 
24 CONSOBJS = console.o console_conf.o authenticate.o @CONS_OBJ@
25
26 # these are the objects that are changed by the .configure process
27 EXTRAOBJS = @OBJLIST@
28
29 OPENSSL_INC = @OPENSSL_INC@
30 OPENSSL_LIBS = @OPENSSL_LIBS@
31
32 CONS_INC=@CONS_INC@
33 CONS_LIBS=@CONS_LIBS@
34 CONS_LDFLAGS=@CONS_LDFLAGS@
35
36 .SUFFIXES:      .c .o
37 .PHONY:
38 .DONTCARE:
39
40 # inference rules
41 .c.o:
42         $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(CONS_INC) $(OPENSSL_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
43 #-------------------------------------------------------------------------
44 all: Makefile bconsole @STATIC_CONS@
45         @echo "==== Make of console is good ===="
46         @echo " "
47
48
49 bconsole: $(CONSOBJS) ../lib/libbac.a
50         $(CXX) $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
51               $(DLIB) $(CONS_LIBS)  -lbac -lm $(LIBS) $(OPENSSL_LIBS)
52
53 static-bconsole: $(CONSOBJS) ../lib/libbac.a
54         $(CXX) -static $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
55               $(DLIB) $(CONS_LIBS)  -lbac -lm $(LIBS) $(OPENSSL_LIBS)
56         strip $@
57
58
59 Makefile: $(srcdir)/Makefile.in $(topdir)/config.status
60         cd $(topdir) \
61           && CONFIG_FILES=$(thisdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
62
63 clean:
64         @$(RMF) console bconsole core core.* a.out *.o *.bak *~ *.intpro *.extpro 1 2 3
65         @$(RMF) static-console static-bconsole gmon.out
66
67 realclean: clean
68         @$(RMF) tags console.conf bconsole.conf
69
70 distclean: realclean
71         if test $(srcdir) = .; then $(MAKE) realclean; fi
72         (cd $(srcdir); $(RMF) Makefile; $(RMF) -r CVS)
73
74 devclean: realclean
75         if test $(srcdir) = .; then $(MAKE) realclean; fi
76         (cd $(srcdir); $(RMF) Makefile)
77
78 install: all
79         @if test -f ${DESTDIR}${sbindir}/console; then \
80            echo " "; \
81            echo "Warning!!!  ${DESTDIR}${sbindir}console found."; \
82            echo " console has been renamed bconsole, so console"; \
83            echo " is no longer used, and you might want to delete it."; \
84            echo " "; \
85         fi
86         $(INSTALL_PROGRAM) bconsole $(DESTDIR)$(sbindir)/bconsole
87         @srcconf=bconsole.conf; \
88         if  test -f ${DESTDIR}${sysconfdir}/$$srcconf; then \
89            destconf=$$srcconf.new; \
90            echo "  ==> Found existing $$srcconf, installing new conf file as $$destconf"; \
91         else \
92            destconf=$$srcconf; \
93            if  test -f ${DESTDIR}${sysconfdir}/console.conf; then \
94               echo "Existing console.conf moved to bconsole.conf"; \
95               @$(MV) ${DESTDIR}${sysconfdir}/console.conf ${DESTDIR}${sysconfdir}/bconsole.conf; \
96               destconf=$$srcconf.new; \
97            fi; \
98         fi; \
99         echo "${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf"; \
100         ${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf
101         if test -f static-bconsole; then \
102            $(INSTALL_PROGRAM) static-bconsole $(DESTDIR)$(sbindir)/static-bconsole; \
103         fi
104
105 uninstall:
106         (cd $(DESTDIR)$(sbindir); $(RMF) bconsole static-bconsole)
107         (cd $(DESTDIR)$(sysconfdir); $(RMF) console.conf bconsole.conf bconsole.conf.new)
108
109
110
111 # Semi-automatic generation of dependencies:
112 # Use gcc -MM because X11 `makedepend' doesn't work on all systems
113 # and it also includes system headers.
114 # `semi'-automatic since dependencies are generated at distribution time.
115
116 depend:
117         @$(MV) Makefile Makefile.bak
118         @$(SED) "/^# DO NOT DELETE:/,$$ d" Makefile.bak > Makefile
119         @$(ECHO) "# DO NOT DELETE: nice dependency list follows" >> Makefile
120         @$(CXX) -S -M $(CPPFLAGS) $(CONS_INC) -I$(srcdir) -I$(basedir) *.c >> Makefile
121         @if test -f Makefile ; then \
122             $(RMF) Makefile.bak; \
123         else \
124            $(MV) Makefile.bak Makefile; \
125            echo " ===== Something went wrong in make depend ====="; \
126         fi
127
128 # -----------------------------------------------------------------------
129 # DO NOT DELETE: nice dependency list follows