SRCS = ./main.cpp \
./parser.cpp
-LIBS = -lconffiles \
- -lstg_crypto \
- -lstg_common \
- -lsrvconf
+LIBS = -lstgconffiles \
+ -lstgcrypto \
+ -lstgcommon \
+ -lstgsrvconf
LIBS += -lexpat \
$(LIB_THREAD)
libs:
$(MAKE) -C $(DIR_LIBSRC)
-$(PROG): $(OBJS) $(LIBS)
- $(CC) $^ $(LDFLAGS) -o $(PROG)
+$(PROG): $(OBJS) $(STGLIBS)
+ $(CC) $^ $(LIBS) $(LDFLAGS) -o $(PROG)
clean:
rm -f deps $(PROG) *.o tags *.*~ .OS
install -m $(BIN_MODE) -o $(OWNER) -s $(PROG) $(PREFIX)/usr/sbin/$(PROG)
$(MAKE) -C $(DIR_LIBSRC) install
-install-data:
- # Install etc
- install -m $(DATA_MODE) -o $(OWNER) -D $(ETC_DIR)/sgconf.conf $(PREFIX)/etc/stargazer/sgconf.conf
-
uninstall: uninstall-bin uninstall-data
uninstall-bin:
rm -f $(PREFIX)/usr/sbin/$(PROG)
-uninstall-data:
- # Uninstall etc
- rm -f $(PREFIX)/etc/stargazer/sgconf.conf
-
ifneq ($(MAKECMDGOALS),distclean)
ifneq ($(MAKECMDGOALS),clean)
$(MAKE) -C $(DIR_LIBSRC) includes
@>deps ;\
for file in $(SRCS); do\
- echo "`$(CC) $(CFLAGS) $(SEARCH_DIRS) -MM $$file` Makefile" >> deps ;\
- echo -e '\t$$(CC) -c $$< $(CFLAGS) $(SEARCH_DIRS) $(DEFS)' >> deps ;\
+ echo "`$(CC) $(CXXFLAGS) $(SEARCH_DIRS) -MM $$file` Makefile" >> deps ;\
+ echo -e '\t$$(CC) -c $$< $(CXXFLAGS) $(SEARCH_DIRS) $(DEFS)' >> deps ;\
done