summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--NWGNUmakefile24
-rw-r--r--build/NWGNUenvironment.inc13
-rw-r--r--xml/NWGNUmakefile5
3 files changed, 32 insertions, 10 deletions
diff --git a/NWGNUmakefile b/NWGNUmakefile
index 77a825251..c4d1f10d0 100644
--- a/NWGNUmakefile
+++ b/NWGNUmakefile
@@ -201,6 +201,14 @@ FILES_nlm_libs = \
$(APRXMLLIB) \
$(EOLIST)
+ifdef EXPATSDK
+ifdef EXPAT_LINK_STATIC
+FILES_nlm_libs += \
+ $(EXPAT_LIB) \
+ $(EOLIST)
+endif
+endif
+
#
# These are the modules that the above NLM target depends on to load.
# These will be added as a module command in the link.opt file.
@@ -223,6 +231,14 @@ FILES_nlm_modules += \
$(EOLIST)
endif
+ifdef EXPATSDK
+ifndef EXPAT_LINK_STATIC
+FILES_nlm_modules += \
+ $(EXPAT_NLM) \
+ $(EOLIST)
+endif
+endif
+
#
# If the nlm has a msg file, put it's path here
#
@@ -263,6 +279,14 @@ FILES_nlm_Ximports += \
$(EOLIST)
endif
+ifdef EXPATSDK
+ifndef EXPAT_LINK_STATIC
+FILES_nlm_Ximports += \
+ @$(EXPAT_IMP) \
+ $(EOLIST)
+endif
+endif
+
#
# Any symbols exported to here
#
diff --git a/build/NWGNUenvironment.inc b/build/NWGNUenvironment.inc
index 876781f16..dd765c6a8 100644
--- a/build/NWGNUenvironment.inc
+++ b/build/NWGNUenvironment.inc
@@ -51,22 +51,23 @@ endif
ifdef EXPATSDK
ifeq "$(wildcard $(EXPATSDK)/include/expat.h)" "$(EXPATSDK)/include/expat.h"
-EXPATINC = $(EXPATSRC)/include
-EXPATIMP = $(EXPATSRC)/imports/expatlbc.imp
-EXPATNLM = EXPATLBC
+EXPAT_IMP = $(EXPATSDK)/imports/expatlbc.imp
+EXPAT_INC = $(EXPATSDK)/include
+EXPAT_LIB = $(EXPATSDK)/lib/expat.lib
+EXPAT_NLM = EXPATLBC
else
$(error EXPATSDK does not point to a valid EXPAT SDK)
endif
endif
ifdef EXPATSRC
ifeq "$(wildcard $(EXPATSRC)/lib/xmlparse.c)" "$(EXPATSRC)/lib/xmlparse.c"
-EXPATINC = $(EXPATSRC)/lib
-EXPATLIB = $(EXPATSRC)/lib/$(OBJDIR)/expat.lib
+EXPAT_INC = $(EXPATSRC)/lib
+EXPAT_LIB = $(EXPATSRC)/lib/$(OBJDIR)/expat.lib
else
$(error EXPATSRC does not point to a valid EXPAT source tree)
endif
endif
-ifndef EXPATINC
+ifndef EXPAT_INC
$(error neither EXPATSDK nor EXPATSRC defined - cant compile without EXPAT SDK or source tree)
endif
diff --git a/xml/NWGNUmakefile b/xml/NWGNUmakefile
index 8a8df2c94..4cdf300cd 100644
--- a/xml/NWGNUmakefile
+++ b/xml/NWGNUmakefile
@@ -52,7 +52,7 @@ endif
# INCDIRS
#
XINCDIRS += \
- $(EXPATINC) \
+ $(EXPAT_INC) \
$(APR)/include \
$(APR)/include/private \
$(APR)/include/arch/NetWare \
@@ -274,10 +274,7 @@ nlms :: libs $(TARGET_nlm)
#
install :: nlms FORCE
-#del_file = $(shell if exist $(subst /,\,$(1)) $(DEL) $(subst /,\,$(1)))
-
clean ::
-# $(foreach file,$(EXPAT_prebuild_headers),$(call del_file,$(file)))
$(foreach file,$(EXPAT_prebuild_headers),$(shell if exist $(subst /,\,$(file)) $(DEL) $(subst /,\,$(file))))
#