1998-01-16 07:13:05 -05:00
|
|
|
dnl Process this file with autoconf to produce a configure script.
|
2002-04-21 12:05:52 -04:00
|
|
|
AC_INIT()
|
1998-01-16 07:13:05 -05:00
|
|
|
|
2002-03-14 01:23:46 -05:00
|
|
|
AC_PREREQ(2.50)
|
|
|
|
|
2002-09-23 07:01:49 -04:00
|
|
|
AC_DEFUN(RUBY_MINGW32,
|
|
|
|
[case "$host_os" in
|
|
|
|
cygwin*)
|
|
|
|
AC_CACHE_CHECK(for mingw32 environment, rb_cv_mingw32,
|
|
|
|
[AC_TRY_CPP([
|
|
|
|
#ifndef __MINGW32__
|
|
|
|
# error
|
|
|
|
#endif
|
|
|
|
], rb_cv_mingw32=yes,rb_cv_mingw32=no)
|
|
|
|
rm -f conftest*])
|
|
|
|
test "$rb_cv_mingw32" = yes && target_os="mingw32"
|
|
|
|
;;
|
|
|
|
esac])
|
|
|
|
|
|
|
|
AC_DEFUN(RUBY_CPPOUTFILE,
|
|
|
|
[cppflags=$CPPFLAGS
|
2002-10-21 12:09:09 -04:00
|
|
|
AC_CACHE_CHECK(whether ${CPP} accepts -o, rb_cv_cppoutfile,
|
|
|
|
[CPPFLAGS='-o conftest.i'
|
|
|
|
AC_TRY_CPP([], rb_cv_cppoutfile="$CPPFLAGS", rb_cv_cppoutfile=' >conftest.i')
|
2002-09-23 07:01:49 -04:00
|
|
|
rm -f conftest*])
|
2002-10-21 12:09:09 -04:00
|
|
|
CPPOUTFILE="$rb_cv_cppoutfile"
|
|
|
|
AC_SUBST(CPPOUTFILE)
|
|
|
|
CPPFLAGS=$cppflags])
|
2002-09-23 07:01:49 -04:00
|
|
|
|
2002-10-04 01:18:05 -04:00
|
|
|
AC_DEFUN(RUBY_PROG_GNU_LD,
|
|
|
|
[AC_CACHE_CHECK(whether the linker is GNU ld, rb_cv_prog_gnu_ld,
|
|
|
|
[if `$CC --print-prog-name=ld` -v 2>&1 | grep "GNU ld" > /dev/null; then
|
|
|
|
rb_cv_prog_gnu_ld=yes
|
|
|
|
else
|
|
|
|
rb_cv_prog_gnu_ld=no
|
|
|
|
fi
|
|
|
|
])
|
|
|
|
GNU_LD=$rb_cv_prog_gnu_ld
|
|
|
|
AC_SUBST(GNU_LD)])
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_version=`grep RUBY_VERSION $srcdir/version.h`
|
|
|
|
MAJOR=`expr "$rb_version" : '#define RUBY_VERSION "\([0-9][0-9]*\)\.[0-9][0-9]*\.[0-9][0-9]*"'`
|
|
|
|
MINOR=`expr "$rb_version" : '#define RUBY_VERSION "[0-9][0-9]*\.\([0-9][0-9]*\)\.[0-9][0-9]*"'`
|
|
|
|
TEENY=`expr "$rb_version" : '#define RUBY_VERSION "[0-9][0-9]*\.[0-9][0-9]*\.\([0-9][0-9]*\)"'`
|
|
|
|
AC_SUBST(MAJOR)
|
|
|
|
AC_SUBST(MINOR)
|
|
|
|
AC_SUBST(TEENY)
|
1998-01-16 07:13:05 -05:00
|
|
|
dnl checks for alternative programs
|
2002-04-11 23:24:52 -04:00
|
|
|
AC_ARG_WITH(gcc, [ --without-gcc never use gcc], [
|
1998-01-16 07:13:05 -05:00
|
|
|
case $withval in
|
2001-11-13 05:53:20 -05:00
|
|
|
no) : ${CC=cc}
|
2001-12-02 09:10:27 -05:00
|
|
|
;;
|
2001-11-13 05:53:20 -05:00
|
|
|
yes) : ${CC=gcc}
|
2001-12-02 09:10:27 -05:00
|
|
|
;;
|
1998-01-16 07:13:05 -05:00
|
|
|
*) CC=$withval
|
2001-12-02 09:10:27 -05:00
|
|
|
;;
|
|
|
|
esac])
|
1998-01-16 07:13:05 -05:00
|
|
|
dnl If the user switches compilers, we can't believe the cache
|
|
|
|
if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
|
|
|
|
then
|
2002-04-19 03:39:40 -04:00
|
|
|
AC_MSG_ERROR(cached CC is different -- throw away $cache_file
|
1998-01-16 07:13:05 -05:00
|
|
|
(it is also a good idea to do 'make clean' before compiling))
|
|
|
|
fi
|
|
|
|
|
2002-09-08 05:08:15 -04:00
|
|
|
if test "$program_prefix" = NONE; then
|
|
|
|
program_prefix=
|
|
|
|
fi
|
2000-07-03 05:08:37 -04:00
|
|
|
AC_CANONICAL_TARGET
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
dnl checks for fat-binary
|
|
|
|
fat_binary=no
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_ARG_ENABLE(fat-binary,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --enable-fat-binary build a NeXT/Apple Multi Architecture Binary. ],
|
1999-08-13 01:45:20 -04:00
|
|
|
[fat_binary=$enableval])
|
1999-01-19 23:59:39 -05:00
|
|
|
if test "$fat_binary" = yes ; then
|
1998-01-16 07:13:05 -05:00
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_MSG_CHECKING(target architecture)
|
1998-01-16 07:13:05 -05:00
|
|
|
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1999-01-19 23:59:39 -05:00
|
|
|
rhapsody*)
|
|
|
|
echo -n "MacOS X Server: "
|
1999-08-13 01:45:20 -04:00
|
|
|
if test "$TARGET_ARCHS" = "" ; then
|
|
|
|
TARGET_ARCHS="ppc i386"
|
|
|
|
fi
|
1999-01-19 23:59:39 -05:00
|
|
|
;;
|
|
|
|
nextstep*|openstep*)
|
|
|
|
echo -n "NeXTSTEP/OPENSTEP: "
|
|
|
|
if test "$TARGET_ARCHS" = "" ; then
|
|
|
|
if test `/usr/bin/arch` = "m68k" ; then
|
|
|
|
TARGET_ARCHS="m68k i486"
|
|
|
|
else # Black and Native one
|
|
|
|
TARGET_ARCHS="m68k `/usr/bin/arch`"
|
|
|
|
fi
|
|
|
|
fi
|
2000-08-01 05:25:37 -04:00
|
|
|
# to ensure AC_HEADER_SYS_WAIT works
|
|
|
|
AC_DEFINE(_POSIX_SOURCE)
|
1999-01-19 23:59:39 -05:00
|
|
|
;;
|
2000-10-02 03:48:42 -04:00
|
|
|
macos*|darwin*)
|
2000-08-28 05:53:42 -04:00
|
|
|
echo -n "MacOS X (Darwin): "
|
2000-10-02 03:48:42 -04:00
|
|
|
if test "$TARGET_ARCHS" = "" ; then
|
|
|
|
TARGET_ARCHS="ppc i386"
|
|
|
|
fi
|
2000-08-28 05:53:42 -04:00
|
|
|
;;
|
1999-01-19 23:59:39 -05:00
|
|
|
esac
|
1998-01-16 07:13:05 -05:00
|
|
|
# /usr/lib/arch_tool -archify_list $TARGET_ARCHS
|
|
|
|
for archs in $TARGET_ARCHS
|
|
|
|
do
|
|
|
|
ARCH_FLAG="$ARCH_FLAG -arch $archs "
|
|
|
|
echo -n " $archs"
|
|
|
|
done
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_DEFINE(NEXT_FAT_BINARY)
|
1998-01-16 07:13:05 -05:00
|
|
|
echo "."
|
|
|
|
fi
|
|
|
|
|
2001-02-28 01:30:03 -05:00
|
|
|
case $target_cpu in
|
|
|
|
i?86) frame_address=yes;;
|
|
|
|
*) frame_address=no;;
|
|
|
|
esac
|
|
|
|
AC_ARG_ENABLE(frame-address,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --enable-frame-address use GCC __builtin_frame_address(). ],
|
2001-02-28 01:30:03 -05:00
|
|
|
[frame_address=$enableval])
|
|
|
|
if test $frame_address = yes; then
|
|
|
|
AC_DEFINE(USE_BUILTIN_FRAME_ADDRESS)
|
|
|
|
fi
|
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_ARG_PROGRAM
|
|
|
|
|
|
|
|
dnl Checks for programs.
|
2000-01-31 22:12:21 -05:00
|
|
|
|
|
|
|
if test x"${build}" != x"${host}"; then
|
|
|
|
AC_CHECK_TOOL(CC, gcc)
|
|
|
|
fi
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_PROG_CC
|
|
|
|
AC_PROG_GCC_TRADITIONAL
|
2000-01-31 22:12:21 -05:00
|
|
|
|
2002-10-04 01:18:05 -04:00
|
|
|
RUBY_PROG_GNU_LD
|
2002-09-23 07:01:49 -04:00
|
|
|
RUBY_CPPOUTFILE
|
|
|
|
|
2002-09-15 08:57:21 -04:00
|
|
|
OUTFLAG='-o '
|
|
|
|
AC_SUBST(OUTFLAG)
|
|
|
|
|
2002-09-23 07:01:49 -04:00
|
|
|
RUBY_MINGW32
|
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_PROG_YACC
|
2000-01-31 22:12:21 -05:00
|
|
|
AC_CHECK_TOOL(RANLIB, ranlib, :)
|
2002-08-28 02:01:58 -04:00
|
|
|
AC_CHECK_TOOL(AR, ar)
|
2002-08-28 03:38:25 -04:00
|
|
|
if test -z "$AR"; then
|
|
|
|
AC_CHECK_PROGS(AR, aal, ar)
|
|
|
|
fi
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2000-01-31 22:12:21 -05:00
|
|
|
case "$target_os" in
|
2001-01-31 09:27:37 -05:00
|
|
|
cygwin*|mingw*)
|
|
|
|
AC_CHECK_TOOL(NM, nm)
|
|
|
|
AC_CHECK_TOOL(WINDRES, windres)
|
2002-06-11 06:26:13 -04:00
|
|
|
AC_CHECK_TOOL(DLLWRAP, dllwrap)
|
2001-11-30 04:17:30 -05:00
|
|
|
target_cpu=`echo $target_cpu | sed s/i.86/i386/`
|
|
|
|
: ${enable_shared=yes}
|
2001-01-31 09:27:37 -05:00
|
|
|
;;
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
aix*)
|
|
|
|
AC_CHECK_TOOL(NM, nm, /usr/ccs/bin/nm, /usr/ccs/bin:$PATH)
|
|
|
|
;;
|
2000-01-31 22:12:21 -05:00
|
|
|
esac
|
|
|
|
|
2002-05-02 03:50:36 -04:00
|
|
|
# by TOYODA Eizi <toyoda@npd.kishou.go.jp>
|
|
|
|
case "$target_os" in
|
|
|
|
hiuxmpp*)
|
|
|
|
AC_DEFINE(__HIUX_MPP__)
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_PROG_LN_S
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_PROG_MAKE_SET
|
|
|
|
|
|
|
|
# checks for UNIX variants that set C preprocessor variables
|
2000-08-01 05:25:37 -04:00
|
|
|
AC_AIX
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_MINIX
|
|
|
|
|
2002-03-14 01:23:46 -05:00
|
|
|
dnl check for large file stuff
|
|
|
|
AC_SYS_LARGEFILE
|
|
|
|
|
|
|
|
AC_CHECK_TYPES([long long, off_t])
|
2002-04-19 03:39:40 -04:00
|
|
|
|
1999-11-10 01:47:11 -05:00
|
|
|
AC_CHECK_SIZEOF(int, 4)
|
|
|
|
AC_CHECK_SIZEOF(short, 2)
|
|
|
|
AC_CHECK_SIZEOF(long, 4)
|
2000-10-31 03:37:47 -05:00
|
|
|
AC_CHECK_SIZEOF(long long, 0)
|
2000-11-02 04:04:54 -05:00
|
|
|
AC_CHECK_SIZEOF(__int64, 0)
|
2002-03-14 01:23:46 -05:00
|
|
|
AC_CHECK_SIZEOF(off_t, 0)
|
1999-11-10 01:47:11 -05:00
|
|
|
AC_CHECK_SIZEOF(void*, 4)
|
|
|
|
AC_CHECK_SIZEOF(float, 4)
|
|
|
|
AC_CHECK_SIZEOF(double, 8)
|
1999-01-19 23:59:39 -05:00
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(for prototypes, rb_cv_have_prototypes,
|
1999-01-19 23:59:39 -05:00
|
|
|
[AC_TRY_COMPILE([int foo(int x) { return 0; }], [return foo(10);],
|
|
|
|
rb_cv_have_prototypes=yes,
|
|
|
|
rb_cv_have_prototypes=no)])
|
|
|
|
if test "$rb_cv_have_prototypes" = yes; then
|
|
|
|
AC_DEFINE(HAVE_PROTOTYPES)
|
|
|
|
fi
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(token paste string, rb_cv_tokenpaste,
|
|
|
|
[AC_TRY_COMPILE([#define paste(a,b) a##b],
|
|
|
|
[int xy = 1; return paste(x,y);],
|
|
|
|
rb_cv_tokenpaste=ansi,
|
|
|
|
rb_cv_tokenpaste=knr)])
|
|
|
|
if test "$rb_cv_tokenpaste" = ansi; then
|
|
|
|
AC_DEFINE(TOKEN_PASTE(x,y),[x##y])
|
|
|
|
else
|
|
|
|
AC_DEFINE(TOKEN_PASTE(x,y),[x/**/y])
|
|
|
|
fi
|
|
|
|
|
|
|
|
AC_CACHE_CHECK(for variable length prototypes and stdarg.h, rb_cv_stdarg,
|
1999-01-19 23:59:39 -05:00
|
|
|
[AC_TRY_COMPILE([
|
|
|
|
#include <stdarg.h>
|
|
|
|
int foo(int x, ...) {
|
|
|
|
va_list va;
|
|
|
|
va_start(va, x);
|
|
|
|
va_arg(va, int);
|
|
|
|
va_arg(va, char *);
|
|
|
|
va_arg(va, double);
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
], [return foo(10, "", 3.14);],
|
|
|
|
rb_cv_stdarg=yes,
|
|
|
|
rb_cv_stdarg=no)])
|
|
|
|
if test "$rb_cv_stdarg" = yes; then
|
|
|
|
AC_DEFINE(HAVE_STDARG_PROTOTYPES)
|
|
|
|
fi
|
|
|
|
|
2001-01-10 03:09:01 -05:00
|
|
|
AC_CACHE_CHECK([for noreturn], rb_cv_noreturn,
|
|
|
|
[rb_cv_noreturn=no
|
|
|
|
for mac in "x __attribute__ ((noreturn))" "__declspec(noreturn) x" x; do
|
|
|
|
AC_TRY_COMPILE(
|
|
|
|
[#define NORETURN(x) $mac
|
|
|
|
NORETURN(void exit(int x));],
|
|
|
|
[],
|
|
|
|
[rb_cv_noreturn="$mac"; break])
|
|
|
|
done])
|
|
|
|
AC_DEFINE_UNQUOTED([NORETURN(x)], $rb_cv_noreturn)
|
|
|
|
|
2002-05-02 03:50:36 -04:00
|
|
|
dnl Check whether we need to define sys_nerr locally
|
2002-05-03 07:24:30 -04:00
|
|
|
AC_CHECK_DECLS([sys_nerr], [], [], [$ac_includes_default
|
|
|
|
#include <errno.h>])
|
1999-01-19 23:59:39 -05:00
|
|
|
|
2002-05-02 03:50:36 -04:00
|
|
|
dnl whether link libc_r or not
|
2001-04-01 12:53:41 -04:00
|
|
|
AC_ARG_WITH(libc_r,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --with-libc_r link libc_r if possible (FreeBSD only)], [
|
2001-04-01 12:53:41 -04:00
|
|
|
case $withval in
|
|
|
|
yes) with_libc_r=yes;;
|
|
|
|
*) with_libc_r=no;;
|
2001-05-30 12:29:32 -04:00
|
|
|
esac], [with_libc_r=no])
|
2001-04-01 12:53:41 -04:00
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
dnl Checks for libraries.
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
nextstep*) ;;
|
1999-01-19 23:59:39 -05:00
|
|
|
openstep*) ;;
|
|
|
|
rhapsody*) ;;
|
2000-10-02 03:48:42 -04:00
|
|
|
darwin*) LIBS="-lobjc $LIBS";;
|
2000-01-04 23:41:21 -05:00
|
|
|
human*) ac_cv_func_getpgrp_void=yes;;
|
1999-01-19 23:59:39 -05:00
|
|
|
beos*) ;;
|
2001-04-26 09:58:10 -04:00
|
|
|
cygwin*) rb_cv_have_daylight=no
|
2002-10-02 10:59:25 -04:00
|
|
|
rb_cv_need_io_flush_between_rw=no
|
|
|
|
rb_cv_need_io_flush_before_seek=no
|
2002-08-21 03:17:55 -04:00
|
|
|
ac_cv_var_tzname=no
|
2002-10-02 00:28:01 -04:00
|
|
|
ac_cv_func__setjmp=no
|
|
|
|
ac_cv_func_setitimer=no
|
|
|
|
;;
|
2000-05-13 12:13:31 -04:00
|
|
|
mingw*) LIBS="-lwsock32 -lmsvcrt $LIBS"
|
2002-10-02 10:59:25 -04:00
|
|
|
rb_cv_need_io_flush_between_rw=no
|
|
|
|
rb_cv_need_io_flush_before_seek=no
|
2000-05-13 12:13:31 -04:00
|
|
|
ac_cv_header_a_out_h=no
|
|
|
|
ac_cv_header_pwd_h=no
|
|
|
|
ac_cv_header_utime_h=no
|
|
|
|
ac_cv_header_sys_ioctl_h=no
|
|
|
|
ac_cv_header_sys_param_h=no
|
|
|
|
ac_cv_header_sys_resource_h=no
|
|
|
|
ac_cv_header_sys_select_h=no
|
2000-08-15 03:11:13 -04:00
|
|
|
ac_cv_header_sys_times_h=no
|
2001-05-31 22:25:28 -04:00
|
|
|
ac_cv_func_times=yes
|
2002-05-22 07:23:11 -04:00
|
|
|
ac_cv_func_waitpid=yes
|
|
|
|
ac_cv_func_vsnprintf=yes
|
2002-06-30 05:07:54 -04:00
|
|
|
ac_cv_func_seekdir=yes
|
|
|
|
ac_cv_func_telldir=yes
|
2002-08-21 03:17:55 -04:00
|
|
|
ac_cv_func_crypt=no
|
2002-05-22 07:23:11 -04:00
|
|
|
;;
|
2000-02-08 03:54:01 -05:00
|
|
|
os2_emx*) LIBS="-lm $LIBS"
|
|
|
|
ac_cv_lib_dir_opendir=no;;
|
2001-02-11 09:59:04 -05:00
|
|
|
msdosdjgpp*) LIBS="-lm $LIBS"
|
|
|
|
ac_cv_func_getpgrp_void=yes;;
|
2000-06-16 03:44:16 -04:00
|
|
|
freebsd*) LIBS="-lm $LIBS"
|
|
|
|
AC_CACHE_CHECK([whether -lxpg4 has to be linked],
|
|
|
|
rb_cv_lib_xpg4_needed,
|
|
|
|
[AC_TRY_CPP([
|
|
|
|
#include <osreldate.h>
|
|
|
|
#if __FreeBSD_version < 400020 || \
|
|
|
|
(__FreeBSD_version >= 500000 && __FreeBSD_version < 500005)
|
|
|
|
#error needs libxpg4
|
|
|
|
#endif
|
|
|
|
],
|
|
|
|
rb_cv_lib_xpg4_needed=no,
|
|
|
|
rb_cv_lib_xpg4_needed=yes,
|
|
|
|
rb_cv_lib_xpg4_needed=yes)])
|
|
|
|
if test "$rb_cv_lib_xpg4_needed" = yes; then
|
|
|
|
AC_CHECK_LIB(xpg4, setlocale)
|
|
|
|
fi
|
2001-04-01 12:53:41 -04:00
|
|
|
if test "$with_libc_r" = yes; then
|
|
|
|
AC_CACHE_CHECK([whether libc_r is supplementary to libc],
|
|
|
|
rb_cv_supplementary_lib_c_r,
|
|
|
|
[AC_TRY_CPP([
|
|
|
|
#include <osreldate.h>
|
|
|
|
#if 500016 <= __FreeBSD_version
|
|
|
|
#error libc_r is supplementary to libc
|
|
|
|
#endif
|
|
|
|
],
|
|
|
|
rb_cv_supplementary_lib_c_r=no,
|
|
|
|
rb_cv_supplementary_lib_c_r=yes,
|
|
|
|
rb_cv_supplementary_lib_c_r=yes)])
|
|
|
|
if test "$rb_cv_supplementary_lib_c_r" = yes; then
|
|
|
|
MAINLIBS="-lc_r $MAINLIBS"
|
|
|
|
else
|
|
|
|
MAINLIBS="-pthread $MAINLIBS"
|
|
|
|
CFLAGS="-D_THREAD_SAFE $CFLAGS"
|
|
|
|
fi
|
|
|
|
fi
|
2000-06-16 03:44:16 -04:00
|
|
|
;;
|
2001-04-22 05:49:15 -04:00
|
|
|
linux*) LIBS="-lm $LIBS"
|
|
|
|
case "$target_cpu" in
|
|
|
|
alpha*)
|
|
|
|
CFLAGS="-mieee $CFLAGS" ;;
|
|
|
|
esac ;;
|
2001-04-26 09:58:10 -04:00
|
|
|
osf*) LIBS="-lm $LIBS"
|
2001-12-02 09:10:27 -05:00
|
|
|
case "$target_cpu"::"$GCC" in
|
2001-04-26 09:58:10 -04:00
|
|
|
alpha*::yes)
|
2001-12-02 09:10:27 -05:00
|
|
|
CFLAGS="-mieee $CFLAGS" ;;
|
|
|
|
alpha*::no|alpha*::)
|
2001-04-26 09:58:10 -04:00
|
|
|
CFLAGS="-ieee $CFLAGS" ;;
|
|
|
|
esac ;;
|
1998-01-16 07:13:05 -05:00
|
|
|
*) LIBS="-lm $LIBS";;
|
|
|
|
esac
|
|
|
|
AC_CHECK_LIB(crypt, crypt)
|
|
|
|
AC_CHECK_LIB(dl, dlopen) # Dynamic linking for SunOS/Solaris and SYSV
|
|
|
|
AC_CHECK_LIB(dld, shl_load) # Dynamic linking for HP-UX
|
|
|
|
|
|
|
|
dnl Checks for header files.
|
|
|
|
AC_HEADER_DIRENT
|
|
|
|
AC_HEADER_STDC
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_HEADER_SYS_WAIT
|
|
|
|
AC_CHECK_HEADERS(stdlib.h string.h unistd.h limits.h sys/file.h sys/ioctl.h\
|
|
|
|
fcntl.h sys/fcntl.h sys/select.h sys/time.h sys/times.h sys/param.h\
|
2002-01-29 04:15:59 -05:00
|
|
|
syscall.h pwd.h a.out.h utime.h memory.h direct.h sys/resource.h \
|
|
|
|
sys/mkdev.h)
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
dnl Checks for typedefs, structures, and compiler characteristics.
|
|
|
|
AC_TYPE_UID_T
|
|
|
|
AC_TYPE_SIZE_T
|
|
|
|
AC_STRUCT_ST_BLKSIZE
|
|
|
|
AC_STRUCT_ST_BLOCKS
|
|
|
|
AC_STRUCT_ST_RDEV
|
|
|
|
|
|
|
|
dnl Checks for library functions.
|
|
|
|
AC_TYPE_GETGROUPS
|
|
|
|
AC_TYPE_SIGNAL
|
|
|
|
AC_FUNC_ALLOCA
|
1999-01-19 23:59:39 -05:00
|
|
|
AC_FUNC_MEMCMP
|
2002-03-14 01:23:46 -05:00
|
|
|
AC_FUNC_FSEEKO
|
|
|
|
AC_CHECK_FUNCS(ftello)
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_REPLACE_FUNCS(dup2 memmove mkdir strcasecmp strncasecmp strerror strftime\
|
2000-07-27 05:49:34 -04:00
|
|
|
strchr strstr strtoul crypt flock vsnprintf\
|
2002-04-11 23:24:52 -04:00
|
|
|
isinf isnan finite hypot acosh)
|
2002-08-01 05:42:38 -04:00
|
|
|
AC_CHECK_FUNCS(fmod killpg wait4 waitpid syscall chroot fsync\
|
2000-09-21 05:31:00 -04:00
|
|
|
truncate chsize times utimes fcntl lockf lstat symlink readlink\
|
2001-09-03 01:37:42 -04:00
|
|
|
setitimer setruid seteuid setreuid setresuid setproctitle\
|
2001-02-16 02:53:21 -05:00
|
|
|
setrgid setegid setregid setresgid pause lchown lchmod\
|
2000-09-21 05:31:00 -04:00
|
|
|
getpgrp setpgrp getpgid setpgid getgroups getpriority getrlimit\
|
2001-12-17 01:45:37 -05:00
|
|
|
dlopen sigprocmask sigaction _setjmp setsid telldir seekdir fchmod\
|
2002-08-02 11:14:02 -04:00
|
|
|
mktime timegm cosh sinh tanh)
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_STRUCT_TIMEZONE
|
2001-12-17 01:45:37 -05:00
|
|
|
AC_CACHE_CHECK(for struct tm.tm_gmtoff, rb_cv_member_struct_tm_tm_gmtoff,
|
|
|
|
[AC_TRY_COMPILE([#include <time.h>],
|
|
|
|
[struct tm t; t.tm_gmtoff = 3600;],
|
|
|
|
[rb_cv_member_struct_tm_tm_gmtoff=yes],
|
|
|
|
[rb_cv_member_struct_tm_tm_gmtoff=no])])
|
|
|
|
if test "$rb_cv_member_struct_tm_tm_gmtoff" = yes; then
|
|
|
|
AC_DEFINE(HAVE_STRUCT_TM_TM_GMTOFF)
|
|
|
|
fi
|
2000-06-12 03:48:31 -04:00
|
|
|
AC_CACHE_CHECK(for external int daylight, rb_cv_have_daylight,
|
2000-06-14 01:15:08 -04:00
|
|
|
[AC_TRY_LINK([#include <time.h>
|
|
|
|
int i;],
|
|
|
|
[i = daylight;],
|
2000-06-12 03:48:31 -04:00
|
|
|
rb_cv_have_daylight=yes,
|
|
|
|
rb_cv_have_daylight=no)])
|
|
|
|
if test "$rb_cv_have_daylight" = yes; then
|
|
|
|
AC_DEFINE(HAVE_DAYLIGHT)
|
1998-01-16 07:13:05 -05:00
|
|
|
fi
|
2001-02-20 02:42:03 -05:00
|
|
|
AC_CACHE_CHECK(for negative time_t for gmtime(3), rb_cv_negative_time_t,
|
|
|
|
[AC_TRY_RUN([
|
|
|
|
#include <time.h>
|
|
|
|
|
|
|
|
void
|
|
|
|
check(tm, y, m, d, h, s)
|
|
|
|
struct tm *tm;
|
|
|
|
int y, m, d, h, s;
|
|
|
|
{
|
2001-02-26 00:29:06 -05:00
|
|
|
if (!tm ||
|
|
|
|
tm->tm_year != y ||
|
2001-02-20 02:42:03 -05:00
|
|
|
tm->tm_mon != m-1 ||
|
|
|
|
tm->tm_mday != d ||
|
|
|
|
tm->tm_hour != h ||
|
|
|
|
tm->tm_sec != s) {
|
|
|
|
exit(1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
int
|
|
|
|
main()
|
|
|
|
{
|
|
|
|
time_t t = -1;
|
|
|
|
struct tm *tm;
|
|
|
|
|
|
|
|
check(gmtime(&t), 69, 12, 31, 23, 59);
|
2001-12-17 01:45:37 -05:00
|
|
|
t = ~(time_t)0 << 31;
|
2001-02-20 02:42:03 -05:00
|
|
|
check(gmtime(&t), 1, 12, 13, 20, 52);
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
],
|
|
|
|
rb_cv_negative_time_t=yes,
|
|
|
|
rb_cv_negative_time_t=no,
|
|
|
|
rb_cv_negative_time_t=yes)])
|
|
|
|
if test "$rb_cv_negative_time_t" = yes; then
|
|
|
|
AC_DEFINE(NEGATIVE_TIME_T)
|
|
|
|
fi
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
if test "$ac_cv_func_sigprocmask" = yes && test "$ac_cv_func_sigaction" = yes; then
|
|
|
|
AC_DEFINE(POSIX_SIGNAL)
|
|
|
|
else
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(for BSD signal semantics, rb_cv_bsd_signal,
|
1998-01-16 07:13:05 -05:00
|
|
|
[AC_TRY_RUN([
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <signal.h>
|
|
|
|
|
|
|
|
void
|
|
|
|
sig_handler(dummy)
|
|
|
|
int dummy;
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
int
|
|
|
|
main()
|
|
|
|
{
|
|
|
|
signal(SIGINT, sig_handler);
|
|
|
|
kill(getpid(), SIGINT);
|
|
|
|
kill(getpid(), SIGINT);
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
],
|
|
|
|
rb_cv_bsd_signal=yes,
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_cv_bsd_signal=no,
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_bsd_signal=no)])
|
|
|
|
if test "$rb_cv_bsd_signal" = yes; then
|
|
|
|
AC_DEFINE(BSD_SIGNAL)
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_FUNC_GETPGRP
|
|
|
|
AC_FUNC_SETPGRP
|
1998-01-16 07:13:05 -05:00
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(for working strtod, rb_cv_func_strtod,
|
|
|
|
[AC_TRY_RUN([
|
|
|
|
double strtod ();
|
|
|
|
int
|
|
|
|
main()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
/* Some versions of Linux strtod mis-parse strings with leading '+'. */
|
|
|
|
char *string = " +69";
|
|
|
|
char *term;
|
|
|
|
double value;
|
|
|
|
value = strtod(string, &term);
|
|
|
|
if (value != 69 || term != (string + 4))
|
|
|
|
exit(1);
|
|
|
|
}
|
|
|
|
|
|
|
|
{
|
|
|
|
/* Under Solaris 2.4, strtod returns the wrong value for the
|
|
|
|
terminating character under some conditions. */
|
|
|
|
char *string = "NaN";
|
|
|
|
char *term;
|
|
|
|
strtod(string, &term);
|
|
|
|
if (term != string && *(term - 1) == 0)
|
|
|
|
exit(1);
|
|
|
|
}
|
|
|
|
exit(0);
|
|
|
|
}
|
|
|
|
], rb_cv_func_strtod=yes, rb_cv_func_strtod=no, rb_cv_func_strtod=no)])
|
2002-03-14 02:20:34 -05:00
|
|
|
test $rb_cv_func_strtod = no && AC_LIBOBJ([strtod])
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
AC_C_BIGENDIAN
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_C_CONST
|
1999-11-10 01:47:11 -05:00
|
|
|
AC_C_CHAR_UNSIGNED
|
2001-03-22 03:59:26 -05:00
|
|
|
AC_C_INLINE
|
1998-01-16 07:13:05 -05:00
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(whether right shift preserve sign bit, rb_cv_rshift_sign,
|
1999-01-19 23:59:39 -05:00
|
|
|
[AC_TRY_RUN([
|
|
|
|
int
|
|
|
|
main()
|
|
|
|
{
|
1999-12-14 01:50:43 -05:00
|
|
|
if (-1==(-1>>1))
|
1999-01-19 23:59:39 -05:00
|
|
|
return 0;
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
],
|
|
|
|
rb_cv_rshift_sign=yes,
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_cv_rshift_sign=no,
|
|
|
|
rb_cv_rshift_sign=yes)])
|
1999-01-19 23:59:39 -05:00
|
|
|
if test "$rb_cv_rshift_sign" = yes; then
|
1999-12-14 01:50:43 -05:00
|
|
|
AC_DEFINE(RSHIFT(x,y), ((x)>>(int)y))
|
1999-01-19 23:59:39 -05:00
|
|
|
else
|
|
|
|
AC_DEFINE(RSHIFT(x,y), (((x)<0) ? ~((~(x))>>y) : (x)>>y))
|
|
|
|
fi
|
|
|
|
|
2002-03-25 09:50:40 -05:00
|
|
|
AC_MSG_CHECKING(read count field in FILE structures)
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_CACHE_VAL(rb_cv_fcnt,
|
2002-03-25 09:50:40 -05:00
|
|
|
[for fcnt in dnl
|
|
|
|
_cnt dnl
|
|
|
|
__cnt dnl
|
|
|
|
_r dnl
|
|
|
|
readCount dnl
|
|
|
|
_rcount dnl for emx0.9c
|
|
|
|
; do
|
|
|
|
AC_TRY_COMPILE([#include <stdio.h>
|
|
|
|
],
|
|
|
|
[FILE *f = stdin; f->$fcnt = 0;],
|
|
|
|
rb_cv_fcnt="$fcnt"; break,
|
|
|
|
rb_cv_fcnt="not found")
|
|
|
|
done])
|
1998-01-16 07:13:05 -05:00
|
|
|
if test "$rb_cv_fcnt" = "not found"; then
|
|
|
|
AC_MSG_RESULT([not found(OK if using GNU libc)])
|
|
|
|
else
|
|
|
|
AC_MSG_RESULT($rb_cv_fcnt)
|
|
|
|
AC_DEFINE_UNQUOTED(FILE_COUNT, $rb_cv_fcnt)
|
|
|
|
fi
|
|
|
|
|
2002-03-25 09:50:40 -05:00
|
|
|
AC_MSG_CHECKING(read buffer ptr field in FILE structures)
|
|
|
|
AC_CACHE_VAL(rb_cv_frptr,
|
|
|
|
[for frptr in dnl
|
|
|
|
_IO_read_ptr dnl
|
|
|
|
_ptr dnl
|
|
|
|
__ptr dnl
|
|
|
|
bufpos dnl
|
2002-03-25 10:37:44 -05:00
|
|
|
_p dnl
|
2002-03-25 09:50:40 -05:00
|
|
|
; do
|
|
|
|
AC_TRY_COMPILE([#include <stdio.h>
|
|
|
|
],
|
|
|
|
[FILE *f = stdin; char buf[256]; f->$frptr = buf;],
|
|
|
|
rb_cv_frptr="$frptr"; break,
|
|
|
|
rb_cv_frptr="not found")
|
|
|
|
done])
|
|
|
|
if test "$rb_cv_frptr" = "not found"; then
|
|
|
|
AC_MSG_RESULT([not found])
|
|
|
|
else
|
|
|
|
AC_MSG_RESULT($rb_cv_frptr)
|
|
|
|
AC_DEFINE_UNQUOTED(FILE_READPTR, $rb_cv_frptr)
|
|
|
|
|
|
|
|
if test "$rb_cv_fcnt" = "not found"; then
|
|
|
|
AC_MSG_CHECKING(read buffer end field in FILE structures)
|
|
|
|
AC_CACHE_VAL(rb_cv_frend,
|
|
|
|
[for frend in dnl
|
|
|
|
_IO_read_end dnl
|
2002-03-26 05:14:44 -05:00
|
|
|
bufread dnl
|
2002-03-25 09:50:40 -05:00
|
|
|
; do
|
|
|
|
AC_TRY_COMPILE([#include <stdio.h>
|
|
|
|
],
|
|
|
|
[FILE *f = stdin; char buf[256]; f->$frend = buf;],
|
|
|
|
rb_cv_frend="$frend"; break,
|
|
|
|
rb_cv_frend="not found")
|
|
|
|
done])
|
|
|
|
if test "$rb_cv_frend" = "not found"; then
|
|
|
|
AC_MSG_RESULT([not found])
|
|
|
|
else
|
|
|
|
AC_MSG_RESULT($rb_cv_frend)
|
|
|
|
AC_DEFINE_UNQUOTED(FILE_READEND, $rb_cv_frend)
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2002-10-02 10:59:25 -04:00
|
|
|
AC_DEFUN(RUBY_CHECK_IO_NEED_FLUSH,
|
|
|
|
[AC_CACHE_CHECK(whether need to flush [$1], [$2],
|
|
|
|
[AC_TRY_RUN([
|
|
|
|
#include <stdio.h>
|
|
|
|
|
|
|
|
char *fn = "conftest.dat";
|
|
|
|
char *wombat = "wombat\n";
|
|
|
|
char *koara = "koara\n";
|
|
|
|
|
|
|
|
int main()
|
|
|
|
{
|
|
|
|
char buf[BUFSIZ];
|
|
|
|
FILE *f;
|
|
|
|
int r = 1;
|
|
|
|
|
|
|
|
if (!(f = fopen(fn, "w+"))) return 1;
|
|
|
|
fputs(wombat, f);
|
|
|
|
fflush(f);
|
|
|
|
fseek(f, 0, 0);
|
|
|
|
if (!fgets(buf, BUFSIZ, f) || strcmp(buf, wombat)) goto fail;
|
|
|
|
]ifelse(index($2,between_rw),-1,fflush(f);)[
|
|
|
|
fputs(koara, f);
|
|
|
|
]ifelse(index($2,before_seek),-1,fflush(f);)[
|
|
|
|
fseek(f, 0, 0);
|
|
|
|
]ifelse(index($2,between_rw),-1,fflush(f);)[
|
|
|
|
if (!fgets(buf, BUFSIZ, f) || strcmp(buf, wombat)) goto fail;
|
|
|
|
if (!fgets(buf, BUFSIZ, f) || strcmp(buf, koara)) goto fail;
|
|
|
|
r = 0;
|
|
|
|
fail:
|
|
|
|
fclose(f);
|
|
|
|
unlink(fn);
|
|
|
|
return r;
|
|
|
|
}
|
|
|
|
], [$2]=no, [$2]=yes, [$2]=yes)])])
|
|
|
|
|
|
|
|
RUBY_CHECK_IO_NEED_FLUSH(between R/W, rb_cv_need_io_flush_between_rw)
|
|
|
|
RUBY_CHECK_IO_NEED_FLUSH(before seek, rb_cv_need_io_flush_before_seek)
|
|
|
|
if test "$rb_cv_need_io_flush_between_rw" = yes; then
|
|
|
|
AC_DEFINE(NEED_IO_FLUSH_BETWEEN_RW, 1)
|
|
|
|
fi
|
|
|
|
if test "$rb_cv_need_io_flush_before_seek" = yes; then
|
|
|
|
AC_DEFINE(NEED_IO_FLUSH_BEFORE_SEEK, 1)
|
|
|
|
fi
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
dnl default value for $KANJI
|
2000-03-07 03:37:59 -05:00
|
|
|
DEFAULT_KCODE="KCODE_NONE"
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_ARG_WITH(default-kcode,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --with-default-kcode=CODE specify default value for \$KCODE (utf8|euc|sjis|none)],
|
1999-08-13 01:45:20 -04:00
|
|
|
[case $withval in
|
2000-03-07 03:37:59 -05:00
|
|
|
utf8) DEFAULT_KCODE="KCODE_UTF8";;
|
|
|
|
euc) DEFAULT_KCODE="KCODE_EUC";;
|
|
|
|
sjis) DEFAULT_KCODE="KCODE_SJIS";;
|
|
|
|
none) DEFAULT_KCODE="KCODE_NONE";;
|
1999-08-13 01:45:20 -04:00
|
|
|
*) AC_MSG_WARN($withval is not valid kcode; ignored);;
|
|
|
|
esac])
|
2000-03-07 03:37:59 -05:00
|
|
|
AC_DEFINE_UNQUOTED(DEFAULT_KCODE, $DEFAULT_KCODE)
|
1999-08-13 01:45:20 -04:00
|
|
|
|
2001-04-01 12:53:41 -04:00
|
|
|
dnl wheather use dln_a_out or not
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_ARG_WITH(dln-a-out,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --with-dln-a-out use dln_a_out if possible], [
|
1998-01-16 07:13:05 -05:00
|
|
|
case $withval in
|
|
|
|
yes) with_dln_a_out=yes;;
|
|
|
|
*) with_dln_a_out=no;;
|
|
|
|
esac], [with_dln_a_out=no])
|
|
|
|
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
AC_SUBST(XCFLAGS)dnl
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_SUBST(XLDFLAGS)dnl
|
|
|
|
|
2000-01-31 22:12:21 -05:00
|
|
|
AC_CACHE_CHECK(whether ELF binaries are produced, rb_cv_binary_elf,
|
|
|
|
[AC_TRY_RUN([
|
1998-01-16 07:13:05 -05:00
|
|
|
/* Test for whether ELF binaries are produced */
|
|
|
|
#include <fcntl.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
main() {
|
|
|
|
char buffer[4];
|
|
|
|
int i=open("conftest",O_RDONLY);
|
|
|
|
if(i==-1)
|
|
|
|
exit(1); /* fail */
|
|
|
|
if(read(i,&buffer[0],4)<4)
|
|
|
|
exit(1); /* fail */
|
|
|
|
if(buffer[0] != 127 || buffer[1] != 'E' ||
|
|
|
|
buffer[2] != 'L' || buffer[3] != 'F')
|
|
|
|
exit(1); /* fail */
|
|
|
|
exit(0); /* succeed (yes, it's ELF) */
|
|
|
|
}
|
|
|
|
],
|
2000-01-31 22:12:21 -05:00
|
|
|
rb_cv_binary_elf=yes,
|
|
|
|
rb_cv_binary_elf=no,
|
|
|
|
rb_cv_binary_elf=yes)])
|
|
|
|
|
|
|
|
if test "$rb_cv_binary_elf" = yes; then
|
|
|
|
AC_DEFINE(USE_ELF)
|
|
|
|
fi
|
|
|
|
|
|
|
|
case "$target_os" in
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
linux*)
|
|
|
|
if test "$rb_cv_binary_elf" = no; then
|
|
|
|
with_dln_a_out=yes
|
|
|
|
target_os=${target_os}-a_out
|
|
|
|
else
|
|
|
|
LDFLAGS="-rdynamic"
|
|
|
|
fi;;
|
2000-01-31 22:12:21 -05:00
|
|
|
netbsd*)
|
|
|
|
if [[ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]]
|
|
|
|
then
|
|
|
|
netbsd_elf=yes
|
|
|
|
else
|
|
|
|
netbsd_elf=no
|
|
|
|
fi
|
|
|
|
;;
|
1998-01-16 07:13:05 -05:00
|
|
|
esac
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBEXT=a
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
AC_SUBST(DLDFLAGS)dnl
|
|
|
|
|
|
|
|
AC_SUBST(STATIC)dnl
|
|
|
|
AC_SUBST(CCDLFLAGS)dnl
|
|
|
|
AC_SUBST(LDSHARED)dnl
|
|
|
|
AC_SUBST(DLEXT)dnl
|
2000-05-09 00:53:16 -04:00
|
|
|
AC_SUBST(DLEXT2)dnl
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
AC_SUBST(LIBEXT)dnl
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
STATIC=
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBPATHFLAG=' -L%s'
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
if test "$with_dln_a_out" != yes; then
|
|
|
|
rb_cv_dlopen=unknown
|
|
|
|
AC_MSG_CHECKING(whether OS depend dynamic link works)
|
|
|
|
if test "$GCC" = yes; then
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
nextstep*) ;;
|
1999-01-19 23:59:39 -05:00
|
|
|
openstep*) ;;
|
|
|
|
rhapsody*) ;;
|
2001-05-02 14:35:50 -04:00
|
|
|
darwin*) CCDLFLAGS=-fno-common;;
|
1998-01-16 07:13:05 -05:00
|
|
|
human*) ;;
|
1999-09-01 05:48:03 -04:00
|
|
|
bsdi*) ;;
|
2000-05-24 00:34:26 -04:00
|
|
|
beos*) ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
cygwin*) ;;
|
2000-05-13 12:13:31 -04:00
|
|
|
mingw*) ;;
|
2001-12-02 13:33:10 -05:00
|
|
|
netbsd*) CCDLFLAGS=-fPIC;;
|
1999-08-13 01:45:20 -04:00
|
|
|
*) CCDLFLAGS=-fPIC;;
|
1998-01-16 07:13:05 -05:00
|
|
|
esac
|
|
|
|
else
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
hpux*) CCDLFLAGS='+z';;
|
2000-06-05 04:46:59 -04:00
|
|
|
solaris*|irix*) CCDLFLAGS='-KPIC' ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
sunos*) CCDLFLAGS='-PIC' ;;
|
|
|
|
esix*|uxpds*) CCDLFLAGS='-KPIC' ;;
|
1998-01-16 07:13:05 -05:00
|
|
|
*) CCDLFLAGS='' ;;
|
|
|
|
esac
|
|
|
|
fi
|
|
|
|
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
hpux*) DLDFLAGS="-E"
|
|
|
|
LDSHARED='ld -b'
|
|
|
|
LDFLAGS="-Wl,-E"
|
|
|
|
rb_cv_dlopen=yes;;
|
1999-08-13 01:45:20 -04:00
|
|
|
solaris*) if test "$GCC" = yes; then
|
2002-01-25 04:00:50 -05:00
|
|
|
LDSHARED='$(CC) -Wl,-G'
|
2002-10-04 01:46:45 -04:00
|
|
|
if test "$rb_cv_prog_gnu_ld" = yes; then
|
2002-01-25 04:00:50 -05:00
|
|
|
LDFLAGS="-Wl,-E"
|
|
|
|
LDSHARED="$LDSHARED -shared"
|
|
|
|
fi
|
1999-08-13 01:45:20 -04:00
|
|
|
else
|
|
|
|
LDSHARED='ld -G'
|
|
|
|
fi
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes;;
|
|
|
|
sunos*) LDSHARED='ld -assert nodefinitions'
|
|
|
|
rb_cv_dlopen=yes;;
|
2000-06-05 04:46:59 -04:00
|
|
|
irix*) LDSHARED='ld -shared'
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes;;
|
|
|
|
sysv4*) LDSHARED='ld -G'
|
|
|
|
rb_cv_dlopen=yes;;
|
2001-05-11 01:24:59 -04:00
|
|
|
nto-qnx*) LDSHARED="qcc -shared"
|
|
|
|
rb_cv_dlopen=yes ;;
|
1998-01-16 07:13:05 -05:00
|
|
|
esix*|uxpds*) LDSHARED="ld -G"
|
|
|
|
rb_cv_dlopen=yes ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
osf*) LDSHARED="$CC -shared"
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
linux*) LDSHARED="$CC -shared"
|
1999-01-19 23:59:39 -05:00
|
|
|
rb_cv_dlopen=yes ;;
|
2002-02-18 04:52:48 -05:00
|
|
|
gnu*) LDSHARED="$CC -shared"
|
|
|
|
rb_cv_dlopen=yes
|
|
|
|
LDFLAGS="-rdynamic" ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
freebsd*) LDSHARED="$CC -shared"
|
2000-01-31 22:12:21 -05:00
|
|
|
if test "$rb_cv_binary_elf" = yes; then
|
1999-08-13 01:45:20 -04:00
|
|
|
LDFLAGS="-rdynamic"
|
|
|
|
DLDFLAGS='-Wl,-soname,$(.TARGET)'
|
|
|
|
else
|
2002-10-04 01:46:45 -04:00
|
|
|
test "$GCC" = yes && test "$rb_cv_prog_gnu_ld" = yes || LDSHARED="ld -Bshareable"
|
1999-08-13 01:45:20 -04:00
|
|
|
fi
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes ;;
|
2001-12-02 13:33:10 -05:00
|
|
|
netbsd*) LDSHARED='${CC} -shared'
|
2001-12-03 04:38:35 -05:00
|
|
|
if test "$rb_cv_binary_elf" = yes; then
|
|
|
|
LDFLAGS="-Wl,-export-dynamic"
|
2002-10-24 08:58:42 -04:00
|
|
|
LIBPATHFLAG=' -L%1$-s -Wl,-R%1$-s'
|
2001-12-03 04:38:35 -05:00
|
|
|
fi
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes ;;
|
1999-01-19 23:59:39 -05:00
|
|
|
openbsd*) LDSHARED="ld -Bforcearchive -Bshareable"
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
bsdi3*) case "$CC" in
|
|
|
|
*shlicc*) LDSHARED="$CC -r"
|
|
|
|
rb_cv_dlopen=yes ;;
|
|
|
|
esac ;;
|
1999-09-01 05:48:03 -04:00
|
|
|
bsdi*) LDSHARED="ld -shared"
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LDFLAGS='-rdynamic -Wl,-rpath,$(libdir)/ruby/$(MAJOR).$(MINOR)/i386-bsdi4.0'
|
1999-09-01 05:48:03 -04:00
|
|
|
rb_cv_dlopen=yes ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
nextstep*) LDSHARED='cc -r -nostdlib'
|
1998-01-16 07:13:05 -05:00
|
|
|
LDFLAGS="-u libsys_s"
|
|
|
|
DLDFLAGS="$ARCH_FLAG"
|
|
|
|
rb_cv_dlopen=yes ;;
|
1999-01-19 23:59:39 -05:00
|
|
|
openstep*) LDSHARED='cc -dynamic -bundle -undefined suppress'
|
|
|
|
LDFLAGS=""
|
|
|
|
DLDFLAGS="$ARCH_FLAG"
|
|
|
|
rb_cv_dlopen=yes ;;
|
|
|
|
rhapsody*) LDSHARED='cc -dynamic -bundle -undefined suppress'
|
|
|
|
LDFLAGS=""
|
|
|
|
DLDFLAGS="$ARCH_FLAG"
|
|
|
|
rb_cv_dlopen=yes ;;
|
2001-10-02 00:31:23 -04:00
|
|
|
darwin*) LDSHARED='cc -dynamic -bundle -undefined suppress -flat_namespace'
|
2000-08-28 05:53:42 -04:00
|
|
|
LDFLAGS=""
|
|
|
|
DLDFLAGS="$ARCH_FLAG"
|
|
|
|
rb_cv_dlopen=yes ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
aix*) LDSHARED='/usr/ccs/bin/ld'
|
|
|
|
XLDFLAGS='-Wl,-bE:ruby.imp'
|
2000-06-28 04:31:35 -04:00
|
|
|
DLDFLAGS='-brtl -eInit_$(TARGET) -bI:$(topdir)/ruby.imp -bM:SRE -T512 -H512 -lc'
|
2000-02-08 03:54:01 -05:00
|
|
|
LDFLAGS="-brtl"
|
1998-01-16 07:13:05 -05:00
|
|
|
rb_cv_dlopen=yes ;;
|
1999-08-13 01:45:20 -04:00
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
human*) DLDFLAGS=''
|
|
|
|
LDSHARED=''
|
1999-08-13 01:45:20 -04:00
|
|
|
LDFLAGS=''
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LINK_SO='ar cru $@ $(OBJS)'
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_cv_dlopen=yes ;;
|
2000-01-04 23:41:21 -05:00
|
|
|
beos*) case "$target_cpu" in
|
1999-01-19 23:59:39 -05:00
|
|
|
powerpc*)
|
1999-08-13 01:45:20 -04:00
|
|
|
LDSHARED="ld -xms"
|
2000-05-24 00:34:26 -04:00
|
|
|
DLDFLAGS='-export Init_$(TARGET) -lbe -lroot glue-noinit.a init_term_dyn.o start_dyn.o'
|
1999-01-19 23:59:39 -05:00
|
|
|
;;
|
1999-08-13 01:45:20 -04:00
|
|
|
i586*)
|
|
|
|
LDSHARED="ld -shared"
|
|
|
|
DLDFLAGS="-L/boot/develop/lib/x86 -lbe -lroot"
|
|
|
|
;;
|
1999-01-19 23:59:39 -05:00
|
|
|
esac
|
|
|
|
rb_cv_dlopen=yes ;;
|
2001-08-05 23:05:23 -04:00
|
|
|
nto-qnx*) DLDFLAGS="-L/lib -L/usr/lib -L/usr/local/lib"
|
|
|
|
LDSHARED='ld -Bshareable -x'
|
|
|
|
LDFLAGS="-L/lib -L/usr/lib -L/usr/local/lib"
|
|
|
|
rb_cv_dlopen=yes;;
|
2002-04-19 03:39:40 -04:00
|
|
|
cygwin*|mingw*) : ${LDSHARED="${CC} -shared -s"}
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
XLDFLAGS='-Wl,--stack,0x02000000'
|
|
|
|
DLDFLAGS="${DLDFLAGS} "'$(DEFFILE)'
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_cv_dlopen=yes ;;
|
2002-05-02 03:50:36 -04:00
|
|
|
hiuxmpp) LDSHARED='ld -r' ;;
|
1998-01-16 07:13:05 -05:00
|
|
|
*) LDSHARED='ld' ;;
|
|
|
|
esac
|
|
|
|
AC_MSG_RESULT($rb_cv_dlopen)
|
|
|
|
fi
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
AC_SUBST(LINK_SO)
|
|
|
|
AC_SUBST(LIBPATHFLAG)
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
dln_a_out_works=no
|
|
|
|
if test "$ac_cv_header_a_out_h" = yes; then
|
|
|
|
if test "$with_dln_a_out" = yes || test "$rb_cv_dlopen" = unknown; then
|
|
|
|
cat confdefs.h > config.h
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(whether matz's dln works, rb_cv_dln_a_out,
|
1998-01-16 07:13:05 -05:00
|
|
|
[AC_TRY_COMPILE([
|
|
|
|
#define USE_DLN_A_OUT
|
|
|
|
#include "dln.c"
|
|
|
|
],
|
|
|
|
[],
|
|
|
|
rb_cv_dln_a_out=yes,
|
|
|
|
rb_cv_dln_a_out=no)])
|
|
|
|
if test "$rb_cv_dln_a_out" = yes; then
|
|
|
|
dln_a_out_works=yes
|
|
|
|
AC_DEFINE(USE_DLN_A_OUT)
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
if test "$dln_a_out_works" = yes; then
|
|
|
|
if test "$GCC" = yes; then
|
|
|
|
STATIC=-static
|
|
|
|
else
|
|
|
|
STATIC=-Bstatic
|
|
|
|
fi
|
1999-08-13 01:45:20 -04:00
|
|
|
DLEXT=so
|
|
|
|
AC_DEFINE(DLEXT, ".so")
|
1998-01-16 07:13:05 -05:00
|
|
|
CCDLFLAGS=
|
|
|
|
else
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
hpux*) DLEXT=sl
|
|
|
|
AC_DEFINE(DLEXT, ".sl");;
|
1999-08-13 01:45:20 -04:00
|
|
|
nextstep*) DLEXT=bundle
|
|
|
|
AC_DEFINE(DLEXT, ".bundle");;
|
1999-01-19 23:59:39 -05:00
|
|
|
openstep*) DLEXT=bundle
|
|
|
|
AC_DEFINE(DLEXT, ".bundle");;
|
|
|
|
rhapsody*) DLEXT=bundle
|
|
|
|
AC_DEFINE(DLEXT, ".bundle");;
|
2000-08-28 05:53:42 -04:00
|
|
|
darwin*) DLEXT=bundle
|
|
|
|
AC_DEFINE(DLEXT, ".bundle");;
|
2000-02-08 03:54:01 -05:00
|
|
|
os2_emx*) DLEXT=dll
|
|
|
|
AC_DEFINE(DLEXT, ".dll");;
|
2000-05-13 12:13:31 -04:00
|
|
|
cygwin*|mingw*) DLEXT=so
|
2000-05-09 00:53:16 -04:00
|
|
|
AC_DEFINE(DLEXT, ".so")
|
|
|
|
DLEXT2=dll
|
|
|
|
AC_DEFINE(DLEXT2, ".dll");;
|
1998-01-16 07:13:05 -05:00
|
|
|
*) DLEXT=so
|
|
|
|
AC_DEFINE(DLEXT, ".so");;
|
|
|
|
esac
|
|
|
|
fi
|
|
|
|
|
|
|
|
AC_SUBST(STRIP)dnl
|
|
|
|
if test "$with_dln_a_out" = yes; then
|
|
|
|
STRIP=true
|
|
|
|
else
|
|
|
|
STRIP=strip
|
|
|
|
fi
|
|
|
|
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
linux*)
|
|
|
|
STRIP='strip -S -x';;
|
2002-02-18 04:52:48 -05:00
|
|
|
gnu*)
|
|
|
|
STRIP='strip -S -x';;
|
1998-01-16 07:13:05 -05:00
|
|
|
nextstep*)
|
|
|
|
STRIP='strip -A -n';;
|
1999-01-19 23:59:39 -05:00
|
|
|
openstep*)
|
|
|
|
STRIP='strip -A -n';;
|
|
|
|
rhapsody*)
|
|
|
|
STRIP='strip -A -n';;
|
2000-08-28 05:53:42 -04:00
|
|
|
darwin*)
|
|
|
|
STRIP='strip -A -n';;
|
1998-01-16 07:13:05 -05:00
|
|
|
esac
|
|
|
|
|
|
|
|
EXTSTATIC=
|
|
|
|
AC_SUBST(EXTSTATIC)dnl
|
|
|
|
AC_ARG_WITH(static-linked-ext,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --with-static-linked-ext link external modules statically],
|
1998-01-16 07:13:05 -05:00
|
|
|
[case $withval in
|
|
|
|
yes) STATIC=
|
|
|
|
EXTSTATIC=static;;
|
|
|
|
*) ;;
|
|
|
|
esac])
|
|
|
|
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1998-01-16 07:13:05 -05:00
|
|
|
human*)
|
|
|
|
AC_CHECK_LIB(signal, _harderr)
|
|
|
|
AC_CHECK_LIB(hmem, hmemset)
|
2000-01-04 23:41:21 -05:00
|
|
|
AC_CHECK_FUNCS(select gettimeofday)
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(whether PD libc _dtos18 fail to convert big number,
|
|
|
|
rb_cv_missing__dtos18,
|
1998-01-16 07:13:05 -05:00
|
|
|
[AC_TRY_RUN(
|
|
|
|
changequote(<<, >>)dnl
|
|
|
|
<<
|
|
|
|
#include <stdio.h>
|
|
|
|
main ()
|
|
|
|
{
|
|
|
|
char buf[256];
|
|
|
|
sprintf (buf, "%g", 1e+300);
|
|
|
|
exit (strcmp (buf, "1e+300") ? 0 : 1);
|
|
|
|
}
|
|
|
|
>>,
|
|
|
|
changequote([, ])dnl
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_cv_missing__dtos18=yes, rb_cv_missing__dtos18=no, rb_cv_missing__dtos18=no)])
|
1998-01-16 07:13:05 -05:00
|
|
|
if test "$rb_cv_missing__dtos18" = yes; then
|
|
|
|
AC_DEFINE(MISSING__DTOS18)
|
|
|
|
fi
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_CACHE_CHECK(whether PD libc fconvert fail to round,
|
|
|
|
rb_cv_missing_fconvert,
|
1998-01-16 07:13:05 -05:00
|
|
|
[AC_TRY_RUN(
|
|
|
|
changequote(<<, >>)dnl
|
|
|
|
<<
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <math.h>
|
|
|
|
main ()
|
|
|
|
{
|
|
|
|
char buf[256];
|
|
|
|
sprintf (buf, "%f", log(exp(1.0)));
|
|
|
|
exit (strcmp (buf, "1.000000") ? 0 : 1);
|
|
|
|
}
|
|
|
|
>>,
|
|
|
|
changequote([, ])dnl
|
1999-08-13 01:45:20 -04:00
|
|
|
rb_cv_missing_fconvert=yes, rb_cv_missing_fconvert=no, rb_cv_missing_fconvert=no)])
|
1998-01-16 07:13:05 -05:00
|
|
|
if test "$rb_cv_missing_fconvert" = yes; then
|
|
|
|
AC_DEFINE(MISSING_FCONVERT)
|
|
|
|
fi
|
2002-03-14 02:20:34 -05:00
|
|
|
AC_LIBOBJ([x68.o])
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
CFLAGS="$CFLAGS -fansi-only"
|
|
|
|
XCFLAGS="-cc1-stack=262144 -cpp-stack=2694144"
|
1999-08-13 01:45:20 -04:00
|
|
|
EXEEXT=.x
|
|
|
|
OBJEXT=o
|
1998-01-16 07:13:05 -05:00
|
|
|
setup=Setup.x68
|
|
|
|
;;
|
1999-08-13 01:45:20 -04:00
|
|
|
dnl OS/2 environment w/ Autoconf 2.1x for EMX
|
|
|
|
os2_emx)
|
2002-03-14 02:20:34 -05:00
|
|
|
AC_LIBOBJ([os2])
|
1999-08-13 01:45:20 -04:00
|
|
|
setup=Setup.emx
|
|
|
|
;;
|
2000-05-21 08:23:51 -04:00
|
|
|
*djgpp*)
|
|
|
|
setup=Setup.dj
|
|
|
|
;;
|
2002-09-25 03:03:05 -04:00
|
|
|
atheos*)
|
|
|
|
setup=Setup.atheos
|
|
|
|
;;
|
1998-01-16 07:13:05 -05:00
|
|
|
*)
|
|
|
|
setup=Setup
|
|
|
|
;;
|
|
|
|
esac
|
1999-01-19 23:59:39 -05:00
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_SUBST(setup)
|
|
|
|
|
|
|
|
if test "$prefix" = NONE; then
|
|
|
|
prefix=$ac_default_prefix
|
|
|
|
fi
|
|
|
|
|
|
|
|
if test "$fat_binary" = yes ; then
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
XCFLAGS="$ARCH_FLAG"
|
1999-01-19 23:59:39 -05:00
|
|
|
fi
|
|
|
|
|
2000-01-04 23:41:21 -05:00
|
|
|
if test x"$cross_compiling" = xyes; then
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
MINIRUBY="${RUBY-ruby} -I`pwd` -rfake"
|
2000-05-21 05:25:58 -04:00
|
|
|
PREP=fake.rb
|
2000-01-04 23:41:21 -05:00
|
|
|
else
|
|
|
|
MINIRUBY='./miniruby$(EXEEXT)'
|
|
|
|
PREP=''
|
|
|
|
fi
|
|
|
|
AC_SUBST(MINIRUBY)
|
|
|
|
AC_SUBST(PREP)
|
|
|
|
|
2000-03-13 02:18:45 -05:00
|
|
|
FIRSTMAKEFILE=""
|
1999-08-13 01:45:20 -04:00
|
|
|
LIBRUBY_A='lib$(RUBY_INSTALL_NAME).a'
|
|
|
|
LIBRUBY='$(LIBRUBY_A)'
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBYARG='-l$(RUBY_INSTALL_NAME)'
|
1999-01-19 23:59:39 -05:00
|
|
|
SOLIBS=
|
1998-01-16 07:13:05 -05:00
|
|
|
|
2000-05-09 00:53:16 -04:00
|
|
|
case "$target_os" in
|
2000-10-02 03:48:42 -04:00
|
|
|
cygwin*|mingw*|beos*|openstep*|nextstep*|rhapsody*|darwin*|os2_emx*)
|
2000-05-09 00:53:16 -04:00
|
|
|
DLDLIBS=""
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
DLDLIBS="-lc"
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
RUBY_SO_NAME='$(RUBY_INSTALL_NAME)'
|
1999-08-13 01:45:20 -04:00
|
|
|
LIBRUBY_LDSHARED=$LDSHARED
|
|
|
|
LIBRUBY_DLDFLAGS=$DLDFLAGS
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR).$(TEENY)'
|
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so'
|
2000-07-02 11:57:18 -04:00
|
|
|
ENABLE_SHARED=no
|
|
|
|
|
2001-11-30 04:17:30 -05:00
|
|
|
AC_ARG_ENABLE(shared,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --enable-shared build a shared library for Ruby. ],
|
1999-08-13 01:45:20 -04:00
|
|
|
[enable_shared=$enableval])
|
1999-01-19 23:59:39 -05:00
|
|
|
if test "$enable_shared" = 'yes'; then
|
1999-08-13 01:45:20 -04:00
|
|
|
LIBRUBY='$(LIBRUBY_SO)'
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBYARG='-l$(RUBY_SO_NAME)'
|
1999-08-13 01:45:20 -04:00
|
|
|
CFLAGS="$CFLAGS $CCDLFLAGS"
|
2000-07-02 11:57:18 -04:00
|
|
|
ENABLE_SHARED=yes
|
2001-03-16 03:17:44 -05:00
|
|
|
if test "$rb_cv_binary_elf" = yes; then
|
|
|
|
SOLIBS='$(LIBS)'
|
|
|
|
fi
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
1999-08-13 01:45:20 -04:00
|
|
|
sunos4*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).so'
|
1999-08-13 01:45:20 -04:00
|
|
|
;;
|
|
|
|
linux*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_DLDFLAGS='-Wl,-soname,lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR)'
|
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).so'
|
|
|
|
test "$rb_cv_prog_gnu_ld" = yes && DLDFLAGS="$DLDFLAGS -Wl,-no-undefined"
|
1999-08-13 01:45:20 -04:00
|
|
|
;;
|
2002-02-18 04:52:48 -05:00
|
|
|
gnu*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_DLDFLAGS='-Wl,-soname,lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR)'
|
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).so'
|
2002-02-18 04:52:48 -05:00
|
|
|
;;
|
1999-08-13 01:45:20 -04:00
|
|
|
freebsd*)
|
2001-03-16 03:17:44 -05:00
|
|
|
SOLIBS='$(LIBS)'
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)'
|
2000-01-31 22:12:21 -05:00
|
|
|
if test "$rb_cv_binary_elf" != "yes" ; then
|
1999-08-13 01:45:20 -04:00
|
|
|
LIBRUBY_SO="$LIBRUBY_SO.\$(TEENY)"
|
|
|
|
LIBRUBY_ALIASES=''
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
netbsd*)
|
2001-03-16 03:17:44 -05:00
|
|
|
SOLIBS='$(LIBS)'
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_SO='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR).$(TEENY)'
|
|
|
|
LIBRUBY_DLDFLAGS='-Wl,-soname,lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR)'
|
|
|
|
LIBRUBYARG='-Wl,-R -Wl,${libdir} -L${libdir} -L. -l$(RUBY_SO_NAME)'
|
2000-01-31 22:12:21 -05:00
|
|
|
if test "$rb_cv_binary_elf" = yes; then # ELF platforms
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR)$(MINOR) lib$(RUBY_SO_NAME).so'
|
2001-12-02 13:33:10 -05:00
|
|
|
else # a.out platforms
|
|
|
|
LIBRUBY_ALIASES=""
|
2000-01-31 22:12:21 -05:00
|
|
|
fi
|
1999-08-13 01:45:20 -04:00
|
|
|
;;
|
2001-03-16 03:17:44 -05:00
|
|
|
openbsd*)
|
|
|
|
SOLIBS='$(LIBS)'
|
|
|
|
;;
|
1999-08-13 01:45:20 -04:00
|
|
|
solaris*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
XLDFLAGS='-R${libdir}'
|
1999-08-13 01:45:20 -04:00
|
|
|
;;
|
|
|
|
hpux*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
XLDFLAGS='-Wl,+s,+b,$(libdir)'
|
|
|
|
LIBRUBY_SO='lib$(RUBY_SO_NAME).sl.$(MAJOR).$(MINOR).$(TEENY)'
|
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).sl.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).sl'
|
1999-08-13 01:45:20 -04:00
|
|
|
;;
|
|
|
|
aix*)
|
|
|
|
if test "$GCC" = yes; then
|
|
|
|
LIBRUBY_LDSHARED='$(CC) -shared'
|
|
|
|
LIBRUBY_DLDFLAGS='-Wl,-bE:ruby.imp'
|
|
|
|
else
|
|
|
|
LIBRUBY_LDSHARED='/usr/ccs/bin/ld'
|
|
|
|
LIBRUBY_DLDFLAGS='-bE:ruby.imp -bM:SRE -bnoentry'
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
ARCHFILE="ruby.imp"
|
1999-08-13 01:45:20 -04:00
|
|
|
fi
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBYARG='-L${libdir} -Wl,lib$(RUBY_SO_NAME).so'
|
1999-08-13 01:45:20 -04:00
|
|
|
SOLIBS='-lm -lc'
|
|
|
|
;;
|
2000-05-24 00:34:26 -04:00
|
|
|
beos*)
|
|
|
|
case "$target_cpu" in
|
|
|
|
powerpc*)
|
|
|
|
LIBRUBY_DLDFLAGS='-f ruby.exp -lnet -lbe -lroot glue-noinit.a init_term_dyn.o start_dyn.o'
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
2001-05-02 14:35:50 -04:00
|
|
|
darwin*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_SO='lib$(RUBY_SO_NAME).$(MAJOR).$(MINOR).$(TEENY).dylib'
|
2001-10-02 00:31:23 -04:00
|
|
|
LIBRUBY_LDSHARED='cc -dynamiclib -undefined suppress -flat_namespace'
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
LIBRUBY_DLDFLAGS='-install_name $(libdir)/lib$(RUBY_SO_NAME).dylib -current_version $(MAJOR).$(MINOR).$(TEENY) -compatibility_version $(MAJOR).$(MINOR)'
|
|
|
|
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).$(MAJOR).$(MINOR).dylib lib$(RUBY_SO_NAME).dylib'
|
2001-05-02 14:35:50 -04:00
|
|
|
;;
|
1999-08-13 01:45:20 -04:00
|
|
|
*)
|
|
|
|
;;
|
|
|
|
esac
|
1999-01-19 23:59:39 -05:00
|
|
|
fi
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
XLDFLAGS="$XLDFLAGS -L."
|
|
|
|
AC_SUBST(ARCHFILE)
|
1999-01-19 23:59:39 -05:00
|
|
|
|
2000-01-04 23:41:21 -05:00
|
|
|
case "$target_os" in
|
2001-12-02 13:33:10 -05:00
|
|
|
netbsd*)
|
|
|
|
CFLAGS="$CFLAGS -pipe"
|
|
|
|
;;
|
2000-05-14 05:36:29 -04:00
|
|
|
nextstep*)
|
1999-01-19 23:59:39 -05:00
|
|
|
CFLAGS="$CFLAGS -pipe"
|
2000-05-14 05:36:29 -04:00
|
|
|
;;
|
|
|
|
openstep*)
|
1999-01-19 23:59:39 -05:00
|
|
|
CFLAGS="$CFLAGS -pipe"
|
2000-05-14 05:36:29 -04:00
|
|
|
;;
|
2000-07-31 00:36:38 -04:00
|
|
|
rhapsody*)
|
1999-01-19 23:59:39 -05:00
|
|
|
CFLAGS="$CFLAGS -pipe -no-precomp"
|
2000-05-14 05:36:29 -04:00
|
|
|
;;
|
2000-08-28 05:53:42 -04:00
|
|
|
darwin*)
|
2002-08-29 05:08:18 -04:00
|
|
|
CFLAGS="$CFLAGS -pipe"
|
2000-08-28 05:53:42 -04:00
|
|
|
;;
|
2000-07-31 00:36:38 -04:00
|
|
|
os2_emx)
|
|
|
|
CFLAGS="$CFLAGS -DOS2"
|
|
|
|
;;
|
2000-05-14 05:36:29 -04:00
|
|
|
osf*)
|
2001-12-02 09:10:27 -05:00
|
|
|
if test "$GCC" != "yes" ; then
|
2000-03-15 00:01:17 -05:00
|
|
|
# compile something small: taint.c is fine for this.
|
|
|
|
# the main point is the '-v' flag of 'cc'.
|
|
|
|
case "`cc -v -I. -c main.c -o /tmp/main.o 2>&1`" in
|
|
|
|
*/gemc_cc*) # we have the new DEC GEM CC
|
2000-03-15 04:09:28 -05:00
|
|
|
CFLAGS="$CFLAGS -oldc"
|
2000-03-15 00:01:17 -05:00
|
|
|
;;
|
|
|
|
*) # we have the old MIPS CC
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
# cleanup
|
|
|
|
rm -f /tmp/main.o
|
|
|
|
CFLAGS="$CFLAGS -std"
|
|
|
|
fi
|
|
|
|
;;
|
2000-05-24 00:34:26 -04:00
|
|
|
beos*)
|
|
|
|
case "$target_cpu" in
|
|
|
|
powerpc*)
|
|
|
|
CFLAGS="$CFLAGS -relax_pointers"
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
2000-07-02 11:57:18 -04:00
|
|
|
cygwin*|mingw*)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
EXPORT_PREFIX=' '
|
2002-08-23 04:18:19 -04:00
|
|
|
case "$target_os" in
|
|
|
|
cygwin*)
|
|
|
|
RUBY_SO_NAME=$target_os-'$(RUBY_INSTALL_NAME)'${MAJOR}${MINOR}
|
|
|
|
AC_LIBOBJ([strftime])
|
|
|
|
CCDLFLAGS=-DUSEIMPORTLIB ;;
|
|
|
|
mingw*)
|
|
|
|
RUBY_SO_NAME=msvcrt-'$(RUBY_INSTALL_NAME)'${MAJOR}${MINOR}
|
|
|
|
AC_LIBOBJ([win32])
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
COMMON_LIBS=m
|
|
|
|
COMMON_MACROS="WIN32_LEAN_AND_MEAN="
|
|
|
|
COMMON_HEADERS="windows.h winsock.h"
|
2002-08-23 04:18:19 -04:00
|
|
|
CFLAGS="-DNT -D__NO_ISOCEXT $CFLAGS"
|
|
|
|
CCDLFLAGS=-DIMPORT ;;
|
|
|
|
esac
|
2000-07-25 10:46:46 -04:00
|
|
|
if test x"$enable_shared" = xyes; then
|
2000-09-04 00:43:26 -04:00
|
|
|
LIBRUBY_SO='$(RUBY_SO_NAME)'.dll
|
2002-05-07 04:15:25 -04:00
|
|
|
LIBRUBY_DLDFLAGS='-Wl,--out-implib=$(LIBRUBY) $(RUBYDEF)'
|
2002-06-11 06:26:13 -04:00
|
|
|
LIBRUBY='lib$(LIBRUBY_SO).a'
|
2000-07-25 10:46:46 -04:00
|
|
|
else
|
2000-07-25 21:12:31 -04:00
|
|
|
LIBRUBY_SO=dummy
|
2002-06-11 06:26:13 -04:00
|
|
|
LIBRUBY_DLDFLAGS=''
|
|
|
|
LIBRUBY='lib$(RUBY_SO_NAME).a'
|
2000-07-25 10:46:46 -04:00
|
|
|
fi
|
2000-07-02 11:57:18 -04:00
|
|
|
LIBRUBY_ALIASES=''
|
|
|
|
LIBRUBY_A='lib$(RUBY_INSTALL_NAME)s.a'
|
|
|
|
FIRSTMAKEFILE=GNUmakefile:cygwin/GNUmakefile.in
|
2000-07-25 21:12:31 -04:00
|
|
|
SOLIBS='$(LIBS)'
|
2000-05-14 05:36:29 -04:00
|
|
|
;;
|
|
|
|
*)
|
2002-08-23 04:18:19 -04:00
|
|
|
;;
|
1999-01-19 23:59:39 -05:00
|
|
|
esac
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_SUBST(LIBRUBY_LDSHARED)
|
|
|
|
AC_SUBST(LIBRUBY_DLDFLAGS)
|
|
|
|
AC_SUBST(RUBY_INSTALL_NAME)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
AC_SUBST(rubyw_install_name)
|
|
|
|
AC_SUBST(RUBYW_INSTALL_NAME)
|
2000-08-07 01:05:04 -04:00
|
|
|
AC_SUBST(RUBY_SO_NAME)
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_SUBST(LIBRUBY_A)
|
|
|
|
AC_SUBST(LIBRUBY_SO)
|
|
|
|
AC_SUBST(LIBRUBY_ALIASES)
|
1999-01-19 23:59:39 -05:00
|
|
|
AC_SUBST(LIBRUBY)
|
|
|
|
AC_SUBST(LIBRUBYARG)
|
|
|
|
AC_SUBST(SOLIBS)
|
2000-05-09 00:53:16 -04:00
|
|
|
AC_SUBST(DLDLIBS)
|
2000-07-02 11:57:18 -04:00
|
|
|
AC_SUBST(ENABLE_SHARED)
|
2001-04-01 12:53:41 -04:00
|
|
|
AC_SUBST(MAINLIBS)
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
AC_SUBST(COMMON_LIBS)
|
|
|
|
AC_SUBST(COMMON_MACROS)
|
|
|
|
AC_SUBST(COMMON_HEADERS)
|
|
|
|
AC_SUBST(EXPORT_PREFIX)
|
|
|
|
|
|
|
|
MAKEFILES="Makefile `echo $FIRSTMAKEFILE | sed 's/:.*//'`"
|
|
|
|
MAKEFILES="`echo $MAKEFILES`"
|
|
|
|
AC_SUBST(MAKEFILES)
|
1999-01-19 23:59:39 -05:00
|
|
|
|
|
|
|
ri_prefix=
|
|
|
|
test "$program_prefix" != NONE &&
|
|
|
|
ri_prefix=$program_prefix
|
|
|
|
|
|
|
|
ri_suffix=
|
|
|
|
test "$program_suffix" != NONE &&
|
|
|
|
ri_suffix=$program_suffix
|
|
|
|
|
|
|
|
RUBY_INSTALL_NAME="${ri_prefix}ruby${ri_suffix}"
|
* configure.in (XCFLAGS): CFLAGS to comile ruby itself.
* configure.in (LIBEXT): suffix for static libraries.
* configure.in (LIBPATHFLAG): switch template to specify library
path.
* configure.in (LINK_SO): command to link shared objects.
* configure.in (DEFFILE, ARCHFILE): miscellaneous system dependent
files.
* configure.in (EXPORT_PREFIX): prefix to exported symbols on
Windows.
* configure.in (COMMON_LIBS, COMMON_MACROS, COMMON_HEADERS):
libraries, macros and headers used in common.
* configure.in (RUBYW_INSTALL_NAME, rubyw_install_name): GUI mode
excutable name.
* Makefile.in (CFLAGS): append XCFLAGS.
* Makefile.in (PREP): miscellaneous system dependent files.
* Makefile.in (ruby.imp, ext/extinit.o): moved from ext/extmk.rb.
* Makefile.in (fake.rb): CROSS_COMPILING keeps building platform.
* Makefile.in (MAKEFILES): depend on *.in and config.status.
* Makefile.in (parse.c): replace "y.tab.c" with actual name for
byacc.
* ext/extmk.rb, lib/mkmf.rb: integrated.
* ext/extmk.rb: propagate MFLAGS.
* ext/extmk.rb (extmake): make dummy Makefile to clean even if no
Makefile is made.
* lib/mkmf.rb (older): accept multiple file names and Time
objects.
* lib/mkmf.rb (xsystem): split and qoute.
* lib/mkmf.rb (cpp_include): make include directives.
* lib/mkmf.rb (try_func): try wheather specified function is
available.
* lib/mkmf.rb (install_files): default to site-install.
* lib/mkmf.rb (checking_for): added.
* lib/mkmf.rb (find_executable0): just find executable file with
no message.
* lib/mkmf.rb (create_header): output header file is variable.
* lib/mkmf.rb (create_makefile): separate sections.
* lib/mkmf.rb (init_mkmf): initialize global variables.
* win32/Makefile.sub, bcc32/Makefile.sub (CPP, AR): added.
* bcc32/Makefile.sub (ARCH): fixed to i386.
* win32/Makefile.sub, bcc32/Makefile.sub (miniruby): should not
link EXTOBJS.
* ext/dl/extconf.rb: use try_cpp to cross compile.
* ext/dl/extconf.rb: not modify files in source directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-10-21 10:17:44 -04:00
|
|
|
case "$target_os" in
|
|
|
|
cygwin*|mingw*)
|
|
|
|
RUBYW_INSTALL_NAME="${ri_prefix}rubyw${ri_suffix}"
|
|
|
|
rubyw_install_name="$RUBYW_INSTALL_NAME"
|
|
|
|
;;
|
|
|
|
esac
|
2000-08-03 05:50:41 -04:00
|
|
|
case "$target_os" in
|
2000-10-02 03:48:42 -04:00
|
|
|
cygwin*|mingw*|*djgpp*|os2_emx*)
|
2000-08-03 05:50:41 -04:00
|
|
|
RUBY_LIB_PREFIX="/lib/ruby"
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
RUBY_LIB_PREFIX="${prefix}/lib/ruby"
|
|
|
|
;;
|
|
|
|
esac
|
2000-02-17 02:11:22 -05:00
|
|
|
RUBY_LIB_PATH="${RUBY_LIB_PREFIX}/${MAJOR}.${MINOR}"
|
2000-09-27 02:48:23 -04:00
|
|
|
|
2000-04-12 01:06:23 -04:00
|
|
|
AC_ARG_WITH(sitedir,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --with-sitedir=DIR site libraries in DIR [PREFIX/lib/ruby/site_ruby]],
|
2000-09-22 14:15:52 -04:00
|
|
|
[sitedir=$withval],
|
2000-09-27 02:48:23 -04:00
|
|
|
[sitedir='${prefix}/lib/ruby/site_ruby'])
|
2000-10-02 03:48:42 -04:00
|
|
|
SITE_DIR="`eval \"echo ${sitedir}\"`"
|
2000-09-27 02:48:23 -04:00
|
|
|
case "$target_os" in
|
2000-10-02 03:48:42 -04:00
|
|
|
cygwin*|mingw*|*djgpp*|os2_emx*)
|
2000-09-27 02:48:23 -04:00
|
|
|
RUBY_SITE_LIB_PATH="`expr "$SITE_DIR" : "$prefix\(/.*\)"`" ||
|
|
|
|
RUBY_SITE_LIB_PATH="$SITE_DIR";;
|
|
|
|
*)
|
|
|
|
RUBY_SITE_LIB_PATH="$SITE_DIR";;
|
|
|
|
esac
|
2000-06-28 08:27:54 -04:00
|
|
|
RUBY_SITE_LIB_PATH2="${RUBY_SITE_LIB_PATH}/${MAJOR}.${MINOR}"
|
2000-02-17 02:11:22 -05:00
|
|
|
|
2000-06-28 08:27:54 -04:00
|
|
|
AC_DEFINE_UNQUOTED(RUBY_LIB, "${RUBY_LIB_PATH}")
|
|
|
|
AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, "${RUBY_SITE_LIB_PATH}")
|
|
|
|
AC_DEFINE_UNQUOTED(RUBY_SITE_LIB2, "${RUBY_SITE_LIB_PATH2}")
|
2000-02-17 02:11:22 -05:00
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_SUBST(arch)dnl
|
2002-08-23 04:18:19 -04:00
|
|
|
AC_SUBST(sitearch)dnl
|
2000-04-12 01:06:23 -04:00
|
|
|
AC_SUBST(sitedir)dnl
|
1998-01-16 07:13:05 -05:00
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
configure_args=$ac_configure_args
|
|
|
|
AC_SUBST(configure_args)dnl
|
|
|
|
|
1998-01-16 07:13:05 -05:00
|
|
|
if test "$fat_binary" = yes ; then
|
2000-01-04 23:41:21 -05:00
|
|
|
arch="fat-${target_os}"
|
1998-01-16 07:13:05 -05:00
|
|
|
|
|
|
|
AC_DEFINE_UNQUOTED(RUBY_THIN_ARCHLIB,
|
2000-01-04 23:41:21 -05:00
|
|
|
"${RUBY_LIB_PATH}/" __ARCHITECTURE__ "-${target_os}")
|
1999-01-19 23:59:39 -05:00
|
|
|
|
|
|
|
AC_DEFINE_UNQUOTED(RUBY_SITE_THIN_ARCHLIB,
|
2000-01-04 23:41:21 -05:00
|
|
|
"${RUBY_SITE_LIB_PATH}/" __ARCHITECTURE__ "-${target_os}")
|
|
|
|
AC_DEFINE_UNQUOTED(RUBY_PLATFORM, __ARCHITECTURE__ "-${target_os}")
|
1998-01-16 07:13:05 -05:00
|
|
|
else
|
2000-01-04 23:41:21 -05:00
|
|
|
arch="${target_cpu}-${target_os}"
|
1998-01-16 07:13:05 -05:00
|
|
|
AC_DEFINE_UNQUOTED(RUBY_PLATFORM, "${arch}")
|
|
|
|
fi
|
2000-02-17 02:11:22 -05:00
|
|
|
|
2002-08-23 04:18:19 -04:00
|
|
|
case "$target_os" in
|
|
|
|
mingw*) sitearch="i386-msvcrt" ;;
|
|
|
|
*) sitearch="${arch}" ;;
|
|
|
|
esac
|
|
|
|
|
1999-08-13 01:45:20 -04:00
|
|
|
AC_DEFINE_UNQUOTED(RUBY_ARCHLIB, "${RUBY_LIB_PATH}/${arch}")
|
2002-08-23 04:18:19 -04:00
|
|
|
AC_DEFINE_UNQUOTED(RUBY_SITE_ARCHLIB, "${RUBY_SITE_LIB_PATH2}/${sitearch}")
|
1999-08-13 01:45:20 -04:00
|
|
|
|
|
|
|
AC_ARG_WITH(search-path,
|
2002-04-11 23:24:52 -04:00
|
|
|
[ --with-search-path=DIR specify the additional search path],
|
1999-08-13 01:45:20 -04:00
|
|
|
[search_path=$withval])
|
|
|
|
if test "$search_path" != ""; then
|
|
|
|
AC_DEFINE_UNQUOTED(RUBY_SEARCH_PATH,"$search_path")
|
|
|
|
fi
|
1998-01-16 07:13:05 -05:00
|
|
|
|
2002-02-06 03:25:00 -05:00
|
|
|
if test -f config.h && tr -d '\015' < confdefs.h | cmp -s config.h -; then
|
|
|
|
echo "config.h unchanged"
|
|
|
|
else
|
|
|
|
echo "creating config.h"
|
|
|
|
tr -d '\015' < confdefs.h > config.h
|
|
|
|
fi
|
2001-01-16 23:33:29 -05:00
|
|
|
: > confdefs.h
|
1998-01-16 07:13:05 -05:00
|
|
|
|
2002-09-08 05:08:15 -04:00
|
|
|
AC_CONFIG_FILES([$FIRSTMAKEFILE Makefile])
|
2002-04-19 03:39:40 -04:00
|
|
|
AC_OUTPUT
|