X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/1adb53e896797c73b5528ee178bd73ff51be2c43..7dde16b48cf5a69da2df4ac143ecf10a85792a06:/projects/rscriptd/Makefile diff --git a/projects/rscriptd/Makefile b/projects/rscriptd/Makefile index da06b50b..4c960db7 100644 --- a/projects/rscriptd/Makefile +++ b/projects/rscriptd/Makefile @@ -13,7 +13,6 @@ SRCS = ./main.cpp \ STGLIBS = scriptexecuter \ conffiles \ logger \ - locker \ crypto \ common @@ -32,7 +31,12 @@ OBJS = $(notdir $(patsubst %.cpp, %.o, $(patsubst %.c, %.o, $(SRCS)))) CXXFLAGS += $(DEFS) $(STGLIBS_INCS) $(SEARCH_DIRS) CFLAGS += $(DEFS) $(STGLIBS_INCS) $(SEARCH_DIRS) -LDFLAGS += -Wl,-E $(STGLIBS_LIBS) + +ifneq ($(OS),darwin) +LDFLAGS += -Wl,-E +endif + +LDFLAGS += $(STGLIBS_LIBS) .PHONY: all clean distclean libs install uninstall all: libs $(PROG) ../../Makefile.conf @@ -68,6 +72,13 @@ install-data: # Install etc mkdir -m $(DIR_MODE) -p $(PREFIX)/etc/rscriptd install -m $(DATA_MODE) -o $(OWNER) ./rscriptd.conf $(PREFIX)/etc/rscriptd/rscriptd.conf +ifeq ($(OS), linux) + install -D -m $(BIN_MODE) -o $(OWNER) ../stargazer/inst/linux/etc/stargazer/OnConnect $(PREFIX)/etc/rscriptd/ + install -D -m $(BIN_MODE) -o $(OWNER) ../stargazer/inst/linux/etc/stargazer/OnDisconnect $(PREFIX)/etc/rscriptd/ +else + install -D -m $(BIN_MODE) -o $(OWNER) ../stargazer/inst/freebsd/etc/stargazer/OnConnect $(PREFIX)/etc/rscriptd/ + install -D -m $(BIN_MODE) -o $(OWNER) ../stargazer/inst/freebsd/etc/stargazer/OnDisconnect $(PREFIX)/etc/rscriptd/ +endif uninstall: uninstall-bin uninstall-data @@ -77,7 +88,8 @@ uninstall-bin: uninstall-data: # Uninstall etc rm -f $(PREFIX)/etc/rscriptd/rscriptd.conf - + rm -f $(PREFIX)/etc/rscriptd/OnConnect + rm -f $(PREFIX)/etc/rscriptd/OnDisconnect ifneq ($(MAKECMDGOALS),distclean) ifneq ($(MAKECMDGOALS),clean)