Patch by Yaakov Selkowitz to get Cygwin port work again

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/tools/make/trunk@28463 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Nicola Pero 2009-08-15 21:59:04 +00:00
parent a921a98987
commit 06301c9ada
4 changed files with 28 additions and 16 deletions

View file

@ -1,4 +1,14 @@
2009-08-14 Nicola Pero <nicola.pero@meta-innovation.com>
2009-08-15 Nicola Pero <nicola.pero@meta-innovation.com>
Patch from Yaakov Selkowitz <yselkowitz@yahoo.com>:
* target.make: On Cygwin, use -Wl,--enable-auto-image-import
instead of manually rebasing; define DLL_PREFIX to be 'cyg' to
match Cygwin conventions and fixed typo in
--Wl,-enable-whole-archive option.
* Instance/library.make: Prepend DLL_PREFIX when creating a dll.
* Instance.framework.make: Same change.
2009-08-15 Nicola Pero <nicola.pero@meta-innovation.com>
* common.make: Do not filter out the -Ox flags when debug=yes.
This means debug=yes now uses "-g -O2" by default - instead of

View file

@ -281,11 +281,12 @@ FRAMEWORK_LIBRARY_FILE = lib$(GNUSTEP_INSTANCE)$(DLL_LIBEXT)$(LIBEXT)
VERSION_FRAMEWORK_LIBRARY_FILE = $(FRAMEWORK_LIBRARY_FILE)
SONAME_FRAMEWORK_FILE = $(FRAMEWORK_LIBRARY_FILE)
# LIB_LINK_DLL_FILE is the DLL library, Renaissance-0.dll. Include
# the INTERFACE_VERSION in the DLL library name. Applications are
# linked explicitly to this INTERFACE_VERSION of the library; this
# works exactly in the same way as under Unix.
LIB_LINK_DLL_FILE = $(GNUSTEP_INSTANCE)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_LIBEXT)
# LIB_LINK_DLL_FILE is the DLL library, Renaissance-0.dll
# (cygRenaissance-0.dll on Cygwin). Include the INTERFACE_VERSION in
# the DLL library name. Applications are linked explicitly to this
# INTERFACE_VERSION of the library; this works exactly in the same way
# as under Unix.
LIB_LINK_DLL_FILE = $(DLL_PREFIX)$(GNUSTEP_INSTANCE)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_LIBEXT)
FRAMEWORK_OBJ_EXT = $(DLL_LIBEXT)
endif # BUILD_DLL

View file

@ -214,11 +214,12 @@ LIBRARY_FILE = $(LIBRARY_NAME_WITH_LIB)$(DLL_LIBEXT)$(LIBEXT)
VERSION_LIBRARY_FILE = $(LIBRARY_FILE)
SONAME_LIBRARY_FILE = $(LIBRARY_FILE)
# LIB_LINK_DLL_FILE is the DLL library, gnustep-base-1.dll. Include
# the INTERFACE_VERSION in the DLL library name. Applications are
# linked explicitly to this INTERFACE_VERSION of the library; this
# works exactly in the same way as under Unix.
LIB_LINK_DLL_FILE = $(LIBRARY_NAME_WITHOUT_LIB)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_LIBEXT)
# LIB_LINK_DLL_FILE is the DLL library, gnustep-base-1.dll
# (cyggnustep-base-1.dll on Cygwin). Include the INTERFACE_VERSION in
# the DLL library name. Applications are linked explicitly to this
# INTERFACE_VERSION of the library; this works exactly in the same way
# as under Unix.
LIB_LINK_DLL_FILE = $(DLL_PREFIX)$(LIBRARY_NAME_WITHOUT_LIB)-$(subst .,_,$(INTERFACE_VERSION))$(DLL_LIBEXT)
endif # BUILD_DLL
else # following code for static libs

View file

@ -928,6 +928,7 @@ HAVE_SHARED_LIBS = yes
# the import library
SHARED_LIB_LINK_CMD = \
$(LD) $(SHARED_LD_PREFLAGS) -shared -o $(LIB_LINK_OBJ_DIR)/$(LIB_LINK_DLL_FILE) \
-Wl,--enable-auto-image-base \
-Wl,--out-implib=$(LIB_LINK_OBJ_DIR)/$(LIB_LINK_VERSION_FILE) \
-Wl,--export-all-symbols \
-Wl,--enable-auto-import \
@ -942,9 +943,8 @@ SHARED_LIBEXT = .dll.a
BUILD_DLL = yes
CYGWIN_DLL_SUPPORT = yes
#SHARED_LIBEXT = .a
DLL_PREFIX = cyg
DLL_LIBEXT = .dll
REBASE = rebase
REBASE_FLAGS = -d -b 0x68000000 -o 0x10000
CYGWIN_LD_FLAGS = -Wl,--export-all-symbols -Wl,--enable-auto-import
#SHARED_CFLAGS +=
@ -955,14 +955,14 @@ HAVE_BUNDLES = yes
BUNDLE_LD = $(LD)
BUNDLE_LDFLAGS += -shared -Wl,--export-all-symbols \
-Wl,--enable-auto-import \
-Wl,--enable-auto-image-base \
-Wl,--whole-archive
BUNDLE_LIBFLAGS += -Wl,--no-whole-archiv
BUNDLE_LIBFLAGS += -Wl,--no-whole-archive
BUNDLE_LINK_CMD = \
$(BUNDLE_LD) $(BUNDLE_LDFLAGS) $(ALL_LDFLAGS) \
-o $(LDOUT)$(BUNDLE_FILE) \
$(OBJ_FILES_TO_LINK) \
$(BUNDLE_LIBFLAGS) $(ALL_LIB_DIRS) $(BUNDLE_LIBS); \
$(REBASE) $(REBASE_FLAGS) $(BUNDLE_FILE)
$(BUNDLE_LIBFLAGS) $(ALL_LIB_DIRS) $(BUNDLE_LIBS)
endif
# end Cygwin