From: Guenter Knauf Date: Tue, 8 Mar 2011 18:17:07 +0000 (+0000) Subject: NetWare build overhaul in order to compile on Linux. X-Git-Tag: 2.3.12~268 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=410da19e0dee2676eecf4f7f3b874ee8e9a049b9;p=thirdparty%2Fapache%2Fhttpd.git NetWare build overhaul in order to compile on Linux. More fixes ... git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1079463 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/build/NWGNUenvironment.inc b/build/NWGNUenvironment.inc index b9cab4deeed..941962c48e5 100644 --- a/build/NWGNUenvironment.inc +++ b/build/NWGNUenvironment.inc @@ -209,12 +209,19 @@ CLIB3S = $(METROWERKS)/Novell Support/Metrowerks Support/Libraries/Runtime/mwcrt MATH3S = PLIB3S = $(METROWERKS)/Novell Support/Metrowerks Support/Libraries/MSL C++/MWCPP.lib -# MetroWerks Win32 build flags to create build tool -MWCW_MSL = "$(METROWERKS)/MSL" -MWCW_W32 = "$(METROWERKS)/Win32-x86 Support" -WIN_CFLAGS = -O2 -gccinc -nodefaults -proc 586 -w off -WIN_CFLAGS += -ir $(MWCW_MSL) -ir $(MWCW_W32) -lr $(MWCW_MSL) -lr $(MWCW_W32) -WIN_CFLAGS += -lMSL_All_x86.lib -lkernel32.lib -luser32.lib +ifeq "$(OS)" "Windows_NT" +# MetroWerks Win32 build flags to create build tools +MWCW_MSL = "$(METROWERKS)/MSL" +MWCW_W32 = "$(METROWERKS)/Win32-x86 Support" +HOST_CC = $(WIN_CC) +HOST_CFLAGS = -O2 -gccinc -nodefaults -proc 586 -w off +HOST_CFLAGS += -ir $(MWCW_MSL) -ir $(MWCW_W32) -lr $(MWCW_MSL) -lr $(MWCW_W32) +HOST_CFLAGS += -lMSL_All_x86.lib -lkernel32.lib -luser32.lib +else +# GNUC build flags to create build tools +HOST_CC = gcc +HOST_CFLAGS = -Wall -O2 +endif # Base compile flags # and prefix or precompiled header added here. diff --git a/build/NWGNUmakefile b/build/NWGNUmakefile index 401b3da3d2d..cdf91f53dcf 100644 --- a/build/NWGNUmakefile +++ b/build/NWGNUmakefile @@ -60,19 +60,19 @@ ifneq "$(BUILDTOOL_AS_NLM)" "1" $(NWOS)/chartables.c: dftables.exe $(PCRE)/dftables.c $(FILES_prebuild_headers) @echo $(DL)GEN $@$(DL) - @$< $@ + $< $@ %.exe: $(PCRE)/%.c @echo $(DL)Creating Build Helper $@$(DL) - @$(WIN_CC) $(WIN_CFLAGS) -DHAVE_CONFIG_H $< -o $@ + $(HOST_CC) $(HOST_CFLAGS) -DHAVE_CONFIG_H $< -o $@ $(NWOS)/test_char.h: gen_test_char.exe $(SERVER)/gen_test_char.c @echo $(DL)GEN $@$(DL) - @$< > $@ + $< > $@ %.exe: $(SERVER)/%.c @echo $(DL)Creating Build Helper $@$(DL) - @$(WIN_CC) $(WIN_CFLAGS) -DCROSS_COMPILE $< -o $@ + $(HOST_CC) $(HOST_CFLAGS) -DCROSS_COMPILE $< -o $@ else @@ -91,7 +91,7 @@ endif # chkapr: $(APR)/build/nw_ver.awk $(APR)/include/apr_version.h @echo $(DL)Checking for APR version...$(DL) - @$(AWK) -v WANTED=$(APR_WANTED) -f $^ + $(AWK) -v WANTED=$(APR_WANTED) -f $^ # # You can use this target if all that is needed is to copy files to the diff --git a/build/NWGNUtail.inc b/build/NWGNUtail.inc index 5e263659134..fed7964a0a4 100644 --- a/build/NWGNUtail.inc +++ b/build/NWGNUtail.inc @@ -263,7 +263,7 @@ endif @echo $(DL)-l $(XML)/$(OBJDIR)$(DL)>> $@ @echo $(DL)-l $(SRC)/$(OBJDIR)$(DL)>> $@ @echo $(DL)-nodefaults$(DL)>> $@ - @echo $(DL)-map $(OBJDIR)/$(NLM_NAME).map>> $@ + @echo $(DL)-map $(OBJDIR)/$(NLM_NAME).map$(DL)>> $@ ifneq "$(strip $(XLFLAGS))" "" @echo $(DL)$(XLFLAGS)$(DL)>> $@ endif @@ -271,7 +271,7 @@ ifneq "$(strip $(FILES_nlm_objs))" "" @echo $(DL)$(foreach objfile,$(strip $(FILES_nlm_objs)),$(objfile))$(DL)>> $@ endif ifneq "$(FILES_nlm_libs)" "" - @echo $(foreach libfile, $(notdir $(strip $(FILES_nlm_libs))),-l$(libfile))$(DL)>> $@ + @echo $(DL)$(foreach libfile, $(notdir $(strip $(FILES_nlm_libs))),-l$(libfile))$(DL)>> $@ endif @echo $(DL)-commandfile $(@:.opt=.def)$(DL)>> $@ @echo $(DL)# Do not edit this file - it is created by make!$(DL)> $(@:.opt=.def) @@ -299,7 +299,7 @@ endif ifneq "$(NLM_CHECK_SYM)" "" @echo $(DL)check $(NLM_CHECK_SYM)$(DL)>> $(@:.opt=.def) endif - @echo $(strip $(NLM_FLAGS))$(DL)>> $(@:.opt=.def) + @echo $(DL)$(strip $(NLM_FLAGS))$(DL)>> $(@:.opt=.def) ifneq "$(FILES_nlm_modules)" "" @echo $(DL)module $(foreach module,$(subst $(SPACE),$(COMMA),$(strip $(FILES_nlm_modules))),$(module))$(DL)>> $(@:.opt=.def) endif diff --git a/modules/NWGNUmakefile b/modules/NWGNUmakefile index 3fb88b810fc..0778884df17 100644 --- a/modules/NWGNUmakefile +++ b/modules/NWGNUmakefile @@ -15,9 +15,9 @@ SUBDIRS = \ aaa \ cache \ cluster \ - dav\main \ - dav\fs \ - dav\lock \ + dav/main \ + dav/fs \ + dav/lock \ echo \ examples \ generators \ @@ -53,12 +53,6 @@ SUBDIRS += lua \ endif endif -#If the mod_edir directory exists then build the mod_edir module -ifeq "$(wildcard $(AP_WORK)\modules\mod_edir)" "$(AP_WORK)\modules\mod_edir" -SUBDIRS += mod_edir \ - $(EOLIST) -endif - # Allow the experimental modules to be built if EXPERIMENTAL is defined ifdef EXPERIMENTAL SUBDIRS += experimental \ @@ -77,6 +71,12 @@ SUBDIRS += test \ $(EOLIST) endif +#If the mod_edir directory exists then build the mod_edir module +ifeq "$(wildcard $(AP_WORK)/modules/mod_edir)" "$(AP_WORK)/modules/mod_edir" +SUBDIRS += mod_edir \ + $(EOLIST) +endif + # # Get the 'head' of the build environment. This includes default targets and