2 # Setup needed Tools and Libraries
5 ifeq "$(wildcard $(AP_WORK)\NWGNUcustom.ini)" "$(AP_WORK)\NWGNUcustom.ini"
6 include $(AP_WORK)\NWGNUcustom.ini
7 CUSTOM_INI = $(AP_WORK)\NWGNUcustom.ini
15 # Treat like an include
17 ifndef EnvironmentDefined
20 # simple macros for parsing makefiles
25 SPACE := $(EMPTY) $(EMPTY)
31 # Try and handle case issues
34 NOVELLLIBC = $(NovellLibC)
39 NOVELLLIBC = C:/novell/ndk/libc
42 # This is a placeholder
44 # LDAPSDK = C:/novell/ndk/cldapsdk
47 # This is a placeholder
49 # ZLIBSDK = C:/novell/ndk/zlibsdk
53 METROWERKS = C:\Program Files\Metrowerks\CodeWarrior
56 # If LM_LICENSE_FILE isn't defined, define a variable that can be used to
57 # restart make with it defined
58 ifndef LM_LICENSE_FILE
59 NO_LICENSE_FILE = NO_LICENSE_FILE
63 # Set the Release type that you want to build, possible values are:
65 # debug - full debug switches are set
66 # noopt - normal switches are set (default)
67 # optimized - optimization switches are set
97 ifeq "$(RELEASE)" "debug"
101 ifeq "$(RELEASE)" "noopt"
105 ifeq "$(RELEASE)" "optimized"
110 # Setup compiler information
113 # MetroWerks NLM tools
117 LIB = mwldnlm -type library -w nocmdline
119 NOVI = $(NOVELLLIBC)\imports
121 INCDIRS = $(NOVELLLIBC)\include;$(NOVELLLIBC)\include\nks;$(NOVELLLIBC)\include\winsock;
122 ifneq "$(LDAPSDK)" ""
123 INCDIRS := $(INCDIRS);$(LDAPSDK)/inc
125 ifneq "$(ZLIBSDK)" ""
126 INCDIRS := $(INCDIRS);$(ZLIBSDK)
132 # MetroWerks static Libraries
134 CLIB3S = $(METROWERKS)\Novell Support\Metrowerks Support\Libraries\Runtime\mwcrtl.lib
136 PLIB3S = $(METROWERKS)\Novell Support\Metrowerks Support\Libraries\MSL C++\MWCPP.lib
139 # and prefix or precompiled header added here.
141 # The default flags are as follows:
143 # -c compile only, no link
144 # -nosyspath treat #include <...> like #include "..."
145 # -Cpp_exceptions off disable C++ exceptions
146 # -RTTI off disable C++ run-time typing information
147 # -align 4 align on 4 byte bounderies
148 # -w nocmdline disable command-line driver/parser warnings
149 # -proc PII generate code base on Pentium II instruction set
150 # -inst mmx use MMX extensions (Not used)
152 CFLAGS = -c -nosyspath -Cpp_exceptions off -RTTI off -align 4 -w nocmdline -proc PII
154 # -g generate debugging information
155 # -O0 level 0 optimizations
157 ifeq "$(RELEASE)" "debug"
161 # -O4,p level 4 optimizations, optimize for speed
162 ifeq "$(RELEASE)" "optimized"
166 # -prefix pre_nw.h #include pre_nw.h for all files
168 CFLAGS += -prefix pre_nw.h
171 PATH:=$(PATH);$(METROWERKS)\bin;$(METROWERKS)\Other Metrowerks Tools\Command Line Tools
174 # Declare major project deliverables output directories here
179 ifeq (\, $(findstring \,$(INSTALL)))
186 ifeq (\, $(findstring \,$(INSTALL)))
192 INSTALL = $(AP_WORK)\Dist
193 INSTDIRS = $(AP_WORK)\Dist
196 # Add support for building IPV6 alongside
198 DEFINES += -DNW_BUILD_IPV6
199 INCDIRS := $(NOVELLLIBC)\include\winsock\IPV6;$(INCDIRS)
201 ifneq "$(findstring IPV6,$(OBJDIR))" "IPV6"
202 OBJDIR := $(OBJDIR)_IPV6
205 ifneq "$(findstring IPV6,$(INSTALL))" "IPV6"
206 INSTALL := $(INSTALL)_IPV6
209 ifneq "$(findstring IPV6,$(INSTDIRS))" "IPV6"
210 INSTDIRS := $(INSTDIRS)_IPV6
217 $(INSTALL)\Apache2\include \
218 $(INSTALL)\Apache2\lib \
222 $(INSTALL)\Apache2\bin \
223 $(INSTALL)\Apache2\cgi-bin \
224 $(INSTALL)\Apache2\conf \
225 $(INSTALL)\Apache2\error \
226 $(INSTALL)\Apache2\htdocs \
227 $(INSTALL)\Apache2\icons \
228 $(INSTALL)\Apache2\logs \
229 $(INSTALL)\Apache2\man \
230 $(INSTALL)\Apache2\manual \
231 $(INSTALL)\Apache2\modules \
234 # Declare Command and tool macros here
237 # Os2LibPath is an extra check to see if we are on NT
242 ifeq "$(OS)" "Windows_NT"
245 CHKNOT=cmd /C if not exist
247 DELTREE = cmd /C rd /s/q
252 CHK=command /C if exist
253 CHKNOT=command /C if not exist
261 # Setup base C compiler flags
268 STDMOD = $(AP_WORK)/modules
269 NWOS = $(AP_WORK)/os/netware
270 SERVER = $(AP_WORK)/server
272 APR = $(AP_WORK)/srclib/apr
273 APRUTIL = $(AP_WORK)/srclib/apr-util
274 SUPMOD = $(AP_WORK)/support
275 PCRE = $(AP_WORK)/srclib/pcre
276 APRTEST = $(AP_WORK)/srclib/apr/test
277 HTTPD = $(AP_WORK)/modules/http
278 XML = $(AP_WORK)/srclib/apr-util/xml
284 APRLIB = $(APR)/$(OBJDIR)/aprlib.lib
285 APRUTLIB = $(APRUTIL)/$(OBJDIR)/aprutil.lib
286 STMODLIB = $(STDMOD)/$(OBJDIR)/stdmod.lib
287 PCRELIB = $(PCRE/$(OBJDIR)/pcre.lib
288 NWOSLIB = $(NWOS)/$(OBJDIR)/netware.lib
289 SERVLIB = $(SERVER)/$(OBJDIR)/server.lib
290 HTTPDLIB = $(HTTPD)/$(OBJDIR)/httpd.lib
291 XMLLIB = $(XML)/$(OBJDIR)/xmllib.lib
294 # Additional general defines
297 EnvironmentDefined = 1
298 endif # ifndef EnvironmentDefined
300 # This is always set so that it will show up in lower directories