Skip to content

Commit 153b610

Browse files
committed
updated for version 7.3.735
Problem: Cannot build Ruby 1.9 with MingW or Cygwin. Solution: Add another include directory. (Ken Takata)
1 parent 77b19e7 commit 153b610

File tree

3 files changed

+22
-2
lines changed

3 files changed

+22
-2
lines changed

src/Make_cyg.mak

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,11 @@
2121
# TCL_VER define to version of TCL being used (83)
2222
# DYNAMIC_TCL no or yes: use yes to load the TCL DLL dynamically (yes)
2323
# RUBY define to path to Ruby dir to get Ruby support (not defined)
24-
# RUBY_VER define to version of Ruby being used (16)
24+
# RUBY_VER define to version of Ruby being used (16)
25+
# RUBY_VER_LONG same, but in format with dot. (1.6)
26+
# You must set RUBY_VER_LONG when changing RUBY_VER.
27+
# You must set RUBY_API_VER version to RUBY_VER_LONG.
28+
# Don't set ruby API version to RUBY_VER like 191.
2529
# DYNAMIC_RUBY no or yes: use yes to load the Ruby DLL dynamically (yes)
2630
# MZSCHEME define to path to MzScheme dir to get MZSCHEME support (not defined)
2731
# MZSCHEME_VER define to version of MzScheme being used (209_000)
@@ -217,8 +221,15 @@ RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_VER)
217221
endif
218222
endif
219223

224+
ifeq (19, $(word 1,$(sort 19 $(RUBY_VER))))
225+
RUBY_19_OR_LATER = 1
226+
endif
227+
220228
DEFINES += -DFEAT_RUBY
221229
INCLUDES += -I$(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM)
230+
ifdef RUBY_19_OR_LATER
231+
INCLUDES += -I$(RUBY)/include/ruby-$(RUBY_VER_LONG) -I$(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM)
232+
endif
222233
EXTRA_OBJS += $(OUTDIR)/if_ruby.o
223234

224235
ifeq (yes, $(DYNAMIC_RUBY))

src/Make_ming.mak

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,14 @@ RUBY_INSTALL_NAME = msvcrt-ruby$(RUBY_API_VER)
301301
endif
302302
endif
303303

304-
RUBYINC =-I $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM)
304+
ifeq (19, $(word 1,$(sort 19 $(RUBY_VER))))
305+
RUBY_19_OR_LATER = 1
306+
endif
307+
308+
RUBYINC = -I $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM)
309+
ifdef RUBY_19_OR_LATER
310+
RUBYINC += -I $(RUBY)/include/ruby-$(RUBY_VER_LONG) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM)
311+
endif
305312
ifeq (no, $(DYNAMIC_RUBY))
306313
RUBYLIB = -L$(RUBY)/lib -l$(RUBY_INSTALL_NAME)
307314
endif

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -725,6 +725,8 @@ static char *(features[]) =
725725

726726
static int included_patches[] =
727727
{ /* Add new patch number below this line */
728+
/**/
729+
735,
728730
/**/
729731
734,
730732
/**/

0 commit comments

Comments
 (0)