]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/console/Makefile.in
This commit was manufactured by cvs2svn to create tag
[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 GETTEXT_LIBS = @LIBINTL@
30
31 OPENSSL_INC = @OPENSSL_INC@
32 OPENSSL_LIBS = @OPENSSL_LIBS@
33
34 CONS_INC=@CONS_INC@
35 CONS_LIBS=@CONS_LIBS@
36 CONS_LDFLAGS=@CONS_LDFLAGS@
37
38 .SUFFIXES:      .c .o
39 .PHONY:
40 .DONTCARE:
41
42 # inference rules
43 .c.o:
44         $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(CONS_INC) $(OPENSSL_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
45 #-------------------------------------------------------------------------
46 all: Makefile bconsole @STATIC_CONS@
47         @echo "==== Make of console is good ===="
48         @echo " "
49
50
51 bconsole: $(CONSOBJS) ../lib/libbac.a
52         $(CXX) $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
53               $(DLIB) $(CONS_LIBS)  -lbac -lm $(LIBS) $(GETTEXT_LIBS) \
54               $(OPENSSL_LIBS)
55
56 static-bconsole: $(CONSOBJS) ../lib/libbac.a
57         $(CXX) -static $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
58               $(DLIB) $(CONS_LIBS)  -lbac -lm $(LIBS) $(GETTEXT_LIBS) \
59               $(OPENSSL_LIBS)
60         strip $@
61
62
63 Makefile: $(srcdir)/Makefile.in $(topdir)/config.status
64         cd $(topdir) \
65           && CONFIG_FILES=$(thisdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
66
67 clean:
68         @$(RMF) console bconsole core core.* a.out *.o *.bak *~ *.intpro *.extpro 1 2 3
69         @$(RMF) static-console static-bconsole gmon.out
70
71 realclean: clean
72         @$(RMF) tags console.conf bconsole.conf
73
74 distclean: realclean
75         if test $(srcdir) = .; then $(MAKE) realclean; fi
76         (cd $(srcdir); $(RMF) Makefile)
77
78 devclean: realclean
79         if test $(srcdir) = .; then $(MAKE) realclean; fi
80         (cd $(srcdir); $(RMF) Makefile)
81
82 install: all
83         @if test -f ${DESTDIR}${sbindir}/console; then \
84            echo " "; \
85            echo "Warning!!!  ${DESTDIR}${sbindir}console found."; \
86            echo " console has been renamed bconsole, so console"; \
87            echo " is no longer used, and you might want to delete it."; \
88            echo " "; \
89         fi
90         $(INSTALL_PROGRAM) bconsole $(DESTDIR)$(sbindir)/bconsole
91         @srcconf=bconsole.conf; \
92         if  test -f ${DESTDIR}${sysconfdir}/$$srcconf; then \
93            destconf=$$srcconf.new; \
94            echo "  ==> Found existing $$srcconf, installing new conf file as $$destconf"; \
95         else \
96            destconf=$$srcconf; \
97            if  test -f ${DESTDIR}${sysconfdir}/console.conf; then \
98               echo "Existing console.conf moved to bconsole.conf"; \
99               @$(MV) ${DESTDIR}${sysconfdir}/console.conf ${DESTDIR}${sysconfdir}/bconsole.conf; \
100               destconf=$$srcconf.new; \
101            fi; \
102         fi; \
103         echo "${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf"; \
104         ${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf
105         if test -f static-bconsole; then \
106            $(INSTALL_PROGRAM) static-bconsole $(DESTDIR)$(sbindir)/static-bconsole; \
107         fi
108
109 uninstall:
110         (cd $(DESTDIR)$(sbindir); $(RMF) bconsole static-bconsole)
111         (cd $(DESTDIR)$(sysconfdir); $(RMF) console.conf bconsole.conf bconsole.conf.new)
112
113
114
115 # Semi-automatic generation of dependencies:
116 # Use gcc -MM because X11 `makedepend' doesn't work on all systems
117 # and it also includes system headers.
118 # `semi'-automatic since dependencies are generated at distribution time.
119
120 depend:
121         @$(MV) Makefile Makefile.bak
122         @$(SED) "/^# DO NOT DELETE:/,$$ d" Makefile.bak > Makefile
123         @$(ECHO) "# DO NOT DELETE: nice dependency list follows" >> Makefile
124         @$(CXX) -S -M $(CPPFLAGS) $(CONS_INC) $(OPENSSL_INC) -I$(srcdir) -I$(basedir) *.c >> Makefile
125         @if test -f Makefile ; then \
126             $(RMF) Makefile.bak; \
127         else \
128            $(MV) Makefile.bak Makefile; \
129            echo " ===== Something went wrong in make depend ====="; \
130         fi
131
132 # -----------------------------------------------------------------------
133 # DO NOT DELETE: nice dependency list follows