summaryrefslogtreecommitdiff
path: root/cygwin/GNUmakefile.in
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-03-30 14:45:05 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-03-30 14:45:05 +0000
commit162b04061133c92f3b703c245eecfd0e0b6c5636 (patch)
tree30d8208d70ccf3f63aeda44c37ff22814c0de597 /cygwin/GNUmakefile.in
parentd6024d60551f484ad71fc9f4a2935bf880b4c5b5 (diff)
* Makefile.in, */Makefile.sub, */configure.bat, cygwin/GNUmakefile.in,
common.mk, configure.in, ext/extmk.rb, lib/mkmf.rb, instruby.rb, runruby.rb: backport extout. [ruby-dev:25963] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8217 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'cygwin/GNUmakefile.in')
-rw-r--r--cygwin/GNUmakefile.in17
1 files changed, 15 insertions, 2 deletions
diff --git a/cygwin/GNUmakefile.in b/cygwin/GNUmakefile.in
index da9efaab47..03208df11c 100644
--- a/cygwin/GNUmakefile.in
+++ b/cygwin/GNUmakefile.in
@@ -1,11 +1,14 @@
include Makefile
ENABLE_SHARED=@ENABLE_SHARED@
+DLLWRAP = @DLLWRAP@ --target=@target_os@
ifeq (@target_os@,cygwin)
DLL_BASE_NAME := $(subst .dll,,$(LIBRUBY_SO))
else
DLL_BASE_NAME := $(RUBY_SO_NAME)
+ DLLWRAP += -mno-cygwin
+ VPATH += $(srcdir)/win32
endif
ifneq ($(ENABLE_SHARED),yes)
@@ -24,6 +27,10 @@ endif
WPROGRAM = $(RUBYW_INSTALL_NAME)$(EXEEXT)
SOLIBS := $(DLL_BASE_NAME).res.@OBJEXT@ $(SOLIBS)
EXTOBJS += $(@:$(EXEEXT)=.res.@OBJEXT@)
+RCFILES = $(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(DLL_BASE_NAME).rc
+
+ruby: $(PROGRAM)
+rubyw: $(WPROGRAM)
$(LIBRUBY): $(RUBY_EXP) $(LIBRUBY_SO)
$(RUBY_EXP) $(LIBRUBY_SO): $(DLL_BASE_NAME).res.@OBJEXT@
@@ -31,7 +38,7 @@ $(RUBY_EXP) $(LIBRUBY_SO): $(DLL_BASE_NAME).res.@OBJEXT@
%.res.@OBJEXT@: %.rc
@WINDRES@ --include-dir . --include-dir $(<D) --include-dir $(srcdir)/win32 $< $@
-$(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(DLL_BASE_NAME).rc: rbconfig.rb
+$(RCFILES): $(RBCONFIG)
@$(MINIRUBY) $(srcdir)/win32/resource.rb \
-ruby_name=$(RUBY_INSTALL_NAME) -rubyw_name=$(RUBYW_INSTALL_NAME) \
-so_name=$(DLL_BASE_NAME) \
@@ -44,7 +51,7 @@ $(WPROGRAM): $(RUBYW_INSTALL_NAME).res.@OBJEXT@
$(MAINOBJ) $(EXTOBJS) $(LIBRUBYARG) $(LIBS) -o $@
$(RUBY_EXP): $(LIBRUBY_A)
- @DLLWRAP@ --target=@target_os@ --driver-name=$(CC) \
+ $(DLLWRAP) \
--output-exp=$(RUBY_EXP) \
--export-all $(LIBRUBY_A) $(LIBS) -o $(PROGRAM)
$(LDSHARED) $(DLDFLAGS) $(OBJS) dmyext.o $(SOLIBS) -o $(PROGRAM)
@@ -63,3 +70,9 @@ cygwin-$(RUBY_INSTALL_NAME)$(MAJOR)$(MINOR).dll: $(LIBRUBY_A)
@DLLWRAP@ -s --def=rubydll.def -o $@
@rm -f rubydll.def
endif
+
+clean-local::
+ @$(RM) $(RUBY_EXP) $(RCFILES:.rc=.res.@OBJEXT@)
+
+distclean-local::
+ @$(RM) $(RCFILES)