2 # Define our required macro's if not already done.
6 export AP_WORK = $(CURDIR)
10 ifeq "$(wildcard $(AP_WORK)/srclib/apr)" "$(AP_WORK)/srclib/apr"
11 export APR_WORK = $(AP_WORK)/srclib/apr
14 ifneq "$(wildcard $(APR_WORK)/include/apr_version.h)" "$(APR_WORK)/include/apr_version.h"
15 $(error APR_WORK does not point to a valid APR source tree)
19 ifeq "$(wildcard $(AP_WORK)/srclib/apr-util)" "$(AP_WORK)/srclib/apr-util"
20 export APU_WORK = $(AP_WORK)/srclib/apr-util
24 ifeq "$(wildcard $(APR_WORK)/include/apu_version.h)" "$(APR_WORK)/include/apu_version.h"
25 export APU_WORK = $(APR_WORK)
28 ifneq "$(wildcard $(APU_WORK)/include/apu_version.h)" "$(APU_WORK)/include/apu_version.h"
29 $(error APU_WORK does not point to a valid APU source tree)
33 # Declare the sub-directories to be built here
44 # Get the 'head' of the build environment. This includes default targets and
48 include $(AP_WORK)\build\NWGNUhead.inc
51 # build this level's files
54 # Make sure all needed macro's are defined
58 # These directories will be at the beginning of the include list, followed by
65 $(AP_WORK)/modules/aaa/ \
66 $(AP_WORK)/modules/core \
67 $(AP_WORK)/modules/filters/ \
68 $(AP_WORK)/modules/generators/ \
69 $(AP_WORK)/modules/http/ \
70 $(AP_WORK)/modules/loggers/ \
71 $(AP_WORK)/modules/mappers/ \
72 $(AP_WORK)/modules/proxy/ \
73 $(AP_WORK)/modules/ssl/ \
74 $(AP_WORK)/os/NetWare \
75 $(AP_WORK)/server/mpm/NetWare \
81 # These flags will come after CFLAGS
87 # These defines will come after DEFINES
93 # These flags will be added to the link.opt file
99 # These values will be appended to the correct variables based on the value of
102 ifeq "$(RELEASE)" "debug"
116 ifeq "$(RELEASE)" "noopt"
130 ifeq "$(RELEASE)" "release"
145 # These are used by the link target if an NLM is being generated
146 # This is used by the link 'name' directive to name the nlm. If left blank
147 # TARGET_nlm (see below) will be used.
152 # This is used by the link '-desc ' directive.
153 # If left blank, NLM_NAME will be used.
155 NLM_DESCRIPTION = Apache Web Server $(VERSION_STR) $(VERSION_SKT)
158 # This is used by the '-threadname' directive. If left blank,
159 # NLM_NAME Thread will be used.
161 NLM_THREAD_NAME = Apache
164 # This is used by the '-screenname' directive. If left blank,
165 # 'Apache for NetWare' Thread will be used.
167 NLM_SCREEN_NAME = Apache $(VERSION_STR) for NetWare
171 # If this is specified, it will override VERSION value in
172 # $(AP_WORK)\build\NWGNUenvironment.inc
177 # If this is specified, it will override the default of 64K
179 NLM_STACK_SIZE = 65536
183 # If this is specified it will be used by the link '-entry' directive
185 NLM_ENTRY_SYM = _LibCPrelude
188 # If this is specified it will be used by the link '-exit' directive
190 NLM_EXIT_SYM = _LibCPostlude
193 # If this is specified it will be used by the link '-check' directive
195 NLM_CHECK_SYM = _LibCCheckUnload
198 # If these are specified it will be used by the link '-flags' directive
200 NLM_FLAGS = PSEUDOPREEMPTION
203 # If this is specified it will be linked in with the XDCData option in the def
204 # file instead of the default of $(NWOS)/apache.xdc. XDCData can be disabled
205 # by setting APACHE_UNIPROC in the environment
210 # If there is an NLM target, put it here
213 $(OBJDIR)/Apache2.nlm \
217 # If there is an LIB target, put it here
223 # These are the OBJ files needed to create the NLM target above.
224 # Paths must all use the '/' character
227 $(OBJDIR)/buildmark.o \
229 $(OBJDIR)/connection.o \
231 $(OBJDIR)/core_filters.o \
232 $(OBJDIR)/eoc_bucket.o \
233 $(OBJDIR)/eor_bucket.o \
234 $(OBJDIR)/error_bucket.o \
235 $(OBJDIR)/http_core.o \
236 $(OBJDIR)/http_protocol.o \
237 $(OBJDIR)/http_request.o \
238 $(OBJDIR)/byterange_filter.o \
239 $(OBJDIR)/chunk_filter.o \
240 $(OBJDIR)/http_etag.o \
241 $(OBJDIR)/http_filters.o \
245 $(OBJDIR)/mod_authn_core.o \
246 $(OBJDIR)/mod_authz_core.o \
247 $(OBJDIR)/mod_authz_host.o \
248 $(OBJDIR)/mod_alias.o \
249 $(OBJDIR)/mod_dir.o \
250 $(OBJDIR)/mod_env.o \
251 $(OBJDIR)/mod_include.o \
252 $(OBJDIR)/mod_log_config.o \
253 $(OBJDIR)/mod_mime.o \
254 $(OBJDIR)/mod_negotiation.o \
255 $(OBJDIR)/mod_netware.o \
256 $(OBJDIR)/mod_setenvif.o \
258 $(OBJDIR)/mod_watchdog.o \
259 $(OBJDIR)/modules.o \
260 $(OBJDIR)/mpm_common.o \
261 $(OBJDIR)/mpm_netware.o \
263 $(OBJDIR)/protocol.o \
264 $(OBJDIR)/provider.o \
265 $(OBJDIR)/request.o \
266 $(OBJDIR)/scoreboard.o \
268 $(OBJDIR)/util_cfgtree.o \
269 $(OBJDIR)/util_charset.o \
270 $(OBJDIR)/util_cookies.o \
271 $(OBJDIR)/util_debug.o \
272 $(OBJDIR)/util_expr.o \
273 $(OBJDIR)/util_filter.o \
274 $(OBJDIR)/util_md5.o \
275 $(OBJDIR)/util_mutex.o \
276 $(OBJDIR)/util_nw.o \
277 $(OBJDIR)/util_pcre.o \
278 $(OBJDIR)/util_script.o \
279 $(OBJDIR)/util_time.o \
280 $(OBJDIR)/util_xml.o \
284 # Build in mod_nw_ssl if Winsock is being used
285 ifndef USE_STDSOCKETS
286 FILES_nlm_objs += $(OBJDIR)/mod_nw_ssl.o \
291 # These are the LIB files needed to create the NLM target above.
292 # These will be added as a library command in the link.opt file.
299 # These are the modules that the above NLM target depends on to load.
300 # These will be added as a module command in the link.opt file.
302 FILES_nlm_modules = \
308 # If the nlm has a msg file, put it's path here
313 # If the nlm has a hlp file put it's path here
318 # If this is specified, it will override $(NWOS)\copyright.txt.
323 # Any additional imports go here
325 FILES_nlm_Ximports = \
329 GetCurrentAddressSpace \
332 # Don't link with Winsock if standard sockets are being used
333 ifndef USE_STDSOCKETS
334 FILES_nlm_Ximports += @ws2nlm.imp \
339 # Any symbols exported to here
341 FILES_nlm_exports = \
346 # These are the OBJ files needed to create the LIB target above.
347 # Paths must all use the '/' character
353 # implement targets and dependancies (leave this section alone)
356 libs :: $(OBJDIR) $(TARGET_lib)
358 nlms :: libs $(TARGET_nlm)
361 # Updated this target to create necessary directories and copy files to the
362 # correct place. (See $(AP_WORK)\build\NWGNUhead.inc for examples)
364 install :: nlms instscripts FORCE
365 -copy $(OBJDIR)\Apache2.nlm $(INSTALL)\$(BASEDIR)\*.*
366 -copy ABOUT_APACHE $(INSTALL)\$(BASEDIR)\*.*
367 -copy README $(INSTALL)\$(BASEDIR)\*.*
368 -copy STATUS $(INSTALL)\$(BASEDIR)\*.*
369 -copy LICENSE $(INSTALL)\$(BASEDIR)\*.*
370 -copy CHANGES $(INSTALL)\$(BASEDIR)\*.*
371 -copy VERSIONING $(INSTALL)\$(BASEDIR)\*.*
372 -copy support\dbmmanage.in $(INSTALL)\$(BASEDIR)\bin\dbmmanage.pl
373 -copy support\logresolve.pl.in $(INSTALL)\$(BASEDIR)\bin\logresolve.pl
374 -copy support\split-logfile.in $(INSTALL)\$(BASEDIR)\bin\split-logfile.pl
375 -$(AWK) -v BDIR=$(BASEDIR) -v PORT=$(PORT) -v SSLPORT=$(SSLPORT) -v MODSSL=$(WITH_MOD_SSL) -v BSDSKT=$(USE_STDSOCKETS) -f build\mkconfnw.awk docs\conf\httpd.conf.in >$(INSTALL)\$(BASEDIR)\conf\httpd.conf
376 $(CHKNOT) $(INSTALL)\$(BASEDIR)\conf\extra\nul mkdir $(INSTALL)\$(BASEDIR)\conf\extra
377 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-autoindex.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-autoindex.conf
378 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-dav.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-dav.conf
379 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-default.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-default.conf
380 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-info.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-info.conf
381 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-languages.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-languages.conf
382 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-manual.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-manual.conf
383 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-mpm.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-mpm.conf
384 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-multilang-errordoc.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-multilang-errordoc.conf
385 -$(AWK) -v BDIR=$(BASEDIR) -f build\mkconfnw.awk docs\conf\extra\httpd-userdir.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-userdir.conf
386 -$(AWK) -v BDIR=$(BASEDIR) -v PORT=$(PORT) -f build\mkconfnw.awk docs\conf\extra\httpd-vhosts.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-vhosts.conf
387 -$(AWK) -v BDIR=$(BASEDIR) -v SSLPORT=$(SSLPORT) -f build\mkconfnw.awk docs\conf\extra\httpd-ssl.conf.in >$(INSTALL)\$(BASEDIR)\conf\extra\httpd-ssl.conf
388 -copy docs\conf\magic $(INSTALL)\$(BASEDIR)\conf\magic
389 -copy docs\conf\mime.types $(INSTALL)\$(BASEDIR)\conf\mime.types
390 -copy docs\conf\charset.conv $(INSTALL)\$(BASEDIR)\conf\charset.conv
391 -copy docs\cgi-examples\printenv $(INSTALL)\$(BASEDIR)\cgi-bin\printenv.pl
392 @xcopy $(XCOPYSW) docs\error $(INSTALL)\$(BASEDIR)\error
393 @xcopy $(XCOPYSW) docs\docroot $(INSTALL)\$(BASEDIR)\htdocs
394 @xcopy $(XCOPYSW) docs\icons $(INSTALL)\$(BASEDIR)\icons
395 @xcopy $(XCOPYSW) docs\man $(INSTALL)\$(BASEDIR)\man
396 @xcopy $(XCOPYSW) docs\manual $(INSTALL)\$(BASEDIR)\manual
399 -copy $(subst /,\,$(AP_WORK))\include\*.h $(INSTALL)\$(BASEDIR)\include\*.*
400 -copy $(subst /,\,$(AP_WORK))\os\netware\*.h $(INSTALL)\$(BASEDIR)\include\*.*
401 -copy $(subst /,\,$(NWOS))\*.imp $(INSTALL)\$(BASEDIR)\lib\*.*
402 -copy $(subst /,\,$(APR))\include\*.h $(INSTALL)\$(BASEDIR)\include\*.*
403 -copy $(subst /,\,$(APRUTIL))\include\*.h $(INSTALL)\$(BASEDIR)\include\*.*
404 -copy $(subst /,\,$(APR))\*.imp $(INSTALL)\$(BASEDIR)\lib\*.*
405 -copy $(subst /,\,$(NWOS))\*.xdc $(INSTALL)\$(BASEDIR)\lib\*.*
408 $(MAKE) -C server -f NWGNUMakefile
409 $(MAKE) -C $(PCRESDK) -f NWGNUMakefile
410 $(CHKNOT) $(PREBUILD_INST)\nul mkdir $(PREBUILD_INST)
411 -copy $(AP_WORK)\server\$(OBJDIR)\*.nlm $(PREBUILD_INST)\*.*
412 -copy $(PCRESDK)\$(basename $(OBJDIR))\*.nlm $(PREBUILD_INST)\*.*
415 # Any specialized rules here
418 vpath %.c server:modules/arch/netware:modules/http:modules/aaa:modules/mappers
419 vpath %.c modules/generators:modules/metadata:modules/filters:modules/loggers
420 vpath %.c modules/core:os/netware:server/mpm/netware:$(PCRESRC)
423 # Include the 'tail' makefile that has targets that depend on variables defined
427 include $(AP_WORK)\build\NWGNUtail.inc
429 include $(AP_WORK)\build\NWGNUscripts.inc