From a96cc90b942cc9cfaa9e8b3bd2a7588cb84cb478 Mon Sep 17 00:00:00 2001 From: bellardo Date: Tue, 7 Aug 2001 02:15:26 +0000 Subject: [PATCH] Updated build system to remove jrd_static.a, and make it possible to build completely statically linked executables. --- src/make.new/Makefile.in.alice | 6 +++--- src/make.new/Makefile.in.burp | 12 +++++------ src/make.new/Makefile.in.dsql | 15 ++------------ src/make.new/Makefile.in.dudley | 6 +++--- src/make.new/Makefile.in.example5 | 10 ++++----- src/make.new/Makefile.in.fbutil | 17 ++------------- src/make.new/Makefile.in.firebird | 16 ++++----------- src/make.new/Makefile.in.gpre | 8 ++++---- src/make.new/Makefile.in.isql | 10 ++++----- src/make.new/Makefile.in.jrd | 24 +++++++++------------- src/make.new/Makefile.in.lock | 31 ++++++++-------------------- src/make.new/Makefile.in.msgs | 22 ++++++++++---------- src/make.new/Makefile.in.pipe | 17 ++------------- src/make.new/Makefile.in.qli | 6 +++--- src/make.new/Makefile.in.remote | 21 ++++--------------- src/make.new/Makefile.in.utilities | 33 +++++++++++++++--------------- src/make.new/Makefile.in.wal | 17 ++------------- src/make.new/make.defaults | 6 +++++- src/make.new/make.shared.variables | 11 +++++++++- src/make.new/prefix.darwin | 7 ++++++- 20 files changed, 113 insertions(+), 182 deletions(-) diff --git a/src/make.new/Makefile.in.alice b/src/make.new/Makefile.in.alice index 0ea4eb1f29..4224e1b178 100644 --- a/src/make.new/Makefile.in.alice +++ b/src/make.new/Makefile.in.alice @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.alice,v 1.3 2001-08-01 04:18:37 skywalker Exp $ +# $Id: Makefile.in.alice,v 1.4 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -56,8 +56,8 @@ Dependencies = $(All_Objects:.o=.d) # Ok so alice, all-else became the program gfix. gfix: $(BIN)/gfix -$(BIN)/gfix: $(ALICE_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/gfix: $(ALICE_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) # $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ diff --git a/src/make.new/Makefile.in.burp b/src/make.new/Makefile.in.burp index d788194a25..180daac085 100644 --- a/src/make.new/Makefile.in.burp +++ b/src/make.new/Makefile.in.burp @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.burp,v 1.2 2001-08-01 08:11:52 skywalker Exp $ +# $Id: Makefile.in.burp,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -62,7 +62,7 @@ all: gbak_static gbak gsplit gbak_static : $(BIN)/gbak_static -$(BIN)/gbak_static : $(BURP_Objects) $(LIB)/jrd_static.a +$(BIN)/gbak_static : $(BURP_Objects) $(BOOT_GDSLIB_Objects) $(CXX) $(LINK_OPTS) $^ -o $@ $(COREFOUNDATION_LINK) $(LINK_LIBS) @@ -75,8 +75,8 @@ $(BIN)/gbak_static : $(BURP_Objects) $(LIB)/jrd_static.a gbak: $(BIN)/gbak -$(BIN)/gbak: $(BURP_Objects) $(LIBGDS_LA) - $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/gbak: $(BURP_Objects) $(LIBGDS_DEP) + $(CXX) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ @@ -85,8 +85,8 @@ gsplit : $(BIN)/gsplit # be careful of split vs spit here the public name is gsplit the internal # one is spit, so be careful the macros have the right name. -$(BIN)/gsplit: $(SPIT_Objects) $(LIBGDS_LA) - $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/gsplit: $(SPIT_Objects) $(LIBGDS_DEP) + $(CXX) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ diff --git a/src/make.new/Makefile.in.dsql b/src/make.new/Makefile.in.dsql index 38ebe7f3eb..729d93d355 100644 --- a/src/make.new/Makefile.in.dsql +++ b/src/make.new/Makefile.in.dsql @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.dsql,v 1.2 2001-08-01 04:18:37 skywalker Exp $ +# $Id: Makefile.in.dsql,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -52,21 +52,10 @@ Dependencies = $(AllObjects:.o=.d) -.PHONY: jrd_static - -jrd_static : $(LIB)/jrd_static.a($(DSQL_Objects)) - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - - - -# In phase2 we add the same objects as before, we just rebuild them as -# portable and load them into a shared libgds.so library. +# Build all our files that belong in the shared library. .PHONY: jrdlib_dependencies - jrdlib_dependencies: $(DSQL_Objects) diff --git a/src/make.new/Makefile.in.dudley b/src/make.new/Makefile.in.dudley index e2fc330775..13bc9b979e 100644 --- a/src/make.new/Makefile.in.dudley +++ b/src/make.new/Makefile.in.dudley @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.dudley,v 1.3 2001-08-06 15:08:18 skywalker Exp $ +# $Id: Makefile.in.dudley,v 1.4 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -56,8 +56,8 @@ all: gdef gdef: $(BIN)/gdef -$(BIN)/gdef: $(DUDLEY_Objects) $(LIBGDS_LA) - $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/gdef: $(DUDLEY_Objects) $(LIBGDS_DEP) + $(CXX) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ diff --git a/src/make.new/Makefile.in.example5 b/src/make.new/Makefile.in.example5 index 6cd8ab726e..9b381b027e 100644 --- a/src/make.new/Makefile.in.example5 +++ b/src/make.new/Makefile.in.example5 @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.example5,v 1.1 2001-07-29 23:43:23 skywalker Exp $ +# $Id: Makefile.in.example5,v 1.2 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -146,9 +146,9 @@ employee.gdb: empbuild$(EXEC_EXT) $(INPUT_FILES) ./empbuild employee.gdb -$(CHMOD_6) employee.gdb -empbuild: $(EMPBLD_OBJ) $(LIBGDS_LA) +empbuild: $(EMPBLD_OBJ) $(LIBGDS_DEP) -$(RM) $@ - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ empbuild.exe: $(EMPBLD_OBJ) @@ -180,9 +180,9 @@ intlbuild.gdb : intlddl.sql intlbld.sql -$(RM) intlbuild.gdb $(ISQL) -i intlbld.sql -intlbld: $(INTLBLD_OBJ) $(LIBGDS_LA) +intlbld: $(INTLBLD_OBJ) $(LIBGDS_DEP) -$(RM) $@ - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ intlbld.exe: $(INTLBLD_OBJ) diff --git a/src/make.new/Makefile.in.fbutil b/src/make.new/Makefile.in.fbutil index 236cd8f0ea..285c8abaec 100755 --- a/src/make.new/Makefile.in.fbutil +++ b/src/make.new/Makefile.in.fbutil @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.fbutil,v 1.2 2001-08-01 04:18:37 skywalker Exp $ +# $Id: Makefile.in.fbutil,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -43,22 +43,9 @@ AllObjects= $(FBUTIL_Objects) Dependancies=$(AllObjects:.o=.d) -.PHONY: all libs progs - - -jrd_static : $(LIB)/jrd_static.a($(FBUTIL_Objects)) - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - - - -# In phase2 we add the same objects as before, we just rebuild them as -# portable and load them into a shared libgds.so library. - +# Build all our objects that belong in the shared library. .PHONY: jrdlib_dependencies - jrdlib_dependencies: $(FBUTIL_Objects) diff --git a/src/make.new/Makefile.in.firebird b/src/make.new/Makefile.in.firebird index ae5706e57f..8441f57e3e 100644 --- a/src/make.new/Makefile.in.firebird +++ b/src/make.new/Makefile.in.firebird @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.firebird,v 1.3 2001-08-02 07:03:59 skywalker Exp $ +# $Id: Makefile.in.firebird,v 1.4 2001-08-07 02:15:26 bellardo Exp $ # ROOT=.. @@ -74,7 +74,7 @@ firebird: phase1 phase2 phase3 # (If you really want to rebuild it you need to remove the executable file # $(BIN)/gpre_static). # -.PHONY: phase1 phase1_build jrd_boot gpre_boot jrd_static gpre_static +.PHONY: phase1 phase1_build jrd_boot gpre_boot gpre_static phase1: $(GPRE_STATIC) @@ -82,19 +82,11 @@ phase1: $(GPRE_STATIC) $(GPRE_STATIC): $(MAKE) phase1_build -phase1_build: jrd_boot gpre_boot build_alt_use_boot jrd_static gpre_static +phase1_build: jrd_boot gpre_boot build_alt_use_boot jrdlib_dependencies gpre_static -gpre_static : jrd_static +gpre_static : jrdlib_dependencies $(MAKE) -C gpre $@ -jrd_static : gpre_boot - $(MAKE) -C jrd $@ - $(MAKE) -C dsql $@ - $(MAKE) -C lock $@ - $(MAKE) -C remote $@ - $(MAKE) -C pipe $@ - $(MAKE) -C wal $@ - build_alt_use_boot: # Create header file so jrd/alt.cpp does not use security. $(MAKE) -C jrd $@ # Also 'hack' security to build dummy .o files $(MAKE) -C utilities $@ diff --git a/src/make.new/Makefile.in.gpre b/src/make.new/Makefile.in.gpre index 424bcfe28b..e78689cdee 100644 --- a/src/make.new/Makefile.in.gpre +++ b/src/make.new/Makefile.in.gpre @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.gpre,v 1.4 2001-08-04 22:48:18 bellardo Exp $ +# $Id: Makefile.in.gpre,v 1.5 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -81,15 +81,15 @@ $(GPRE_BOOT): $(GPRECommon_Objects) $(GPREBoot_Objects) $(LIB)/jrd_boot.a $(LN) $(@F) $(GPRE_CURRENT) -$(GPRE_STATIC):$(GPRECommon_Objects) $(GPRE_Objects) $(LIB)/jrd_static.a +$(GPRE_STATIC):$(GPRECommon_Objects) $(GPRE_Objects) $(BOOT_GDSLIB_Objects) $(STATICEXE_LINK) $(LINK_OPTS) $^ -o $@ $(STATICLINK_LIBS) $(CHMOD_7) $@ -$(RM) $(GPRE_CURRENT) $(LN) $(@F) $(GPRE_CURRENT) -$(GPRE):$(GPRECommon_Objects) $(GPRE_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(GPRE):$(GPRECommon_Objects) $(GPRE_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ -$(RM) $(GPRE_CURRENT) $(LN) $(@F) $(GPRE_CURRENT) diff --git a/src/make.new/Makefile.in.isql b/src/make.new/Makefile.in.isql index 4da8533ac7..65b4f2ccb3 100644 --- a/src/make.new/Makefile.in.isql +++ b/src/make.new/Makefile.in.isql @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.isql,v 1.2 2001-08-01 08:11:52 skywalker Exp $ +# $Id: Makefile.in.isql,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -66,8 +66,8 @@ isql: $(ISQL) -$(ISQL): $(ISQL_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(ISQL): $(ISQL_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ @@ -79,8 +79,8 @@ $(ISQL): $(ISQL_Objects) $(LIBGDS_LA) muisql: $(MUISQL) -$(MUISQL): $(ISQL_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(MUISQL): $(ISQL_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ # Again this wants to change to $(GEN_SRC) directory diff --git a/src/make.new/Makefile.in.jrd b/src/make.new/Makefile.in.jrd index 59b899c772..34fe677d3b 100644 --- a/src/make.new/Makefile.in.jrd +++ b/src/make.new/Makefile.in.jrd @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.jrd,v 1.5 2001-08-06 15:08:18 skywalker Exp $ +# $Id: Makefile.in.jrd,v 1.6 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -53,7 +53,7 @@ GPRE_FLAGS = -n -z -gds_cxx -raw -ids -.PHONY: jrd_boot jrd_static +.PHONY: jrd_boot # This is the very first library built it contains just enough methods @@ -68,24 +68,20 @@ jrd_boot : $(LIB)/jrd_boot.a $(LIB)/jrd_boot.a: $(BOOT_Objects) -$(RM) $@ $(AR) $@ $^ - -ranlib $@ + -$(RANLIB) $@ $(CHMOD_6) $@ # Add all the jrd objects to the jrd static library. -jrd_static : $(LIB)/jrd_static.a($(JRD_Objects)) - $(RANLIB) $(LIB)/jrd_static.a - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - +$(LIBGDS_A) : $(GDSLIB_Objects) + ar -q $@ $^ + -$(RANLIB) $@ # This is the first dynamic link library that we build in phase2 it still -# does not contain security objects. - - +# does not contain security objects. Also used to produce the object files +# that the *_static programs link against. jrdlib_dependencies: $(JRD_Objects) @@ -660,9 +656,9 @@ rebuild_codes: codes ./codes $(ROOT)/src/include/gen -codes: codes.o $(STDIO) $(LIBGDS_LA) +codes: codes.o $(STDIO) $(LIBGDS_DEP) -$(RM) codes - $(EXE_LINK) $(LINK_OPTIONS) $(CXX_INCLUDE_DIRS) -o codes $^ + $(EXE_LINK) $(LINK_OPTIONS) $(LIBGDS_LINK) $(CXX_INCLUDE_DIRS) -o codes $^ $(CHMOD_7) codes diff --git a/src/make.new/Makefile.in.lock b/src/make.new/Makefile.in.lock index e8e1d41a41..0eba08a15d 100644 --- a/src/make.new/Makefile.in.lock +++ b/src/make.new/Makefile.in.lock @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.lock,v 1.3 2001-08-04 22:48:18 bellardo Exp $ +# $Id: Makefile.in.lock,v 1.4 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -54,7 +54,7 @@ Dependencies = $(All_Objects:.o=.d) -.PHONY: jrd_static gds_lock_manager lock_print lock_config_file +.PHONY: gds_lock_manager lock_print lock_config_file all: jrdlib_dependencies gds_lock_manager lock_print lock_config_file @@ -62,24 +62,11 @@ all: jrdlib_dependencies gds_lock_manager lock_print lock_config_file other_targets: lock_driver # is a lock test program -# jrd_static -# -# As part of the boot build process a static library is build with the lock -# object in it. After the boot has built it is no longer required. - - -jrd_static : $(LIB)/jrd_static.a($(LOCK_Objects)) - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - # jrdlib_dependencies # -# In phase2 we add the same objects as before, we just rebuild them as -# portable and load them into a shared libgds.so library. - - +# Used in phase1 and phase2 to build the LOCK objects that belong in the +# shared library. jrdlib_dependencies: $(LOCK_Objects) @@ -92,7 +79,7 @@ jrdlib_dependencies: $(LOCK_Objects) gds_lock_manager : $(BIN)/gds_lock_mgr -$(BIN)/gds_lock_mgr: $(LOCKMGR_Objects) $(LIB)/jrd_static.a +$(BIN)/gds_lock_mgr: $(LOCKMGR_Objects) $(BOOT_GDSLIB_Objects) $(CXX) $(LINK_OPTS) $^ -o $@ $(CHMOD_S7) $@ @@ -105,8 +92,8 @@ $(BIN)/gds_lock_mgr: $(LOCKMGR_Objects) $(LIB)/jrd_static.a lock_print : $(BIN)/lock_print -$(BIN)/lock_print: $(LOCKPRINT_Objects) $(LIBGDS_LA) - $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/lock_print: $(LOCKPRINT_Objects) $(LIBGDS_DEP) + $(CXX) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_S7) $@ @@ -132,8 +119,8 @@ $(INTERBASE)/isc_config : config_params lock_driver : $(BIN)/lock_driver -$(BIN)/lock_driver: $(LOCKDRIVER_OBJECTS) $(LIBGDS_LA) - $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/lock_driver: $(LOCKDRIVER_OBJECTS) $(LIBGDS_DEP) + $(CXX) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_S7) $@ diff --git a/src/make.new/Makefile.in.msgs b/src/make.new/Makefile.in.msgs index 2078422658..c8c57f9fbc 100644 --- a/src/make.new/Makefile.in.msgs +++ b/src/make.new/Makefile.in.msgs @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.msgs,v 1.3 2001-08-06 19:36:58 bellardo Exp $ +# $Id: Makefile.in.msgs,v 1.4 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -82,28 +82,28 @@ do_check: $(CHECK_MESSAGES) $(BUILD_FILE) -$(CHECK_MESSAGES): $(CHECK_OBJECTS) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(CHECK_MESSAGES): $(CHECK_OBJECTS) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ -$(BUILD_FILE): $(BUILD_OBJECTS) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BUILD_FILE): $(BUILD_OBJECTS) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ -$(ENTER_MESSAGES): $(ENTER_OBJECTS) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(ENTER_MESSAGES): $(ENTER_OBJECTS) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ -$(MODIFY_MESSAGES): $(MODIFY_OBJECTS) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(MODIFY_MESSAGES): $(MODIFY_OBJECTS) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ -$(CHANGE_MESSAGES): $(CHANGE_OBJECTS) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(CHANGE_MESSAGES): $(CHANGE_OBJECTS) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ diff --git a/src/make.new/Makefile.in.pipe b/src/make.new/Makefile.in.pipe index 7b4879e587..84379fecae 100644 --- a/src/make.new/Makefile.in.pipe +++ b/src/make.new/Makefile.in.pipe @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.pipe,v 1.2 2001-08-01 04:18:37 skywalker Exp $ +# $Id: Makefile.in.pipe,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -44,22 +44,9 @@ AllObjects = $(PIPE_Objects) Dependencies = $(All_Objects:.o=.d) -.PHONY: jrd_static - - -jrd_static : $(LIB)/jrd_static.a($(PIPE_Objects)) - - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - - -# In phase2 we add the same objects as before, we just rebuild them as -# portable and load them into a shared libgds.so library. - +# Build the PIPE objects that belong in the shared library. .PHONY: jrdlib_dependencies - jrdlib_dependencies: $(PIPE_Objects) diff --git a/src/make.new/Makefile.in.qli b/src/make.new/Makefile.in.qli index 310bd836a2..dbe2348fe5 100644 --- a/src/make.new/Makefile.in.qli +++ b/src/make.new/Makefile.in.qli @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.qli,v 1.2 2001-08-01 08:11:52 skywalker Exp $ +# $Id: Makefile.in.qli,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -63,8 +63,8 @@ allx: qli # allx is used since there is a local all.cpp file. # qli : $(QLI) -$(QLI): $(QLI_Objects) $(LIBGDS_LA) - $(CXX) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(QLI): $(QLI_Objects) $(LIBGDS_DEP) + $(CXX) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_S7) $@ diff --git a/src/make.new/Makefile.in.remote b/src/make.new/Makefile.in.remote index 620c034055..50755ddd39 100644 --- a/src/make.new/Makefile.in.remote +++ b/src/make.new/Makefile.in.remote @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.remote,v 1.3 2001-08-01 04:18:37 skywalker Exp $ +# $Id: Makefile.in.remote,v 1.4 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -57,22 +57,9 @@ AllObjects = $(INTERFACE_Objects) $(SERVER_Objects) $(INETSERVER_Objects) Dependencies = $(AllObjects:.o=.d) -.PHONY: jrd_static - -jrd_static : $(LIB)/jrd_static.a($(INTERFACE_Objects)) - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - - - -# In phase2 we add the same objects as before, we just rebuild them as -# portable and load them into a shared libgds.so library. - +# Build the INTERFACE objects that go in the shared library .PHONY: jrdlib_dependencies - - jrdlib_dependencies: $(INTERFACE_Objects) @@ -88,8 +75,8 @@ all: inet_server inet_server : $(BIN)/gds_inet_server -$(BIN)/gds_inet_server: $(SERVER_Objects) $(INETSERVER_Objects) $(LIBGDS_LA) - $(CC) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(BIN)/gds_inet_server: $(SERVER_Objects) $(INETSERVER_Objects) $(LIBGDS_DEP) + $(CC) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_S7) $@ diff --git a/src/make.new/Makefile.in.utilities b/src/make.new/Makefile.in.utilities index 60af8c6f24..192fdcaeee 100644 --- a/src/make.new/Makefile.in.utilities +++ b/src/make.new/Makefile.in.utilities @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.utilities,v 1.5 2001-08-06 15:08:18 skywalker Exp $ +# $Id: Makefile.in.utilities,v 1.6 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -45,7 +45,8 @@ CREATEDB_Objects = $(CREATEDB_Sources:%.cpp=$(OBJ)/%.o) DROP_Sources = drop.cpp dropv3.cpp DROP_Objects = $(DROP_Sources:%.cpp=$(OBJ)/%.o) -GSEC_Sources = gsec.cpp security.cpp +#GSEC_Sources = gsec.cpp security.cpp +GSEC_Sources = gsec.cpp GSEC_Objects = $(GSEC_Sources:%.cpp=$(OBJ)/%.o) GSTAT_Sources = dba.cpp ppg.cpp @@ -103,12 +104,12 @@ ibguard : $(IBGUARD) -$(CREATE_DB): $(CREATEDB_Objects) $(LIB)/jrd_static.a +$(CREATE_DB): $(CREATEDB_Objects) $(BOOT_GDSLIB_Objects) $(STATICEXE_LINK) $(STATICLINK_OPTS) $^ -o $@ $(STATICLINK_LIBS) $(CHMOD_7) $@ -$(GDS_DROP): $(DROP_Objects) $(LIB)/jrd_static.a +$(GDS_DROP): $(DROP_Objects) $(BOOT_GDSLIB_Objects) $(STATICEXE_LINK) $(STATICLINK_OPTS) $^ -o $@ $(STATICLINK_LIBS) $(CHMOD_S7) $@ @@ -185,8 +186,8 @@ have_added_sysdba_user.flg : $(ISC_GDB) $(GSEC) # no it aint MOD 13-7-2001 -$(GSEC): $(GSEC_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(GSEC): $(GSEC_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ @@ -195,32 +196,32 @@ $(GSEC): $(GSEC_Objects) $(LIBGDS_LA) # dba/gstat -$(GSTAT): $(GSTAT_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(GSTAT): $(GSTAT_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ # ibguard -$(IBGUARD): $(IBGUARD_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(IBGUARD): $(IBGUARD_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ # ibmgr -$(IBMGR_BIN): $(IBMGR_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(IBMGR_BIN): $(IBMGR_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ # rebuild -$(GDS_REBUILD): $(REBUILD_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(GDS_REBUILD): $(REBUILD_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ @@ -228,8 +229,8 @@ $(GDS_REBUILD): $(REBUILD_Objects) $(LIBGDS_LA) -$(GDS_RELAY): $(RELAY_Objects) $(LIBGDS_LA) - $(EXE_LINK) $(LINK_OPTS) $^ -o $@ $(LINK_LIBS) +$(GDS_RELAY): $(RELAY_Objects) $(LIBGDS_DEP) + $(EXE_LINK) $(LINK_OPTS) $(LIBGDS_LINK) $^ -o $@ $(LINK_LIBS) $(CHMOD_7) $@ diff --git a/src/make.new/Makefile.in.wal b/src/make.new/Makefile.in.wal index f19a64b147..ed39abd2d0 100644 --- a/src/make.new/Makefile.in.wal +++ b/src/make.new/Makefile.in.wal @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: Makefile.in.wal,v 1.2 2001-08-01 04:18:37 skywalker Exp $ +# $Id: Makefile.in.wal,v 1.3 2001-08-07 02:15:26 bellardo Exp $ # ROOT=../.. @@ -45,22 +45,9 @@ Dependencies = $(All_Objects:.o=.d) -.PHONY: jrd_static - -jrd_static : $(LIB)/jrd_static.a($(WAL_Objects)) - -$(LIB)/jrd_static.a(%.o) : %.o - ar crv $@ $% - - - -# In phase2 we add the same objects as before, we just rebuild them as -# portable and load them into a shared libgds.so library. - +# Build the WAL objects that belong in the shared library. .PHONY: jrdlib_dependencies - - jrdlib_dependencies: $(WAL_Objects) diff --git a/src/make.new/make.defaults b/src/make.new/make.defaults index 4c9f4be352..513a099522 100755 --- a/src/make.new/make.defaults +++ b/src/make.new/make.defaults @@ -26,7 +26,7 @@ # Contributor(s): # # -# $Id: make.defaults,v 1.5 2001-08-04 22:48:18 bellardo Exp $ +# $Id: make.defaults,v 1.6 2001-08-07 02:15:26 bellardo Exp $ # @@ -86,8 +86,12 @@ LIBGDS_A = $(LIB)/libgds.a ifdef UseSharedLibraries LIBGDS_LA = $(LIBGDS_SO) + LIBGDS_DEP = + LIBGDS_LINK = $(LIBGDS_SO) else LIBGDS_LA = $(LIBGDS_A) + LIBGDS_DEP = $(LIBGDS_LA) + LIBGDS_LINK = endif diff --git a/src/make.new/make.shared.variables b/src/make.new/make.shared.variables index bfd3addcea..dfc86e3b0e 100644 --- a/src/make.new/make.shared.variables +++ b/src/make.new/make.shared.variables @@ -157,5 +157,14 @@ GDSLIB_Objects = $(JRD_Objects) \ $(SECURITY_Objects) \ $(FBUTIL_Objects) -GDSLIB_SharedObjects = $(GDSLIB_Objects:.o=.lo) +# Notice that $(SECURITY_Objects) are missing, because that file can't be +# compiled until later in the build process. +BOOT_GDSLIB_Objects = $(JRD_Objects) \ + $(DSQL_Objects) \ + $(LOCK_Objects) \ + $(INTERFACE_Objects) \ + $(PIPE_Objects) \ + $(WAL_Objects) \ + $(GPRELIB_Objects) \ + $(FBUTIL_Objects) diff --git a/src/make.new/prefix.darwin b/src/make.new/prefix.darwin index daed1e1458..4aa6e52b7f 100644 --- a/src/make.new/prefix.darwin +++ b/src/make.new/prefix.darwin @@ -15,7 +15,7 @@ # All Rights Reserved. # Contributor(s): ______________________________________. # Start of file prefix.darwin: $(VERSION) @PLATFORM@ -#$Id: prefix.darwin,v 1.3 2001-08-07 00:41:03 bellardo Exp $ +#$Id: prefix.darwin,v 1.4 2001-08-07 02:15:26 bellardo Exp $ #_____________________________________________________________________________ @@ -204,6 +204,11 @@ CFLAGS := $(CARBONCORE_DIR_FLAG) $(CFLAGS) CXXFLAGS:= $(CXXFLAGS) $(CFLAGS) +# Set up the link line to work with the framework. +ifdef UseSharedLibraries + LIBGDS_LINK = -F$(FIREBIRD) -framework $(FBFW_PREFIX) +endif + # Set DYLD_FRAMEWORK_PATH to point to the framework we are building.