]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/console/Makefile.in
This commit was manufactured by cvs2svn to create tag
[bacula/bacula] / bacula / src / console / Makefile.in
index 646adb7a6f2e5833e3f1cef1461854da30716687..1ada11c45cd87f8cbe645efb3c644d0ed5337863 100644 (file)
@@ -20,12 +20,17 @@ first_rule: all
 dummy:
 
 #
-CONSSRCS = console.c console_conf.c authenticate.c
-CONSOBJS = console.o console_conf.o authenticate.o
+CONSSRCS = console.c console_conf.c authenticate.c @CONS_SRC@ 
+CONSOBJS = console.o console_conf.o authenticate.o @CONS_OBJ@
 
 # these are the objects that are changed by the .configure process
 EXTRAOBJS = @OBJLIST@
 
+GETTEXT_LIBS = @LIBINTL@
+
+OPENSSL_INC = @OPENSSL_INC@
+OPENSSL_LIBS = @OPENSSL_LIBS@
+
 CONS_INC=@CONS_INC@
 CONS_LIBS=@CONS_LIBS@
 CONS_LDFLAGS=@CONS_LDFLAGS@
@@ -36,20 +41,22 @@ CONS_LDFLAGS=@CONS_LDFLAGS@
 
 # inference rules
 .c.o:
-       $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(CONS_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
+       $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(CONS_INC) $(OPENSSL_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
 #-------------------------------------------------------------------------
-all: Makefile console @STATIC_CONS@
+all: Makefile bconsole @STATIC_CONS@
        @echo "==== Make of console is good ===="
        @echo " "
 
 
-console: $(CONSOBJS) ../lib/libbac.a ../cats/libsql.a
+bconsole: $(CONSOBJS) ../lib/libbac.a
        $(CXX) $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
-             $(LIBS) $(DLIB) $(CONS_LIBS) -lbac -lsql -lm
+             $(DLIB) $(CONS_LIBS)  -lbac -lm $(LIBS) $(GETTEXT_LIBS) \
+             $(OPENSSL_LIBS)
 
-static-console: $(CONSOBJS) ../lib/libbac.a ../cats/libsql.a
-       $(CXX) $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
-             $(LIBS) $(DLIB) $(CONS_LIBS) -lbac -lsql -lm
+static-bconsole: $(CONSOBJS) ../lib/libbac.a
+       $(CXX) -static $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -L../cats -o $@ $(CONSOBJS) \
+             $(DLIB) $(CONS_LIBS)  -lbac -lm $(LIBS) $(GETTEXT_LIBS) \
+             $(OPENSSL_LIBS)
        strip $@
 
 
@@ -58,31 +65,50 @@ Makefile: $(srcdir)/Makefile.in $(topdir)/config.status
          && CONFIG_FILES=$(thisdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
 
 clean:
-       @$(RMF) console core core.* a.out *.o *.bak *~ *.intpro *.extpro 1 2 3
-       @$(RMF) static-console
+       @$(RMF) console bconsole core core.* a.out *.o *.bak *~ *.intpro *.extpro 1 2 3
+       @$(RMF) static-console static-bconsole gmon.out
 
 realclean: clean
-       @$(RMF) tags console.conf
+       @$(RMF) tags console.conf bconsole.conf
 
 distclean: realclean
        if test $(srcdir) = .; then $(MAKE) realclean; fi
-       (cd $(srcdir); $(RMF) Makefile; $(RMF) -r CVS)
+       (cd $(srcdir); $(RMF) Makefile)
+
+devclean: realclean
+       if test $(srcdir) = .; then $(MAKE) realclean; fi
+       (cd $(srcdir); $(RMF) Makefile)
 
 install: all
-       $(INSTALL_SCRIPT) console $(DESTDIR)$(sbindir)/console
-       @srcconf=console.conf; \
+       @if test -f ${DESTDIR}${sbindir}/console; then \
+          echo " "; \
+          echo "Warning!!!  ${DESTDIR}${sbindir}console found."; \
+          echo " console has been renamed bconsole, so console"; \
+          echo " is no longer used, and you might want to delete it."; \
+          echo " "; \
+       fi
+       $(INSTALL_PROGRAM) bconsole $(DESTDIR)$(sbindir)/bconsole
+       @srcconf=bconsole.conf; \
        if  test -f ${DESTDIR}${sysconfdir}/$$srcconf; then \
           destconf=$$srcconf.new; \
           echo "  ==> Found existing $$srcconf, installing new conf file as $$destconf"; \
        else \
           destconf=$$srcconf; \
+          if  test -f ${DESTDIR}${sysconfdir}/console.conf; then \
+             echo "Existing console.conf moved to bconsole.conf"; \
+             @$(MV) ${DESTDIR}${sysconfdir}/console.conf ${DESTDIR}${sysconfdir}/bconsole.conf; \
+             destconf=$$srcconf.new; \
+          fi; \
        fi; \
-       echo "${INSTALL_DATA} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf"; \
-       ${INSTALL_DATA} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf
+       echo "${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf"; \
+       ${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf
+       if test -f static-bconsole; then \
+          $(INSTALL_PROGRAM) static-bconsole $(DESTDIR)$(sbindir)/static-bconsole; \
+       fi
 
 uninstall:
-       (cd $(DESTDIR)$(sbindir); $(RMF) console)
-       (cd $(DESTDIR)$(sysconfdir); $(RMF) console.conf
+       (cd $(DESTDIR)$(sbindir); $(RMF) bconsole static-bconsole)
+       (cd $(DESTDIR)$(sysconfdir); $(RMF) console.conf bconsole.conf bconsole.conf.new)
 
 
 
@@ -95,12 +121,12 @@ depend:
        @$(MV) Makefile Makefile.bak
        @$(SED) "/^# DO NOT DELETE:/,$$ d" Makefile.bak > Makefile
        @$(ECHO) "# DO NOT DELETE: nice dependency list follows" >> Makefile
-       @$(CC) -S -M $(CPPFLAGS) $(XINC) -I$(srcdir) -I$(basedir) $(SQL_INC) *.c >> Makefile
+       @$(CXX) -S -M $(CPPFLAGS) $(CONS_INC) $(OPENSSL_INC) -I$(srcdir) -I$(basedir) *.c >> Makefile
        @if test -f Makefile ; then \
            $(RMF) Makefile.bak; \
        else \
           $(MV) Makefile.bak Makefile; \
-          echo -e "Something went wrong\n\a"; \
+          echo " ===== Something went wrong in make depend ====="; \
        fi
 
 # -----------------------------------------------------------------------