1# 2# Declare the sub-directories to be built here 3# 4 5SUBDIRS = \ 6 $(EOLIST) 7 8# 9# Get the 'head' of the build environment. This includes default targets and 10# paths to tools 11# 12 13ifndef EnvironmentDefined 14include $(APR_WORK)/build/NWGNUhead.inc 15endif 16 17#include $(APR)\build\NWGNUcustom.inc 18 19# 20# build this level's files 21 22# 23# Make sure all needed macro's are defined 24# 25 26# LINK_STATIC = 1 27 28# for now defined here - should finally go into build/NWGNUenvironment.inc 29SQLITE3_INC = $(SQLITE3SDK)/src 30SQLITE3_IMP = $(SQLITE3SDK)/lsqlite3.imp 31SQLITE3_LIB = $(SQLITE3SDK)/lsqlite3.lib 32SQLITE3_NLM = lsqlite3 33 34# 35# These directories will be at the beginning of the include list, followed by 36# INCDIRS 37# 38XINCDIRS += \ 39 $(APR)/include/arch/netware \ 40 $(APR)/include \ 41 $(APU)/include \ 42 $(APU)/include/private \ 43 $(APR) \ 44 $(SQLITE3_INC) \ 45 $(EOLIST) 46 47# 48# These flags will come after CFLAGS 49# 50XCFLAGS += \ 51 $(EOLIST) 52 53# 54# These defines will come after DEFINES 55# 56XDEFINES += \ 57 -DAPU_DSO_MODULE_BUILD \ 58 -DAPU_HAVE_SQLITE3=1 \ 59 $(EOLIST) 60 61# 62# These flags will be added to the link.opt file 63# 64XLFLAGS += \ 65 $(EOLIST) 66 67ifdef LINK_STATIC 68XLFLAGS += \ 69 -l $(SQLITE3SDK) \ 70 $(EOLIST) 71endif 72 73# 74# These values will be appended to the correct variables based on the value of 75# RELEASE 76# 77ifeq "$(RELEASE)" "debug" 78XINCDIRS += \ 79 $(EOLIST) 80 81XCFLAGS += \ 82 $(EOLIST) 83 84XDEFINES += \ 85 $(EOLIST) 86 87XLFLAGS += \ 88 $(EOLIST) 89endif 90 91ifeq "$(RELEASE)" "noopt" 92XINCDIRS += \ 93 $(EOLIST) 94 95XCFLAGS += \ 96 $(EOLIST) 97 98XDEFINES += \ 99 $(EOLIST) 100 101XLFLAGS += \ 102 $(EOLIST) 103endif 104 105ifeq "$(RELEASE)" "release" 106XINCDIRS += \ 107 $(EOLIST) 108 109XCFLAGS += \ 110 $(EOLIST) 111 112XDEFINES += \ 113 $(EOLIST) 114 115XLFLAGS += \ 116 $(EOLIST) 117endif 118 119# 120# These are used by the link target if an NLM is being generated 121# This is used by the link 'name' directive to name the nlm. If left blank 122# TARGET_nlm (see below) will be used. 123# 124NLM_NAME = dbdsqli3 125 126# 127# This is used by the link '-desc ' directive. 128# If left blank, NLM_NAME will be used. 129# 130NLM_DESCRIPTION = Apache Portability Runtime Library $(VERSION_STR) DBD SQLite3 Driver Module 131 132# 133# This is used by the '-threadname' directive. If left blank, 134# NLM_NAME Thread will be used. 135# 136NLM_THREAD_NAME = dbdsqli3 137 138# 139# If this is specified, it will override VERSION value in 140# $(AP_WORK)\build\NWGNUenvironment.inc 141# 142NLM_VERSION = 143 144# 145# If this is specified, it will override the default of 64K 146# 147NLM_STACK_SIZE = 8192 148 149 150# 151# If this is specified it will be used by the link '-entry' directive 152# 153NLM_ENTRY_SYM = 154 155# 156# If this is specified it will be used by the link '-exit' directive 157# 158NLM_EXIT_SYM = 159 160# 161# If this is specified it will be used by the link '-check' directive 162# 163NLM_CHECK_SYM = 164 165# 166# If these are specified it will be used by the link '-flags' directive 167# 168NLM_FLAGS = 169 170# 171# If this is specified it will be linked in with the XDCData option in the def 172# file instead of the default of $(NWOS)/apache.xdc. XDCData can be disabled 173# by setting APACHE_UNIPROC in the environment 174# 175XDCDATA = 176 177# 178# If there is an NLM target, put it here 179# 180TARGET_nlm = \ 181 $(OBJDIR)\$(NLM_NAME).nlm \ 182 $(EOLIST) 183 184# 185# If there is an LIB target, put it here 186# 187TARGET_lib = \ 188 $(EOLIST) 189 190# 191# These are the OBJ files needed to create the NLM target above. 192# Paths must all use the '/' character 193# 194FILES_nlm_objs = \ 195 $(OBJDIR)/apr_dbd_sqlite3.o \ 196 $(EOLIST) 197 198# 199# These are the LIB files needed to create the NLM target above. 200# These will be added as a library command in the link.opt file. 201# 202FILES_nlm_libs = \ 203 $(PRELUDE) \ 204 $(EOLIST) 205 206ifeq ($(LINK_STATIC),1) 207FILES_nlm_libs += \ 208 $(SQLITE3_LIB) \ 209 $(EOLIST) 210endif 211 212# 213# These are the modules that the above NLM target depends on to load. 214# These will be added as a module command in the link.opt file. 215# 216FILES_nlm_modules = \ 217 aprlib \ 218 libc \ 219 $(EOLIST) 220 221ifneq ($(LINK_STATIC),1) 222FILES_nlm_modules += \ 223 $(SQLITE3_NLM) \ 224 $(EOLIST) 225endif 226 227# 228# If the nlm has a msg file, put it's path here 229# 230FILE_nlm_msg = 231 232# 233# If the nlm has a hlp file put it's path here 234# 235FILE_nlm_hlp = 236 237# 238# If this is specified, it will override $(NWOS)\copyright.txt. 239# 240FILE_nlm_copyright = 241 242# 243# Any additional imports go here 244# 245FILES_nlm_Ximports = \ 246 @$(APR)/aprlib.imp \ 247 @libc.imp \ 248 apr_dbd_mutex_lock \ 249 apr_dbd_mutex_unlock \ 250 $(EOLIST) 251 252ifneq ($(LINK_STATIC),1) 253FILES_nlm_Ximports += \ 254 @$(SQLITE3_IMP) \ 255 $(EOLIST) 256endif 257 258# 259# Any symbols exported to here 260# 261FILES_nlm_exports = \ 262 apr_dbd_sqlite3_driver \ 263 $(EOLIST) 264 265# 266# These are the OBJ files needed to create the LIB target above. 267# Paths must all use the '/' character 268# 269FILES_lib_objs = \ 270 $(EOLIST) 271 272# 273# implement targets and dependancies (leave this section alone) 274# 275 276libs :: $(OBJDIR) $(TARGET_lib) 277 278nlms :: libs $(TARGET_nlm) 279 280# 281# Updated this target to create necessary directories and copy files to the 282# correct place. (See $(AP_WORK)\build\NWGNUhead.inc for examples) 283# 284install :: nlms FORCE 285 286# 287# Any specialized rules here 288# 289 290# 291# Include the 'tail' makefile that has targets that depend on variables defined 292# in this makefile 293# 294 295include $(APRBUILD)/NWGNUtail.inc 296 297 298 299