1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

2000-06-24

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
eban 2000-06-24 14:06:35 +00:00
parent 552fb72159
commit e551412777
9 changed files with 137 additions and 90 deletions

21
djgpp/README.djgpp Normal file
View file

@ -0,0 +1,21 @@
* How to compile and install on djgpp
This is what you need to do to compile and install Ruby:
1. Run configure.bat, which will generate config.h and Makefile
and ext/extmk.rb(GNU sed required).
Message like this is normal:
sed.exe: can't read 123456789: No such file or directory (ENOENT)
2. Edit defines.h if you need. Probably this step will not need.
3. Remove comment mark(#) before the module names from ext/Setup.dj (or
add module names if not present).
4. Run make.
5. Optionally, run 'make test' to check whether the compiled Ruby
interpreter works well. If you see the message "test succeeded",
your ruby works as it should (hopefully).
6. Run 'make install'

72
djgpp/config.hin Normal file
View file

@ -0,0 +1,72 @@
#define USE_THREAD 1
#define SIZEOF_INT 4
#define SIZEOF_SHORT 2
#define SIZEOF_LONG 4
#define SIZEOF_VOIDP 4
#define SIZEOF_FLOAT 4
#define SIZEOF_DOUBLE 8
#define HAVE_PROTOTYPES 1
#define TOKEN_PASTE(x,y) x##y
#define HAVE_STDARG_PROTOTYPES 1
#define HAVE_ATTR_NORETURN 1
#define HAVE_DIRENT_H 1
#define STDC_HEADERS 1
#define HAVE_STDLIB_H 1
#define HAVE_UNISTD_H 1
#define HAVE_LIMITS_H 1
#define HAVE_SYS_FILE_H 1
#define HAVE_SYS_IOCTL_H 1
#define HAVE_PWD_H 1
#define HAVE_SYS_TIME_H 1
#define HAVE_SYS_TIMES_H 1
#define HAVE_SYS_PARAM_H 1
#define HAVE_SYS_WAIT_H 1
#define HAVE_STRING_H 1
#define HAVE_UTIME_H 1
#define HAVE_MEMORY_H 1
#define HAVE_DIRECT_H 1
#define HAVE_ST_BLKSIZE 1
#define HAVE_ST_RDEV 1
#define GETGROUPS_T gid_t
#define RETSIGTYPE void
#define HAVE_ALLOCA 1
#define vfork fork
#define HAVE_DUP2 1
#define HAVE_SETENV 1
#define HAVE_MEMMOVE 1
#define HAVE_MKDIR 1
#define HAVE_STRCASECMP 1
#define HAVE_STRERROR 1
#define HAVE_STRFTIME 1
#define HAVE_STRCHR 1
#define HAVE_STRSTR 1
#define HAVE_STRTOUL 1
#define HAVE_STRDUP 1
#define HAVE_ISINF 1
#define HAVE_ISNAN 1
#define HAVE_FINITE 1
#define HAVE_FMOD 1
#define HAVE_RANDOM 1
#define HAVE_WAITPID 1
#define HAVE_GETCWD 1
#define HAVE_TRUNCATE 1
#define HAVE_CHSIZE 1
#define HAVE_TIMES 1
#define HAVE_UTIMES 1
#define HAVE_FCNTL_H 1
/*#define HAVE_SETITIMER 1*/
#define HAVE_GETGROUPS 1
#define HAVE_SIGPROCMASK 1
#define HAVE_SIGACTION 1
#define HAVE_SETSID 1
#define POSIX_SIGNAL 1
#define BSD_SETPGRP setpgrp
#define RSHIFT(x,y) ((x)>>y)
#define FILE_COUNT _cnt
#define DLEXT ".o"
#define RUBY_LIB "/usr/local/lib/ruby/@MAJOR@.@MINOR@"
#define RUBY_SITE_LIB "/usr/local/lib/ruby/site_ruby"
#define RUBY_SITE_LIB2 "/usr/local/lib/ruby/site_ruby/@MAJOR@.@MINOR@"
#define RUBY_PLATFORM "i386-msdosdjgpp"
#define RUBY_ARCHLIB "/usr/local/lib/ruby/@MAJOR@.@MINOR@/i386-msdosdjgpp"
#define RUBY_SITE_ARCHLIB "/usr/local/lib/ruby/site_ruby/@MAJOR@.@MINOR@/i386-msdosdjgpp"

76
djgpp/config.status Normal file
View file

@ -0,0 +1,76 @@
/^SHELL/s,/bin/sh,$(COMPSEC),
s%@srcdir@%.%g
s%@top_srcdir@%..%
s%@CFLAGS@%-O2%g
s%@CPPFLAGS@%%g
s%@CXXFLAGS@%%g
s%@LDFLAGS@%%g
s%@LIBS@%-lm %g
s%@exec_prefix@%${prefix}%g
s%@prefix@%/usr/local%g
s%@program_transform_name@%s,x,x,%g
s%@bindir@%${exec_prefix}/bin%g
s%@sbindir@%${exec_prefix}/sbin%g
s%@libexecdir@%${exec_prefix}/libexec%g
s%@datadir@%${prefix}/share%g
s%@sysconfdir@%${prefix}/etc%g
s%@sharedstatedir@%${prefix}/com%g
s%@localstatedir@%${prefix}/var%g
s%@libdir@%${exec_prefix}/lib%g
s%@includedir@%${prefix}/include%g
s%@oldincludedir@%/usr/include%g
s%@infodir@%${prefix}/info%g
s%@mandir@%${prefix}/man%g
s%@host@%i386-pc-msdosdjgpp%g
s%@host_alias@%i386-msdosdjgpp%g
s%@host_cpu@%i386%g
s%@host_vendor@%pc%g
s%@host_os@%msdosdjgpp%g
s%@CC@%gcc%g
s%@CPP@%gcc -E%g
s%@YACC@%bison -y%g
s%@RANLIB@%ranlib%g
s%@AR@%ar%g
s%@INSTALL_PROGRAM@%${INSTALL}%g
s%@INSTALL_DATA@%${INSTALL} -m 644%g
s%@SET_MAKE@%%g
s%@LIBOBJS@% crypt.o flock.o vsnprintf.o%g
s%@ALLOCA@%%g
s%@DEFAULT_KCODE@%%g
s%@EXEEXT@%.exe%g
s%@OBJEXT@%o%g
s%@XLDFLAGS@%%g
s%@DLDFLAGS@%%g
s%@STATIC@%%g
s%@CCDLFLAGS@%%g
s%@LDSHARED@%ld%g
s%@DLEXT@%o%g
s%@STRIP@%strip%g
s%@EXTSTATIC@%%g
s%@binsuffix@%.exe%g
s%@setup@%Setup.dj%g
s%@LIBRUBY@%libruby.a%g
s%@LIBRUBY_A@%libruby.a%g
s%@LIBRUBYARG@%libruby.a%g
s%@LIBRUBY_SO@%%g
s%@SOLIBS@%%g
s%@arch@%i386-msdosdjgpp%g
;s%/bin/rm%rm%
s%@DLDLIBS@%-lc%g
s%@PREP@%%
s%@RUBY_INSTALL_NAME@%ruby%g
s%@arch@%i386-msdosdjgpp%g
s%@sitedir@%${prefix}/lib/ruby/site_ruby%g
s%@MINIRUBY@%./miniruby%
s%@archlib@%/usr/local/lib/ruby/i386-msdosdjgpp%
;s%|| true%%
;/\/dev\/null/ {
;s,/dev/null 2>&1, nul,
;s,2> /dev/null,,
;}
;/^config.status/ {
; N;N;N;N;N;d
;}
;s%y\.tab\.c%y_tab.c%
/^,THIS_IS_DUMMY_PATTERN_/i\
ac_given_srcdir=.

25
djgpp/configure.bat Normal file
View file

@ -0,0 +1,25 @@
@echo off
set _dj_=djgpp
if exist djgpp\nul goto top
cd ..
:top
if exist %_dj_%\version.sed goto exist
sed -n -f %_dj_%\mkver.sed < version.h > %_dj_%\version.sed
:exist
set _convert_=-f %_dj_%\config.status -f %_dj_%\version.sed
sed %_convert_% < Makefile.in > Makefile
sed %_convert_% < ext\extmk.rb.in > ext\extmk.rb
sed %_convert_% < %_dj_%\config.hin > config.h
echo LFN check > 12345678
sed -n /LFN/d 123456789 > nul
if errorlevel 2 goto LFN
copy missing\vsnprintf.c missing\vsnprint.c > nul
copy %_dj_%\config.status config.sta > nul
goto end
:LFN
copy %_dj_%\config.status config.status > nul
:end
set _dj_=
set _convert_=
del 12345678
echo Now you must run a make.

1
djgpp/mkver.sed Normal file
View file

@ -0,0 +1 @@
/RUBY_VERSION /s/^.*\([0-9][0-9]*\)\.\([0-9][0-9]*\)\.\([0-9][0-9]*\).*$/s,@MAJOR@,\1,;s,@MINOR@,\2,;s,@TEENY@,\3,/p