summaryrefslogtreecommitdiff
path: root/bcc32
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 /bcc32
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 'bcc32')
-rw-r--r--bcc32/Makefile.sub354
-rw-r--r--bcc32/configure.bat62
2 files changed, 182 insertions, 234 deletions
diff --git a/bcc32/Makefile.sub b/bcc32/Makefile.sub
index cac6128..5fe7937 100644
--- a/bcc32/Makefile.sub
+++ b/bcc32/Makefile.sub
@@ -1,6 +1,7 @@
# -*- makefile -*-
SHELL = $(COMSPEC)
+MKFILES = Makefile
#### Start of system configuration section. ####
OS = bccwin32
@@ -56,6 +57,7 @@ AR = tlib
PURIFY =
AUTOCONF = autoconf
+RM = $(srcdir:/=\)\win32\rm.bat
!if !defined(PROCESSOR_ARCHITECTURE)
PROCESSOR_ARCHITECTURE = x86
@@ -91,9 +93,26 @@ exec_prefix = $(prefix)
!ifndef libdir
libdir = $(exec_prefix)/lib
!endif
-!ifndef DESTDIR
-DESTDIR = $(prefix)
+!if !defined(datadir)
+datadir = $(prefix)/share
!endif
+!ifndef EXTOUT
+EXTOUT = .ext
+!endif
+!ifndef RIDATADIR
+RIDATADIR = $(DESTDIR)$(datadir)/ri/$(MAJOR).$(MINOR)/system
+!endif
+!ifndef TESTUI
+TESTUI = console
+!endif
+!ifndef TESTS
+TESTS =
+!endif
+!ifndef RDOCTARGET
+RDOCTARGET = install-doc
+!endif
+
+OUTFLAG = -o
!ifndef CFLAGS
CFLAGS = -q -tWR -tWC $(DEBUGFLAGS) $(OPTFLAGS) $(PROCESSOR_FLAG) -w- -wsus -wcpt -wdup -wext -wrng -wrpt -wzdi
!endif
@@ -135,6 +154,7 @@ PROGRAM=$(RUBY_INSTALL_NAME)$(EXEEXT)
WPROGRAM=$(RUBYW_INSTALL_NAME)$(EXEEXT)
RUBYDEF = $(RUBY_SO_NAME).def
MINIRUBY = .\miniruby$(EXEEXT)
+RUNRUBY = .\ruby$(EXEEXT) "$(srcdir)runruby.rb" --extout="$(EXTOUT)" --
ORGLIBPATH = $(LIB)
@@ -145,70 +165,46 @@ LIBRUBY_SO = $(RUBY_SO_NAME).dll
LIBRUBY = $(RUBY_SO_NAME).lib
LIBRUBYARG = $(LIBRUBY)
-!ifndef EXTOBJS
-EXTOBJS = dmyext.obj
-!endif
-
-MAINOBJ = main.obj
-WINMAINOBJ = winmain.obj
-
-OBJS = array.obj \
- bignum.obj \
- class.obj \
- compar.obj \
- dir.obj \
- dln.obj \
- enum.obj \
- error.obj \
- eval.obj \
- file.obj \
- gc.obj \
- hash.obj \
- inits.obj \
- io.obj \
- marshal.obj \
- math.obj \
- numeric.obj \
- object.obj \
- pack.obj \
- parse.obj \
- prec.obj \
- process.obj \
- random.obj \
- range.obj \
- re.obj \
- regex.obj \
- ruby.obj \
- signal.obj \
- sprintf.obj \
- st.obj \
- string.obj \
- struct.obj \
- time.obj \
- util.obj \
- variable.obj \
- version.obj \
- $(MISSING)
-
-SCRIPT_ARGS = "--dest-dir=$(DESTDIR)" \
- "--make=$(MAKE)" \
- "--mflags=$(MFLAGS)" \
- "--make-flags=$(MAKEFLAGS)"
-
-all: miniruby$(EXEEXT) rbconfig.rb \
- $(LIBRUBY) $(MISCLIBS)
- .\miniruby$(EXEEXT) $(srcdir)ext/extmk.rb --extstatic=$(EXTSTATIC) $(SCRIPT_ARGS)
+PREP = miniruby$(EXEEXT)
+
+DMYOBJS = dmyext.obj
+OBJEXT = obj
+
+WINMAINOBJ = winmain.$(OBJEXT)
+
+.path.c = .;$(srcdir);$(srcdir)win32;$(srcdir)missing
+.path.h = .;$(srcdir);$(srcdir)win32;$(srcdir)missing
+.path.y = $(srcdir)
+.path. = $(srcdir)
+
+.c.obj:
+ $(CC) $(CFLAGS) $(XCFLAGS) -I. $(CPPFLAGS) -c $(<:/=\)
+
+.rc.res:
+ $(RC) $(RFLAGS) -I. -I$(<D). $(iconinc) -I$(srcdir)win32 $(RFLAGS) -fo$@ $(<:/=\)
+
+.y.c:
+ $(YACC) $(YFLAGS) $(<:\=/)
+ sed -e "s!^ *extern char \*getenv();!/* & */!;s/^\(#.*\)y\.tab/\1parse/" y.tab.c > $(@F)
+ @del y.tab.c
+
+all: $(srcdir)bcc32/Makefile.sub $(srcdir)common.mk
ruby: $(PROGRAM)
rubyw: $(WPROGRAM)
-lib: $(LIBRUBY)
-dll: $(LIBRUBY_SO)
-config: config.h config.status
+!include $(srcdir)/common.mk
-config.h:
- @echo Creating $(@:.\=)
- @type > $@ &&|
+PHONY: Makefile
+
+CONFIG_H = ./.config.h.time
+
+config: config.status
+
+config.status: $(CONFIG_H)
+
+$(CONFIG_H): $(MKFILES) $(srcdir)bcc32/Makefile.sub
+ @$(srcdir:/=\)win32\ifchange.bat config.h &&|
\#define HAVE_SYS_TYPES_H 1
\#define HAVE_SYS_STAT_H 1
\#define HAVE_STDLIB_H 1
@@ -274,7 +270,6 @@ config.h:
\#define STACK_GROW_DIRECTION -1
\#define DEFAULT_KCODE KCODE_NONE
\#define DLEXT ".so"
-\#define DLEXT2 ".dll"
\#define RUBY_LIB "/lib/ruby/$(MAJOR).$(MINOR)"
\#define RUBY_SITE_LIB "/lib/ruby/site_ruby"
\#define RUBY_SITE_LIB2 "/lib/ruby/site_ruby/$(MAJOR).$(MINOR)"
@@ -282,12 +277,14 @@ config.h:
\#define RUBY_ARCHLIB "/lib/ruby/$(MAJOR).$(MINOR)/$(ARCH)-$(OS)"
\#define RUBY_SITE_ARCHLIB "/lib/ruby/site_ruby/$(MAJOR).$(MINOR)/$(ARCH)-$(OS)"
|
+ @exit > $@
-config.status: Makefile $(srcdir)bcc32/Makefile.sub
+config.status: $(MKFILES) $(srcdir)bcc32/Makefile.sub $(srcdir)common.mk
@echo Creating $@
@type > $@ &&|
# Generated automatically by Makefile.sub.
s,@SHELL@,$$(COMSPEC),;t t
+s,@PATH_SEPARATOR@,;,;t t
s,@CFLAGS@,$(CFLAGS),;t t
s,@CPPFLAGS@,$(CPPFLAGS),;t t
s,@CXXFLAGS@,$(CXXFLAGS),;t t
@@ -295,7 +292,7 @@ s,@FFLAGS@,$(FFLAGS),;t t
s,@LDFLAGS@,,;t t
s,@LIBS@,$(LIBS),;t t
s,@exec_prefix@,$${prefix},;t t
-s,@prefix@,,;t t
+s,@prefix@,$(prefix),;t t
s,@program_transform_name@,s,,,,;t t
s,@bindir@,$${exec_prefix}/bin,;t t
s,@sbindir@,$${exec_prefix}/sbin,;t t
@@ -345,12 +342,16 @@ s,@STATIC@,$(STATIC),;t t
s,@CCDLFLAGS@,,;t t
s,@LDSHARED@,$(LDSHARED),;t t
s,@DLEXT@,so,;t t
-s,@DLEXT2@,dll,;t t
s,@LIBEXT@,lib,;t t
s,@STRIP@,$(STRIP),;t t
s,@EXTSTATIC@,$(EXTSTATIC),;t t
s,@setup@,Setup,;t t
s,@MINIRUBY@,$(MINIRUBY),;t t
+s,@PREP@,miniruby$(EXEEXT),;t t
+s,@RUNRUBY@,$(RUNRUBY),;t t
+s,@EXTOUT@,$(EXTOUT),;t t
+s,@ARCHFILE@,,;t t
+s,@RDOCTARGET@,,;t t
s,@LIBRUBY_LDSHARED@,$$(LDSHARED),;t t
s,@LIBRUBY_DLDFLAGS@,-Gi $$(DLDFLAGS),;t t
s,@RUBY_INSTALL_NAME@,$(RUBY_INSTALL_NAME),;t t
@@ -367,7 +368,7 @@ s,@LIBRUBYARG_SHARED@,$$(LIBRUBY),;t t
s,@SOLIBS@,$(SOLIBS),;t t
s,@DLDLIBS@,$(DLDLIBS),;t t
s,@ENABLE_SHARED@,yes,;t t
-s,@OUTFLAG@,-o,;t t
+s,@OUTFLAG@,$(OUTFLAG),;t t
s,@CPPOUTFILE@,,;t t
s,@LIBPATHFLAG@, -L"%s",;t t
s,@RPATHFLAG@,,;t t
@@ -375,8 +376,9 @@ s,@LIBARG@,%s.lib,;t t
s,@LINK_SO@,$$(LDSHARED) $$(DLDFLAGS) $$(LIBPATH) $$(OBJS), $$(@:/=\), nul, $$(LIBS) $$(LOCAL_LIBS), $$(DEFFILE), $$(RESFILE),;t t
s,@COMPILE_C@,$$(CC) $$(CFLAGS) $$(CPPFLAGS) -c $$(<:/=\),;t t
s,@COMPILE_CXX@,$$(CXX) $$(CXXFLAGS) $$(CPPFLAGS) -P -c $$(<:/=\),;t t
-s,@COMPILE_RULES@,{$$(srcdir)}.%s{}.%s: .%s.%s:,;t t
-s,@COMMON_LIBS@,m,;t t
+s,@COMPILE_RULES@,{$$(srcdir)}.%s{}.%s: {$$(topdir)}.%s{}.%s: {$$(hdrdir)}.%s{}.%s: .%s.%s:,;t t
+s,@RULE_SUBST@,{.;$$(VPATH)}%s,;t t
+s,@COMMON_LIBS@,m advapi32 avicap32 avifil32 cap comctl32 comdlg32 dlcapi gdi32 glu32 imagehlp imm32 inetmib1 kernel32 loadperf lsapi32 lz32 mapi32 mgmtapi mpr msacm32 msvfw32 nddeapi netapi32 ole32 oleaut32 oledlg olepro32 opengl32 pdh pkpd32 rasapi32 rasdlg rassapi rpcrt4 setupapi shell32 shfolder snmpapi sporder tapi32 url user32 vdmdbg version win32spl winmm wintrust wsock32,;t t
s,@COMMON_MACROS@,WIN32_LEAN_AND_MEAN;t t
s,@COMMON_HEADERS@,winsock2.h windows.h,;t t
s,@TRY_LINK@,$$(CC) -oconftest $$(INCFLAGS) -I$$(hdrdir) $$(CPPFLAGS) $$(CFLAGS) $$(LIBPATH) $$(LDFLAGS) $$(src) $$(LOCAL_LIBS) $$(LIBS),;t t
@@ -390,9 +392,9 @@ s,@srcdir@,$(srcdir),;t t
s,@top_srcdir@,$(srcdir),;t t
|
-miniruby$(EXEEXT): $(LIBRUBY_A) $(MAINOBJ) dmyext.obj
+miniruby$(EXEEXT):
@echo $(LIBS)
- $(LD) $(LDFLAGS) $(XLDFLAGS) $(MAINOBJ) dmyext.obj,$@,nul,$(LIBRUBY_A) $(LIBS)
+ $(LD) $(LDFLAGS) $(XLDFLAGS) $(MAINOBJ),$@,nul,$(LIBRUBY_A) $(LIBS)
$(PROGRAM): $(MAINOBJ) $(LIBRUBY_SO) $(RUBY_INSTALL_NAME).res
$(LD) $(LDFLAGS) $(XLDFLAGS) $(MAINOBJ),$@,nul,$(LIBRUBYARG) $(LIBS),,$(RUBY_INSTALL_NAME).res
@@ -407,83 +409,14 @@ $(LIBRUBY_A): $(OBJS) dmyext.obj
# $(LIBRUBY): $(LIBRUBY_SO)
# implib $@ $(LIBRUBY_SO)
-$(LIBRUBY_SO) $(LIBRUBY): $(LIBRUBY_A) $(EXTOBJS) $(RUBYDEF) $(RUBY_SO_NAME).res
+$(LIBRUBY_SO): $(LIBRUBY_A) $(EXTOBJS) $(RUBYDEF) $(RUBY_SO_NAME).res
@echo $(EXTOBJS)
$(LIBRUBY_LDSHARED) $(LIBRUBY_DLDFLAGS) $(EXTOBJS:/=\),$(LIBRUBY_SO),nul,$(LIBRUBY_A) $(LIBS),$(RUBYDEF),$(RUBY_SO_NAME).res
-$(RUBYDEF): $(LIBRUBY_A) miniruby$(EXEEXT)
- $(MINIRUBY) $(srcdir)bcc32/mkexports.rb -output=$@ $(LIBRUBY_A)
-
-install: rbconfig.rb
- $(MINIRUBY) $(srcdir)instruby.rb $(SCRIPT_ARGS)
- $(MINIRUBY) $(srcdir)ext/extmk.rb $(SCRIPT_ARGS) install
-
-what-where no-install: rbconfig.rb
- $(MINIRUBY) $(srcdir)instruby.rb -n $(SCRIPT_ARGS)
- $(MINIRUBY) $(srcdir)ext/extmk.rb -n $(SCRIPT_ARGS) install
-
-clean: clean-ext clean-local
-
-clean-local:
- @if exist $(LIBRUBY_A) del $(LIBRUBY_A)
- @if exist $(MAINOBJ) del $(MAINOBJ)
- @if exist rbconfig.rb del rbconfig.rb
- @if exist ext\extinit.c del ext\extinit.c
- @if exist ext\extinit.obj del ext\extinit.obj
- @if exist ext\vc*.pdb del ext\vc*.pdb
- @if exist *.obj del *.obj
- @if exist *.res del *.res
- @if exist *.tds del *.tds
- @if exist *.il? del *.il?
-
-clean-ext:
- @-$(MINIRUBY) $(srcdir)ext/extmk.rb $(SCRIPT_ARGS) clean
-
-distclean: distclean-ext distclean-local
-
-distclean-local: clean-local
- @if exist Makefile del Makefile
- @if exist config.h del config.h
- @if exist ext\config.cache del ext\config.cache
- @if exist config.cache del config.cache
- @if exist config.log del config.log
- @if exist config.status del config.status
- @if exist *~ del *~
- @if exist *.bak del *.bak
- @if exist *.stackdump del *.stackdump
- @if exist *.core del *.core
- @if exist gmon.out del gmon.out
- @if exist y.tab.c del y.tab.c
- @if exist y.output del y.output
- @if exist *.map del *.map
- @if exist *.pdb del *.pdb
- @if exist *.ilk del *.ilk
- @if exist *.exp del *.exp
- @if exist $(RUBYDEF) del $(RUBYDEF)
- @if exist $(RUBY_INSTALL_NAME).rc del $(RUBY_INSTALL_NAME).rc
- @if exist $(RUBYW_INSTALL_NAME).rc del $(RUBYW_INSTALL_NAME).rc
- @if exist $(RUBY_SO_NAME).rc del $(RUBY_SO_NAME).rc
- @if exist $(PROGRAM) del $(PROGRAM)
- @if exist $(WPROGRAM) del $(WPROGRAM)
- @if exist $(LIBRUBY_SO) del $(LIBRUBY_SO)
- @if exist $(LIBRUBY) del $(LIBRUBY)
- @if exist ext\nul if not exist ext\* rmdir ext
- @if exist miniruby$(EXEEXT) del miniruby$(EXEEXT)
-
-distclean-ext:
- @-$(MINIRUBY) $(srcdir)ext/extmk.rb $(SCRIPT_ARGS) distclean
-
-realclean: distclean
- @if exist parse.c del parse.c
- @if exist lex.c del lex.c
-
-test: miniruby$(EXEEXT) rbconfig.rb $(PROGRAM) NUL
- @$(MINIRUBY) $(srcdir)rubytest.rb
-
-rbconfig.rb: miniruby$(EXEEXT) config.status
- @$(MINIRUBY) $(srcdir)mkconfig.rb -srcdir=$(srcdir) \
- -install_name=$(RUBY_INSTALL_NAME) \
- -so_name=$(RUBY_SO_NAME) rbconfig.rb
+$(LIBRUBY): $(LIBRUBY_SO)
+
+$(RUBYDEF): $(LIBRUBY_A) $(PREP)
+ $(MINIRUBY) $(srcdir)bcc32/mkexports.rb -output=$@ -base=$(RUBY_SO_NAME) $(LIBRUBY_A)
$(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(RUBY_SO_NAME).rc: rbconfig.rb
@$(MINIRUBY) $(srcdir)win32/resource.rb \
@@ -492,95 +425,56 @@ $(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(RUBY_SO_NAME).rc: rbconfig.rb
-so_name=$(RUBY_SO_NAME) \
. $(icondirs) $(srcdir)win32
-#config.status: $(srcdir)configure
-# $(SHELL) .config.status --recheck
-
-.path.c = .;$(srcdir);$(srcdir)win32;$(srcdir)missing
-.path.h = .;$(srcdir);$(srcdir)win32;$(srcdir)missing
-.path.y = $(srcdir)
-
-.c.obj:
- $(CC) $(CFLAGS) $(XCFLAGS) -I. $(CPPFLAGS) -c $(<:/=\)
+post-install-ext::
+ $(MINIRUBY) -I$(srcdir)lib -rrbconfig -rfileutils \
+ -e 'FileUtils.rm_f(Dir[File.join(Config::CONFIG["archdir"],"**","*.tds")])'
-.rc.res:
- $(RC) $(RFLAGS) -I. -I$(<D). $(iconinc) -I$(srcdir)win32 $(RFLAGS) -fo$@ $(<:/=\)
-
-.y.c:
- $(YACC) $(YFLAGS) $(<:\=/)
- sed -e "s!^ *extern char \*getenv();!/* & */!;s/^\(#.*\)y\.tab/\1parse/" y.tab.c > $(@F)
- @del y.tab.c
+clean-local::
+ @$(RM) ext\extinit.c ext\extinit.$(OBJEXT) *.tds *.il? $(RUBY_SO_NAME).lib
+ @$(RM) $(RUBY_INSTALL_NAME).res $(RUBYW_INSTALL_NAME).res $(RUBY_SO_NAME).res
-parse.c: parse.y
+distclean-local::
+ @$(RM) ext\config.cache $(RBCONFIG:/=\)
+ @$(RM) *.map *.pdb *.ilk *.exp $(RUBYDEF)
+ @$(RM) $(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(RUBY_SO_NAME).rc
ext/extinit.obj: ext/extinit.c $(SETUP)
$(CC) $(CFLAGS) $(XCFLAGS) $(CPPFLAGS) -o$@ -c ext/extinit.c
-acosh.obj: acosh.c win32.h
-alloca.obj: alloca.c win32.h
-crypt.obj: crypt.c win32.h
-dup2.obj: dup2.c win32.h
-erf.obj: erf.c win32.h
-finite.obj: finite.c win32.h
-flock.obj: flock.c win32.h
-memcmp.obj: memcmp.c win32.h
-memmove.obj: memmove.c win32.h
-mkdir.obj: mkdir.c win32.h
-vsnprintf.obj: vsnprintf.c win32.h
-strcasecmp.obj: strcasecmp.c win32.h
-strncasecmp.obj: strncasecmp.c win32.h
-strchr.obj: strchr.c win32.h
-strdup.obj: strdup.c win32.h
-strerror.obj: strerror.c win32.h
-strftime.obj: strftime.c win32.h
-strstr.obj: strstr.c win32.h
-strtod.obj: strtod.c win32.h
-strtol.obj: strtol.c win32.h
-strtoul.obj: strtoul.c win32.h
-nt.obj: nt.c win32.h
-x68.obj: x68.c win32.h
-os2.obj: os2.c win32.h
-dl_os2.obj: dl_os2.c win32.h
-
-# when I use -I., there is confliction at "OpenFile"
-# so, set . into environment varible "include"
-win32.obj: win32.c win32.h
-
-###
-array.obj: array.c ruby.h config.h defines.h intern.h missing.h util.h st.h win32.h
-bignum.obj: bignum.c ruby.h config.h defines.h intern.h missing.h win32.h
-class.obj: class.c ruby.h config.h defines.h intern.h missing.h rubysig.h node.h st.h win32.h
-compar.obj: compar.c ruby.h config.h defines.h intern.h missing.h win32.h
-dir.obj: dir.c ruby.h config.h defines.h intern.h missing.h util.h win32.h
-dln.obj: dln.c ruby.h config.h defines.h intern.h missing.h dln.h win32.h
-dmyext.obj: dmyext.c
-enum.obj: enum.c ruby.h config.h defines.h intern.h missing.h node.h util.h win32.h
-error.obj: error.c ruby.h config.h defines.h intern.h missing.h env.h st.h win32.h
-eval.obj: eval.c ruby.h config.h defines.h intern.h missing.h node.h env.h util.h rubysig.h st.h dln.h win32.h
-file.obj: file.c ruby.h config.h defines.h intern.h missing.h rubyio.h rubysig.h util.h dln.h win32.h
-gc.obj: gc.c ruby.h config.h defines.h intern.h missing.h rubysig.h st.h node.h env.h re.h regex.h win32.h
-hash.obj: hash.c ruby.h config.h defines.h intern.h missing.h st.h util.h rubysig.h win32.h
-inits.obj: inits.c ruby.h config.h defines.h intern.h missing.h win32.h
-io.obj: io.c ruby.h config.h defines.h intern.h missing.h rubyio.h rubysig.h env.h util.h win32.h
-main.obj: main.c ruby.h config.h defines.h intern.h missing.h win32.h
-marshal.obj: marshal.c ruby.h config.h defines.h intern.h missing.h rubyio.h st.h util.h win32.h
-math.obj: math.c ruby.h config.h defines.h intern.h missing.h win32.h
-numeric.obj: numeric.c ruby.h config.h defines.h intern.h missing.h win32.h
-object.obj: object.c ruby.h config.h defines.h intern.h missing.h st.h util.h win32.h
-pack.obj: pack.c ruby.h config.h defines.h intern.h missing.h win32.h
-parse.obj: parse.c ruby.h config.h defines.h intern.h missing.h env.h node.h st.h regex.h util.h lex.c win32.h
-prec.obj: prec.c ruby.h config.h defines.h intern.h missing.h win32.h
-process.obj: process.c ruby.h config.h defines.h intern.h missing.h rubysig.h st.h win32.h
-random.obj: random.c ruby.h config.h defines.h intern.h missing.h win32.h
-range.obj: range.c ruby.h config.h defines.h intern.h missing.h win32.h
-re.obj: re.c ruby.h config.h defines.h intern.h missing.h re.h regex.h win32.h
-regex.obj: regex.c config.h regex.h win32.h
-ruby.obj: ruby.c ruby.h config.h defines.h intern.h missing.h dln.h node.h util.h win32.h
-signal.obj: signal.c ruby.h config.h defines.h intern.h missing.h rubysig.h win32.h
-sprintf.obj: sprintf.c ruby.h config.h defines.h intern.h missing.h win32.h
-st.obj: st.c config.h st.h
-string.obj: string.c ruby.h config.h defines.h intern.h missing.h re.h regex.h win32.h
-struct.obj: struct.c ruby.h config.h defines.h intern.h missing.h win32.h
-time.obj: time.c ruby.h config.h defines.h intern.h missing.h win32.h
-util.obj: util.c ruby.h config.h defines.h intern.h missing.h util.h win32.h
-variable.obj: variable.c ruby.h config.h defines.h intern.h missing.h env.h node.h st.h util.h win32.h
-version.obj: version.c ruby.h config.h defines.h intern.h missing.h version.h win32.h
+main.$(OBJEXT): win32.h
+array.$(OBJEXT): win32.h
+bignum.$(OBJEXT): win32.h
+class.$(OBJEXT): win32.h
+compar.$(OBJEXT): win32.h
+dir.$(OBJEXT): dir.h win32.h
+dln.$(OBJEXT): win32.h
+enum.$(OBJEXT): win32.h
+error.$(OBJEXT): win32.h
+eval.$(OBJEXT): win32.h
+file.$(OBJEXT): win32.h
+gc.$(OBJEXT): win32.h
+hash.$(OBJEXT): win32.h
+inits.$(OBJEXT): win32.h
+io.$(OBJEXT): win32.h
+marshal.$(OBJEXT): win32.h
+math.$(OBJEXT): win32.h
+numeric.$(OBJEXT): win32.h
+object.$(OBJEXT): win32.h
+pack.$(OBJEXT): win32.h
+parse.$(OBJEXT): win32.h
+process.$(OBJEXT): win32.h
+prec.$(OBJEXT): win32.h
+random.$(OBJEXT): win32.h
+range.$(OBJEXT): win32.h
+re.$(OBJEXT): win32.h
+regex.$(OBJEXT): win32.h
+ruby.$(OBJEXT): win32.h
+signal.$(OBJEXT): win32.h
+sprintf.$(OBJEXT): win32.h
+st.$(OBJEXT): win32.h
+string.$(OBJEXT): win32.h
+struct.$(OBJEXT): win32.h
+time.$(OBJEXT): win32.h
+util.$(OBJEXT): win32.h
+variable.$(OBJEXT): win32.h
+version.$(OBJEXT): win32.h
diff --git a/bcc32/configure.bat b/bcc32/configure.bat
index 449b6e2..91a4028 100644
--- a/bcc32/configure.bat
+++ b/bcc32/configure.bat
@@ -8,25 +8,79 @@ echo>> ~tmp~.mak conf = %0
echo>> ~tmp~.mak $(conf:\=/): nul
echo>> ~tmp~.mak @del ~tmp~.mak
echo>> ~tmp~.mak @-$(MAKE) -l$(MAKEFLAGS) -f $(@D)setup.mak \
-echo>> ~tmp~.mak bcc32dir="$(@D)" \
:loop
if "%1" == "" goto :end
+if "%1" == "--prefix" goto :prefix
if "%1" == "--srcdir" goto :srcdir
if "%1" == "srcdir" goto :srcdir
if "%1" == "--target" goto :target
if "%1" == "target" goto :target
- echo>> ~tmp~.mak "%1"
+if "%1" == "--with-static-linked-ext" goto :extstatic
+if "%1" == "--program-suffix" goto :suffix
+if "%1" == "--program-name" goto :progname
+if "%1" == "--enable-install-doc" goto :enable-rdoc
+if "%1" == "--disable-install-doc" goto :disable-rdoc
+if "%1" == "-h" goto :help
+if "%1" == "--help" goto :help
+ echo>> ~tmp~.mak "%1" \
shift
goto :loop
:srcdir
- echo>> ~tmp~.mak "srcdir=%2"
+ echo>> ~tmp~.mak -D"srcdir=%2" \
+ shift
+ shift
+goto :loop
+:prefix
+ echo>> ~tmp~.mak -D"prefix=%2" \
+ shift
+ shift
+goto :loop
+:suffix
+ echo>> ~tmp~.mak -D"RUBY_SUFFIX=%2" \
+ shift
+ shift
+goto :loop
+:installname
+ echo>> ~tmp~.mak -D"RUBY_INSTALL_NAME=%2" \
+ shift
+ shift
+goto :loop
+:soname
+ echo>> ~tmp~.mak -D"RUBY_SO_NAME=%2" \
shift
shift
goto :loop
:target
- echo>> ~tmp~.mak %2
+ echo>> ~tmp~.mak "%2" \
shift
shift
goto :loop
+:extstatic
+ echo>> ~tmp~.mak -D"EXTSTATIC=static" \
+ shift
+goto :loop
+:enable-rdoc
+ echo>> ~tmp~.mak -D"RDOCTARGET=install-doc" \
+ shift
+goto :loop
+:disable-rdoc
+ echo>> ~tmp~.mak -D"RDOCTARGET=install-nodoc" \
+ shift
+goto :loop
+:help
+ echo Configuration:
+ echo --help display this help
+ echo --srcdir=DIR find the sources in DIR [configure dir or `..']
+ echo Installation directories:
+ echo --prefix=PREFIX install files in PREFIX [/usr]
+ echo System types:
+ echo --target=TARGET configure for TARGET [i386-bccwin32]
+ echo Optional Package:
+ echo --with-static-linked-ext link external modules statically
+ echo --enable-install-doc install rdoc indexes during install
+ del ~tmp~.mak
+goto :exit
:end
+echo>> ~tmp~.mak bcc32dir="$(@D)"
make -s -f ~tmp~.mak
+:exit