14 # this dir relative to top dir
15 thisdir = src/tray-monitor
23 MONITORSRCS = tray-monitor.c tray_conf.c authenticate.c eggmarshalers.c eggstatusicon.c eggtrayicon.c
24 MONITOROBJS = tray-monitor.o tray_conf.o authenticate.o eggmarshalers.o eggstatusicon.o eggtrayicon.o
26 # these are the objects that are changed by the .configure process
29 MONITOR_CPPFLAGS=@TRAY_MONITOR_CPPFLAGS@
30 MONITOR_LDFLAGS=@TRAY_MONITOR_LDFLAGS@ @X_LIBS@ -lX11
32 OPENSSL_INC = @OPENSSL_INC@
33 OPENSSL_LIBS = @OPENSSL_LIBS@
42 $(NO_ECHO)$(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(MONITOR_CPPFLAGS) \
43 $(OPENSSL_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
44 #-------------------------------------------------------------------------
45 all: Makefile bacula-tray-monitor
46 @echo "==== Make of bacula-tray-monitor is good ===="
49 bacula-tray-monitor: $(MONITOROBJS) ../lib/libbac.a
50 $(CXX) $(LDFLAGS) $(MONITOR_LDFLAGS) -L../lib -L../cats -o $@ \
51 $(MONITOROBJS) $(DLIB) -lbac -lm $(LIBS) $(OPENSSL_LIBS)
54 Makefile: $(srcdir)/Makefile.in $(topdir)/config.status
56 && CONFIG_FILES=$(thisdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
59 @$(RMF) bacula-tray-monitor core core.* a.out *.o *.bak *~ *.intpro *.extpro 1 2 3
62 @$(RMF) tags tray-monitor.conf
65 if test $(srcdir) = .; then $(MAKE) realclean; fi
66 (cd $(srcdir); $(RMF) Makefile)
69 if test $(srcdir) = .; then $(MAKE) realclean; fi
70 (cd $(srcdir); $(RMF) Makefile)
73 $(INSTALL_PROGRAM) bacula-tray-monitor $(DESTDIR)$(sbindir)/bacula-tray-monitor
74 @srcconf=tray-monitor.conf; \
75 if test -f ${DESTDIR}${sysconfdir}/$$srcconf; then \
76 destconf=$$srcconf.new; \
77 echo " ==> Found existing $$srcconf, installing new conf file as $$destconf"; \
81 echo "${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf"; \
82 ${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf
85 (cd $(DESTDIR)$(sbindir); $(RMF) bacula-tray-monitor)
86 (cd $(DESTDIR)$(sysconfdir); $(RMF) tray-monitor.conf)
90 # Semi-automatic generation of dependencies:
91 # Use gcc -MM because X11 `makedepend' doesn't work on all systems
92 # and it also includes system headers.
93 # `semi'-automatic since dependencies are generated at distribution time.
96 @$(MV) Makefile Makefile.bak
97 @$(SED) "/^# DO NOT DELETE:/,$$ d" Makefile.bak > Makefile
98 @$(ECHO) "# DO NOT DELETE: nice dependency list follows" >> Makefile
99 @$(CXX) -S -M $(CPPFLAGS) $(MONITOR_CPPFLAGS) -I$(srcdir) -I$(basedir) *.c >> Makefile
100 @if test -f Makefile ; then \
101 $(RMF) Makefile.bak; \
103 $(MV) Makefile.bak Makefile; \
104 echo -e "Something went wrong\n\a"; \
107 # -----------------------------------------------------------------------
108 # DO NOT DELETE: nice dependency list follows