14 # this dir relative to top dir
15 thisdir = src/gnome2-console
22 GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@
23 GNOMEUI_LIBS = @GNOMEUI_LIBS@
24 GNOME_LIBDIR = @GNOME_LIBDIR@
25 GNOME_LIBS = @GNOME_LIBS@
29 CONSSRCS = console.c console_conf.c authenticate.c support.c interface.c callbacks.c \
31 CONSOBJS = console.o console_conf.o authenticate.o support.o interface.o callbacks.o \
34 # these are the objects that are changed by the .configure process
37 #CONS_INC=@CONS_INC@ $(GNOME_INCLUDEDIR)
38 #CONS_LIBS=@CONS_LIBS@ $(GNOME_LIBS)
39 #CONS_LDFLAGS=@CONS_LDFLAGS@ $(GNOME_LIBDIR) $(GNOMEUI_LIBS)
41 CONS_INC=$(GNOME_INCLUDEDIR)
42 CONS_LIBS=$(GNOME_LIBS) $(OPENSSL_LIBS)
43 CONS_LDFLAGS=$(GNOME_LIBDIR) $(GNOMEUI_LIBS)
53 $(NO_ECHO)$(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(CONS_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
54 #-------------------------------------------------------------------------
55 all: Makefile bgnome-console @STATIC_GNOME_CONS@
56 @echo "==== Make of bgnome-console is good ===="
61 mv support.c support.c.orig
62 sed "s%parent = g_object_get_data%parent = \(GtkWidget \*\)g_object_get_data%" support.c.orig >support.c
63 $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) $(CONS_INC) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) $<
65 bgnome-console: Makefile $(CONSOBJS) ../lib/libbaccfg$(DEFAULT_ARCHIVE_TYPE) ../lib/libbac$(DEFAULT_ARCHIVE_TYPE)
66 $(LIBTOOL_LINK) $(CXX) $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -o $@ $(CONSOBJS) \
67 $(LIBS) $(DLIB) $(CONS_LIBS) -lbaccfg -lbac -lm
69 static-console: static-bgnome-console
71 static-bgnome-console: Makefile $(CONSOBJS) ../lib/libbaccfg$(DEFAULT_ARCHIVE_TYPE) ../lib/libbac$(DEFAULT_ARCHIVE_TYPE)
72 $(LIBTOOL_LINK) $(CXX) $(LDFLAGS) $(CONS_LDFLAGS) -L../lib -o $@ $(CONSOBJS) \
73 $(LIBS) $(DLIB) $(CONS_LIBS) -lbaccfg -lbac -lm
76 Makefile: $(srcdir)/Makefile.in $(topdir)/config.status
78 && CONFIG_FILES=$(thisdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
83 clean: @LIBTOOL_CLEAN_TARGET@
84 @$(RMF) bgnome-console core core.* a.out *.o *.bak *~ *.intpro *.extpro 1 2 3
85 @$(RMF) static-bgnome-console gmon.out Makefile.am
89 @$(RM) -rf .deps bgnome-console.conf
92 if test $(srcdir) = .; then $(MAKE) realclean; fi
93 (cd $(srcdir); $(RMF) Makefile)
96 if test $(srcdir) = .; then $(MAKE) realclean; fi
97 (cd $(srcdir); $(RMF) Makefile)
100 @if test -f ${DESTDIR}${sbindir}/gnome-console; then \
102 echo "Warning!!! ${DESTDIR}${sbindir}gnome-console found."; \
103 echo " gnome-console has been renamed bgnome-console, so gnome-console"; \
104 echo " is no longer used, and you might want to delete it."; \
107 $(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) bgnome-console $(DESTDIR)$(sbindir)/bgnome-console
108 @srcconf=bgnome-console.conf; \
109 if test -f ${DESTDIR}${sysconfdir}/$$srcconf; then \
110 destconf=$$srcconf.new; \
111 echo " ==> Found existing $$srcconf, installing new conf file as $$destconf"; \
113 destconf=$$srcconf; \
115 echo "${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf"; \
116 ${INSTALL_CONFIG} $$srcconf ${DESTDIR}${sysconfdir}/$$destconf
117 if test -f static-bgnome-console; then \
118 $(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) static-bgnome-console $(DESTDIR)$(sbindir)/static-bgnome-console; \
122 (cd $(DESTDIR)$(sbindir); $(RMF) bgnome-console static-bgnome-console)
123 (cd $(DESTDIR)$(sysconfdir); $(RMF) bgnome-console.conf bgnome-console.conf.new)
124 (cd $(DESTDIR)$(sbindir); $(RMF) gnome-console static-gnome-console)
125 (cd $(DESTDIR)$(sysconfdir); $(RMF) gnome-console.conf gnome-console.conf.new)
130 # Semi-automatic generation of dependencies:
131 # Use gcc -MM because X11 `makedepend' doesn't work on all systems
132 # and it also includes system headers.
133 # `semi'-automatic since dependencies are generated at distribution time.
136 @$(MV) Makefile Makefile.bak
137 @$(SED) "/^# DO NOT DELETE:/,$$ d" Makefile.bak > Makefile
138 @$(ECHO) "# DO NOT DELETE: nice dependency list follows" >> Makefile
139 @$(CXX) -S -M $(CPPFLAGS) $(XINC) -I$(srcdir) -I$(basedir) $(GNOME_INCLUDEDIR) $(SQL_INC) *.c >> Makefile
140 @if test -f Makefile ; then \
141 $(RMF) Makefile.bak; \
143 $(MV) Makefile.bak Makefile; \
144 echo -e "Something went wrong\n\a"; \
147 # -----------------------------------------------------------------------
148 # DO NOT DELETE: nice dependency list follows