diff options
author | eban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-06-01 12:58:56 +0000 |
---|---|---|
committer | eban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-06-01 12:58:56 +0000 |
commit | fd681fe0e5240ae112b15ff437d3259f202b9705 (patch) | |
tree | 3c702e558fd624f097011e635fb851425d7623c8 | |
parent | dc13952417e5c918de9bd51f504db7a289ddabed (diff) |
* configure.in: should not use def file, use ld with
--export-all-symbols option on Cygwin/MinGW.
* defines.h: ditto.
* cygwin/GNUmakefile.in: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3894 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 19 | ||||
-rw-r--r-- | configure.in | 8 | ||||
-rw-r--r-- | cygwin/GNUmakefile.in | 20 | ||||
-rw-r--r-- | defines.h | 2 |
4 files changed, 27 insertions, 22 deletions
@@ -1,3 +1,12 @@ +Sun Jun 1 21:50:01 2003 WATANABE Hirofumi <[email protected]> + + * configure.in: should not use def file, use ld with + --export-all-symbols option on Cygwin/MinGW. + + * defines.h: ditto. + + * cygwin/GNUmakefile.in: ditto. + Sun Jun 01 13:33:49 2003 Takaaki Uematsu <[email protected]> * wince/string_wce.c: add strpbrk() for hpcpro support. @@ -19,14 +28,14 @@ Sat May 31 04:36:54 2003 Nobuyoshi Nakada <[email protected]> Fri May 30 23:18:01 2003 why the lucky stiff <[email protected]> - * ext/syck/rubyext.c (rb_syck_mktime): seconds calculated wrong. + * ext/syck/rubyext.c (rb_syck_mktime): seconds calculated wrong. - * ext/syck/gram.c: flexibility to anchors and transfer methods on - collections. + * ext/syck/gram.c: flexibility to anchors and transfer methods on + collections. - * ext/syck/token.c: hex escapes. + * ext/syck/token.c: hex escapes. - * lib/yaml/basenode.rb: YamlNode references changed to YAML::BaseNode. + * lib/yaml/basenode.rb: YamlNode references changed to YAML::BaseNode. Fri May 30 22:28:04 2003 Nobuyoshi Nakada <[email protected]> diff --git a/configure.in b/configure.in index e115561b8a..7bf4e39a86 100644 --- a/configure.in +++ b/configure.in @@ -833,7 +833,7 @@ if test "$with_dln_a_out" != yes; then rb_cv_dlopen=yes;; cygwin*|mingw*) : ${LDSHARED="${CC} -shared -s"} XLDFLAGS='-Wl,--stack,0x02000000' - DLDFLAGS="${DLDFLAGS} -Wl,--enable-auto-import "'$(DEFFILE)' + DLDFLAGS="${DLDFLAGS} -Wl,--enable-auto-import,--export-all" rb_cv_dlopen=yes ;; hiuxmpp) LDSHARED='ld -r' ;; atheos*) LDSHARED="$CC -shared" @@ -1166,7 +1166,6 @@ case "$target_os" in esac ;; cygwin*|mingw*) - EXPORT_PREFIX=' ' case "$target_os" in cygwin*) RUBY_SO_NAME=$target_os-'$(RUBY_INSTALL_NAME)'${MAJOR}${MINOR} @@ -1180,14 +1179,13 @@ case "$target_os" in COMMON_HEADERS="windows.h winsock.h" ;; esac - XCFLAGS="$XCFLAGS -DRUBY_EXPORT" + XCFLAGS="$XCFLAGS" + LIBRUBY_DLDFLAGS="${DLDFLAGS}"' -Wl,--out-implib=$(LIBRUBY)' if test x"$enable_shared" = xyes; then LIBRUBY_SO='$(RUBY_SO_NAME)'.dll - LIBRUBY_DLDFLAGS='-Wl,--out-implib=$(LIBRUBY) $(RUBYDEF)' LIBRUBY='lib$(LIBRUBY_SO).a' else LIBRUBY_SO=dummy - LIBRUBY_DLDFLAGS='' LIBRUBY='lib$(RUBY_SO_NAME).a' LIBRUBYARG='-l$(RUBY_SO_NAME)' fi diff --git a/cygwin/GNUmakefile.in b/cygwin/GNUmakefile.in index 0acb327bbd..7e8672b9d3 100644 --- a/cygwin/GNUmakefile.in +++ b/cygwin/GNUmakefile.in @@ -6,6 +6,7 @@ ifneq ($(ENABLE_SHARED),yes) RUBY_EXP = $(RUBY_INSTALL_NAME).exp EXTOBJS = $(RUBY_EXP) LIBRUBYARG = $(LIBRUBY_A) + LIBRUBY_SO = endif ifeq ($(RUBY_INSTALL_NAME),ruby) @@ -14,12 +15,11 @@ else RUBYW_INSTALL_NAME = $(subst ruby,rubyw,$(RUBY_INSTALL_NAME)) endif WPROGRAM = $(RUBYW_INSTALL_NAME)$(EXEEXT) -RUBYDEF = $(RUBY_INSTALL_NAME).def SOLIBS := $(RUBY_SO_NAME).res.@OBJEXT@ $(SOLIBS) EXTOBJS += $(@:$(EXEEXT)=.res.@OBJEXT@) -$(LIBRUBY_SO): $(RUBYDEF) $(RUBY_SO_NAME).res.@OBJEXT@ $(RUBY_EXP) -$(LIBRUBY): $(LIBRUBY_SO) +$(LIBRUBY): $(RUBY_EXP) $(LIBRUBY_SO) +$(RUBY_EXP) $(LIBRUBY_SO): $(RUBY_SO_NAME).res.@OBJEXT@ %.res.@OBJEXT@: %.rc @WINDRES@ --include-dir . --include-dir $(<D) --include-dir $(srcdir)/win32 $< $@ @@ -36,14 +36,12 @@ $(WPROGRAM): $(RUBYW_INSTALL_NAME).res.@OBJEXT@ $(PURIFY) $(CC) -mwindows -e _mainCRTStartup $(LDFLAGS) $(XLDFLAGS) \ $(MAINOBJ) $(EXTOBJS) $(LIBRUBYARG) $(LIBS) -o $@ -$(RUBYDEF): $(LIBRUBY_A) - echo EXPORTS > $(RUBYDEF) - @NM@ --extern-only --defined-only $(LIBRUBY_A) | sed -n 's/.* [CDT] _//p' >> $(RUBYDEF) - -$(RUBY_EXP): $(RUBYDEF) - @DLLWRAP@ --output-exp=$(RUBY_EXP) --output-lib=$(LIBRUBY) \ - --def=$(RUBYDEF) $(LIBRUBY_A) $(LIBS) -o $(PROGRAM) - rm $(PROGRAM) +$(RUBY_EXP): $(LIBRUBY_A) + @DLLWRAP@ --target=@target_os@ --driver-name=$(CC) \ + --output-exp=$(RUBY_EXP) \ + --export-all $(LIBRUBY_A) $(LIBS) -o $(PROGRAM) + $(LDSHARED) $(DLDFLAGS) $(OBJS) dmyext.o $(SOLIBS) -o $(PROGRAM) + @rm -f $(PROGRAM) GNUmakefile: $(srcdir)/cygwin/GNUmakefile.in @@ -125,7 +125,7 @@ void xfree _((void*)); #endif #undef RUBY_EXTERN -#if defined __CYGWIN__ || defined _WIN32 +#if defined _WIN32 && !defined __GNUC__ # ifndef RUBY_EXPORT # define RUBY_EXTERN extern __declspec(dllimport) # endif |