X-Git-Url: https://git.exim.org/exim.git/blobdiff_plain/7482553d06b156505e38b4cb1b72324bcfb62b37..baaa69d91ad081a6920f2e29e800a30c8de0255c:/src/OS/Makefile-Base?ds=sidebyside diff --git a/src/OS/Makefile-Base b/src/OS/Makefile-Base index 4df9451f8..d45524561 100644 --- a/src/OS/Makefile-Base +++ b/src/OS/Makefile-Base @@ -36,7 +36,7 @@ FE = $(FULLECHO) # up-to-date. Then the os-specific source files and the C configuration file # are set up, and finally it goes to the main Exim target. -all: utils exim +all: utils exim dynmodules config: $(EDITME) checklocalmake Makefile os.c config.h version.h version.sh macro.c exim_openssl exim_gnutls: clean exim @@ -245,7 +245,7 @@ macro.c: macro_predef .PHONY: all config utils \ buildauths buildlookups buildpdkim buildrouters \ - buildtransports checklocalmake clean + buildtransports dynmodules checklocalmake clean utils: $(EXIM_MONITOR) exicyclog exinext exiwhat \ @@ -544,7 +544,7 @@ exim: buildlookups buildauths pdkim/pdkim.a \ # The utility for dumping the contents of an exim database -OBJ_DUMPDB = exim_dumpdb.o util-os.o util-store.o +OBJ_DUMPDB = exim_dumpdb.o util-os.o util-store.o util-xtextencode.o exim_dumpdb: $(OBJ_DUMPDB) @echo "$(LNCC) -o exim_dumpdb" @@ -559,7 +559,7 @@ exim_dumpdb: $(OBJ_DUMPDB) # The utility for interrogating/fixing the contents of an exim database -OBJ_FIXDB = exim_fixdb.o util-os.o util-store.o util-md5.o +OBJ_FIXDB = exim_fixdb.o util-os.o util-store.o util-md5.o util-xtextencode.o exim_fixdb: $(OBJ_FIXDB) @echo "$(LNCC) -o exim_fixdb" @@ -574,11 +574,12 @@ exim_fixdb: $(OBJ_FIXDB) # The utility for tidying the contents of an exim database -OBJ_TIDYDB = exim_tidydb.o util-os.o util-store.o +OBJ_TIDYDB = exim_tidydb.o util-os.o util-store.o util-xtextencode.o exim_tidydb: $(OBJ_TIDYDB) @echo "$(LNCC) -o exim_tidydb" - $(FE)$(LNCC) $(CFLAGS) $(INCLUDE) -o exim_tidydb $(LFLAGS) $(OBJ_TIDYDB) \ + $(FE)$(LNCC) $(CFLAGS) $(INCLUDE) -o exim_tidydb $(LFLAGS) \ + $(OBJ_TIDYDB) \ $(LIBS) $(EXTRALIBS) $(DBMLIB) @if [ x"$(STRIP_COMMAND)" != x"" ]; then \ echo $(STRIP_COMMAND) exim_tidydb; \ @@ -589,9 +590,12 @@ exim_tidydb: $(OBJ_TIDYDB) # The utility for building dbm files -exim_dbmbuild: exim_dbmbuild.o +OBJ_DBMBUILD = exim_dbmbuild.o util-xtextencode.o + +exim_dbmbuild: $(OBJ_DBMBUILD) @echo "$(LNCC) -o exim_dbmbuild" - $(FE)$(LNCC) $(CFLAGS) $(INCLUDE) -o exim_dbmbuild $(LFLAGS) exim_dbmbuild.o \ + $(FE)$(LNCC) $(CFLAGS) $(INCLUDE) -o exim_dbmbuild $(LFLAGS) \ + $(OBJ_DBMBUILD) \ $(LIBS) $(EXTRALIBS) $(DBMLIB) @if [ x"$(STRIP_COMMAND)" != x"" ]; then \ echo $(STRIP_COMMAND) exim_dbmbuild; \ @@ -636,6 +640,7 @@ OBJ_MONBIN = util-host_address.o \ util-string.o \ util-tod.o \ util-tree.o \ + util-xtextencode.o \ $(MONBIN) eximon.bin: $(EXIMON_EDITME) eximon $(OBJ_MONBIN) ../exim_monitor/em_version.c \ @@ -794,6 +799,10 @@ util-tree.o: $(HDRS) tree.c @echo "$(CC) -DCOMPILE_UTILITY tree.c" $(FE)$(CC) -c $(CFLAGS) $(INCLUDE) -DCOMPILE_UTILITY -o util-tree.o tree.c +util-xtextencode.o: $(HDRS) xtextencode.c + @echo "$(CC) -DCOMPILE_UTILITY xtextencode.c" + $(FE)$(CC) -c $(CFLAGS) $(INCLUDE) -DCOMPILE_UTILITY -o util-xtextencode.o xtextencode.c + util-os.o: $(HDRS) os.c @echo "$(CC) -DCOMPILE_UTILITY os.c" $(FE)$(CC) -c $(CFLAGS) $(INCLUDE) \ @@ -934,6 +943,18 @@ $(MONBIN): $(HDRS) # Targets for the various libraries that Exim uses. +# Copies of modules built as dynamic-load libraries + +dynmodules: buildlookups buildrouters buildtransports buildauths + rm -fr dynmodules + mkdir dynmodules + for d in lookup router transport auth; do \ + for f in $${d}s/*.so; do \ + [ -e $$f ] && ln $$f dynmodules/`basename $$f .so`_$$d.so; \ + done; \ + done; \ + true + # The lookups library. buildlookups: config @@ -947,6 +968,7 @@ buildlookups: config buildrouters: config @cd routers && $(MAKE) SHELL=$(SHELL) AR="$(AR)" $(MFLAGS) CC="$(CC)" CFLAGS="$(CFLAGS)" \ + CFLAGS_DYNAMIC="$(CFLAGS_DYNAMIC)" \ FE="$(FE)" RANLIB="$(RANLIB)" RM_COMMAND="$(RM_COMMAND)" HDRS="$(PHDRS)" \ INCLUDE="$(INCLUDE) $(IPV6_INCLUDE) $(TLS_INCLUDE)" @echo " " @@ -955,6 +977,7 @@ buildrouters: config buildtransports: config @cd transports && $(MAKE) SHELL=$(SHELL) AR="$(AR)" $(MFLAGS) CC="$(CC)" CFLAGS="$(CFLAGS)" \ + CFLAGS_DYNAMIC="$(CFLAGS_DYNAMIC)" \ FE="$(FE)" RANLIB="$(RANLIB)" RM_COMMAND="$(RM_COMMAND)" HDRS="$(PHDRS)" \ INCLUDE="$(INCLUDE) $(IPV6_INCLUDE) $(TLS_INCLUDE)" @echo " " @@ -963,6 +986,7 @@ buildtransports: config buildauths: config @cd auths && $(MAKE) SHELL=$(SHELL) AR="$(AR)" $(MFLAGS) CC="$(CC)" CFLAGS="$(CFLAGS)" \ + CFLAGS_DYNAMIC="$(CFLAGS_DYNAMIC)" \ FE="$(FE)" RANLIB="$(RANLIB)" RM_COMMAND="$(RM_COMMAND)" HDRS="$(PHDRS)" \ INCLUDE="$(INCLUDE) $(IPV6_INCLUDE) $(TLS_INCLUDE)" @echo " "