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

* dln.c: newer BeOS support. a patch from Pete Goodeve

<pete.goodeve at computer.org> in [ruby-core:18712].

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19426 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 2008-09-19 00:33:19 +00:00
parent a9cc553e61
commit d7de44a8fc
8 changed files with 19 additions and 7 deletions

View file

@ -1,3 +1,8 @@
Fri Sep 19 09:29:26 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
* dln.c: newer BeOS support. a patch from Pete Goodeve
<pete.goodeve at computer.org> in [ruby-core:18712].
Fri Sep 19 03:41:25 2008 NARUSE, Yui <naruse@ruby-lang.org>
* ext/nkf/nkf-utf8/nkf.c: fix memory violation. mentioned by mame [ruby-dev:36373]

View file

@ -1423,10 +1423,12 @@ if test "$with_dln_a_out" != yes; then
powerpc*)
: ${LDSHARED="ld -xms"}
DLDFLAGS="$DLDFLAGS "'-export Init_$(TARGET) -lbe -lroot glue-noinit.a init_term_dyn.o start_dyn.o'
;;
LDFLAGS="$LDFLAGS -L/boot/home/config/lib -lbe -lroot"
;;
i586*)
: ${LDSHARED="ld -shared"}
DLDFLAGS="$DLDFLAGS -L/boot/develop/lib/x86 -lbe -lroot"
DLDFLAGS="$DLDFLAGS -L/boot/develop/lib/x86 -L/boot/home/config/lib \$(topdir)/_APP_ -lbe -lroot"
LDFLAGS="$LDFLAGS -L/boot/develop/lib/x86 -L/boot/home/config/lib -lbe -lroot"
;;
esac
: ${LIBPATHENV=LIBRARY_PATH}
@ -1826,6 +1828,7 @@ case "$target_os" in
CFLAGS="$CFLAGS -relax_pointers"
;;
esac
CPPFLAGS="$CPPFLAGS -I/boot/home/config/include"
;;
cygwin*|mingw*)
LIBRUBY_DLDFLAGS="${DLDFLAGS}"' -Wl,--out-implib=$(LIBRUBY)'

3
dln.c
View file

@ -1442,7 +1442,8 @@ dln_load(const char *file)
/* load extention module */
img_id = load_add_on(file);
if (img_id <= 0) {
rb_loaderror("Failed to load %.200s", file);
rb_loaderror("Failed to load add_on %.200s error_code=%x",
file, img_id);
}
/* find symbol for module initialize function. */

View file

@ -42,7 +42,7 @@
#include <sys/types.h>
#ifndef _WIN32
#include <sys/param.h>
#if defined(__BEOS__) && !defined(__HAIKU__)
#if defined(__BEOS__) && !defined(__HAIKU__) && !defined(BONE)
# include <net/socket.h>
#else
# include <sys/socket.h>

View file

@ -38,7 +38,7 @@
#include <stdio.h>
#include <sys/types.h>
#ifndef _WIN32
#if defined(__BEOS__) && !defined(__HAIKU__)
#if defined(__BEOS__) && !defined(__HAIKU__) && !defined(BONE)
# include <net/socket.h>
#else
# include <sys/socket.h>

View file

@ -28,7 +28,7 @@
#endif
#ifndef _WIN32
#if defined(__BEOS__) && !defined(__HAIKU__)
#if defined(__BEOS__) && !defined(__HAIKU__) && !defined(BONE)
# include <net/socket.h>
#else
# include <sys/socket.h>

View file

@ -198,7 +198,7 @@ void xfree(void*);
#include "vms/vms.h"
#endif
#if defined(__BEOS__) && !defined(__HAIKU__)
#if defined(__BEOS__) && !defined(__HAIKU__) && !defined(BONE)
#include <net/socket.h> /* intern.h needs fd_set definition */
#endif

View file

@ -78,6 +78,9 @@ round(double x)
}
return x;
}
#elif defined(__BEOS__)
/* appears to be a bug in the BeOS headers */
double round(double x);
#endif
static ID id_coerce, id_to_i, id_eq;