# -*- Mode: makefile -*- # # Settings: default configuration paramters for JVM Accelerator # # ########################################################################### # # Source Server, Target Server # ########################################################################### connection.driver.default = oci8 connection.driver = $(connection.driver.default) source.server.connection.string = jdbc:oracle:$(connection.driver):@$(source.server) target.server.connection.string = jdbc:oracle:$(connection.driver):@$(target.server) ########################################################################### # # LOADJAVA. We use loadjava tool to upload java classes to the server. # We also use loadjava to upload the DLLs to the server. # ########################################################################### loadjava.basic.options = $(JA_VERBOSE) -$(connection.driver) -resolve loadjava.connection = \ -user $(SCHEMA)/$(PASSWORD)$(loadjava.opt.database.suffix) loadjava.options = $(loadjava.basic.options) $(loadjava.connection) loadjava = loadjava $(loadjava.options) drop.java.source.command = drop java source $@ dropjava = dropjava ########################################################################### # # : these must be platform-specific definitions. # if you see platform_xxx in the project's makefile, # then it means jaccelerator's home directory does not provide # Settings[_arch[_os]].properties file where "os" and "arch" # are as returned by System.getProperty() ########################################################################### file.extension.dll = UNDEFINED_platform_file_extension_dll file.extension.obj = UNDEFINED_platform_file_extension_obj library.prefix = UNDEFINED_platform_library_prefix LINK_COMMAND = UNDEFINED_PLATFORM_LINK_COMMAND EXPORTS_COMMAND = ########################################################################### # # C compiler flags # ########################################################################### c.compile.flags.platform = c.compile.flags.aurora = \ -D_REENTRANT -DEO_SUPPRESS_DEBUG -DEO_SUPPRESS_TRACE \ -DEO_SUPPRESS_DEBUG -DEO_SUPPRESS_TRACE CPPFLAGS = CC = gcc CFLAGS = $< -o $@ $(c.compile.include) $(c.compile.flags.platform) $(c.compile.flags.aurora) COMPILE.c = $(CC) $(CFLAGS) $(CPPFLAGS) -c ccompile.c.command = $(COMPILE.c) c.compile.include = -I. -I$(JA_HOME) ########################################################################### # # java home # ########################################################################### java.options = -ms256M -mx1024M java = $(JAVA_HOME)/bin/java $(java.options) javac = $(JAVA_HOME)/bin/javac jar = $(JAVA_HOME)/bin/jar jvmc.java.classpath = .$(path.separator)$(JA_HOME)\ $(path.separator)$(JA_LIBS_HOME)/javavm/lib/jaccelerator.zip\ $(path.separator)$(JA_LIBS_HOME)/javavm/lib/aurora_ncomp_gen.zip\ $(path.separator)$(JA_LIBS_HOME)/javavm/lib/ncomp.zip\ $(path.separator)$(JA_LIBS_HOME)/jdbc/lib/ojdbc5.jar\ $(path.separator)$(JA_LIBS_HOME)/sqlj/lib/translator.zip\ $(path.separator)$(JAVA_HOME_CLASSPATH) compile-for-server.javac.classpath = .$(path.separator)$(JA_HOME)\ $(path.separator)$(JA_LIBS_HOME)/javavm/lib/aurora.zip\ $(path.separator)$(JA_LIBS_HOME)/jdbc/lib/ojdbc5.jar\ $(path.separator)$(JA_LIBS_HOME)/sqlj/lib/translator.zip\ $(path.separator)$(JAVA_HOME_CLASSPATH) compile-for-server.javac.command = \ $(javac) -classpath $(compile-for-server.javac.classpath) ########################################################################### # # translator configuration # ########################################################################### dump.class.attributes.option = -dumpAttributes jvmc.translator.options = -optNullPointerChecks -emitStructs -notree \ -finalIsSpecial -maintainStack -reuseHeaders \ -fragile -monolithic -vtbls \ -timestamp $(NCOMP_TIMESTAMP) \ -emitFragileSet $(dump.class.attributes.option) jvmc.translator.classpath = $(WORK_DIR)/classes class.properties.dumper.classlist = \ $(JA_HOME)/ClassProperties.java \ $(JA_HOME)/Dumper.java \ $(JA_HOME)/TransitiveClosureDumper.java load.class.properties.dumper.command = \ $(loadjava) $(class.properties.dumper.classlist) $*.java reuse.class.attributes.command = \ $(cp.command) exact_class_list.txt class_attributes.txt translate.preamble.command = $(load.class.properties.dumper.command) translate.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.client.jvmc.Main \ -classpath $(jvmc.translator.classpath) \ -$(connection.driver) -user $(SCHEMA) -password $(PASSWORD)$(loadjava.opt.database.suffix) \ $(jvmc.translator.options) \ -module $*.cfg ########################################################################### # # DLL deployment # ########################################################################### dll.local.path = oracle/aurora/deploy/ deployment.jar.dll.resource.list = $(DLL_LIST:f:^"oracle/aurora/deploy/") ## dll.local.path = lib/ ## deployment.jar.dll.resource.list = $(DLL_LIST:f:^"lib/") dll.installer.maker.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.InstallerMaker \ -libPath $(dll.local.path) -DLLExtension $(file.extension.dll) \ -libPrefix $(library.prefix) \ -schema $(SCHEMA) \ -allClasses $(WORK_DIR)/class_attributes.txt \ -fragileSet fragile-set.lst -timestamp $(NCOMP_TIMESTAMP) \ $(*:f).cfg bundle.installer.maker.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.BundleInstallerClassBuilder \ project $(MODULE_TARGETS:+"_Installer.java") deployment.jar.content = \ $(MODULE_TARGETS:^"oracle/aurora/deploy/":+"_Installer.class") \ $(deployment.jar.dll.resource.list) jar.include.list = \ -C $(JA_HOME) SQL.java \ -C $(JA_HOME) ForEachClass.java \ -C $(JA_HOME) ClassProcessor.java \ -C $(JA_HOME) PackageDisableNcomp.java \ -C $(JA_HOME) PackageValidateAll.java \ -C $(JA_HOME) ClassProperties.java \ -C $(JA_HOME) Dumper.java \ -C $(JA_HOME) Installer.java dll.installer.classlist = \ $(JA_HOME)/SQL.java \ $(JA_HOME)/ForEachClass.java \ $(JA_HOME)/ClassProcessor.java \ $(JA_HOME)/PackageDisableNcomp.java \ $(JA_HOME)/PackageValidateAll.java \ $(JA_HOME)/ClassProperties.java \ $(JA_HOME)/Dumper.java \ $(JA_HOME)/Installer.java compile.dll.installers = \ $(compile-for-server.javac.command) \ -d $(WORK_DIR) \ $(dll.installer.classlist) \ $(MODULE_TARGETS:+"_Installer.java") load.installer.classes.command = $(loadjava) $(dll.installer.classlist) # Might add -force because otherwise loadjava might refuse to # reload DLLs deleted by ISV Ncomp. deploy.command = $(loadjava) $*.jar ########################################################################### # # Bundle DLL installer invoker # # InstallDLL: Invoke a BundleInstaller. If when the mechanism using # Runnable in oracle/aurora/deploy/ is used, install.dlls.command # is unnecessary. # # ShowDllsTable: print the contents of table jaccelerator$dlls # # ########################################################################### install.dlls.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.client.InstallDLL \ $(target.server.connection.string) $(SCHEMA) $(PASSWORD) \ $(*:f) dlls.status.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.client.ShowDllsTable \ $(target.server.connection.string) $(SCHEMA) $(PASSWORD) ########################################################################### # # generate project # # MakefileMaker spawns separate C compilation for each java class # # WithCFileBundlingMakefileMaker emits special "bundling" C files, # one per DLL # ########################################################################### one.c.unit.per.class.makefile.maker = oracle.jaccelerator.MakefileMaker one.c.unit.per.dll.makefile.maker = \ oracle.jaccelerator.WithCFileBundlingMakefileMaker makefile.maker = $(one.c.unit.per.class.makefile.maker) genproject.command = \ $(java) -classpath $(jvmc.java.classpath) \ $(makefile.maker) \ -objFileExtension $(file.extension.obj) -libPath $(dll.local.path) \ -buildDirName opt -DLLExtension $(file.extension.dll) \ -libPrefix $(library.prefix) \ -stamp $(NCOMP_TIMESTAMP) \ -projectSpec $(*:b) \ -user $(SCHEMA)/$(PASSWORD)$(loadjava.opt.database.suffix) genproject.commonClosure.flags = -closurePrecomputed gen-incr-dumper-class.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.ClassListLoaderGenerator \ -DLLExtension $(file.extension.dll) \ -libPrefix $(library.prefix) \ -projectSpec $(*:b)_minimalClassListAndTCDumper \ -user $(SCHEMA)/$(PASSWORD)$(loadjava.opt.database.suffix) \ $* tc.dumper.classlist = \ $(JA_HOME)/TransitiveClosureDumper.java \ $(JA_HOME)/MinimizeNcompListAndDumpTC.java incremental.dumper.classlist = \ $(dll.installer.classlist) \ $(tc.dumper.classlist) status.output.file = compute-dump-minimal-class-set.command = \ $(java) -classpath $(jvmc.java.classpath) \ oracle.jaccelerator.client.FindClassesToNcomp \ $(source.server.connection.string) \ $(SCHEMA) $(PASSWORD) load-incr-dumper-class.command = $(loadjava) $(incremental.dumper.classlist) drop-incr-dumper-class.command = $(dropjava) $(loadjava.connection) $(tc.dumper.classlist) ########################################################################### # # Aux commands # ########################################################################### cp.command = cp ls.command = ls -lt rm.command = rm -f rmdir.command = rm -rf du.command = du -k ls.libs.command = ls -l lib