Remove the ancient patches directory.
Nothing referenced it.
Diff
patches/automake/automake-1.10.1.diff | 17 -----------------
patches/bison/bison-2.3.diff | 20 --------------------
patches/libtool/libtool-1.5.26.diff | 123 --------------------------------------------------------------------------------
patches/openssh/.OptionalPackageDescription | 5 -----
patches/openssh/Notes | 31 -------------------------------
patches/openssh/openssh.diff | 20 --------------------
patches/openssh/ssh.sh | 17 -----------------
patches/openssl/Notes | 17 -----------------
patches/openssl/openssl-0.9.8g.diff | 54 ------------------------------------------------------
patches/perl/perl-5.10.0.diff | 617 --------------------------------------------------------------------------------
patches/texinfo/texinfo-4.11.diff | 12 ------------
11 files changed, 933 deletions(-)
@@ -1,17 +1,0 @@
diff -ur automake-1.10.1-orig/lib/config.guess automake-1.10.1/lib/config.guess
--- automake-1.10.1-orig/lib/config.guess 2008-01-19 09:54:57.000000000 +0000
+++ automake-1.10.1/lib/config.guess 2008-03-20 23:52:43.000000000 +0000
@@ -1216,6 +1216,12 @@
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
echo i586-pc-beos
exit ;;
+ BeMac:Haiku:*:*)
+ echo powerpc-apple-haiku
+ exit ;;
+ BePC:Haiku:*:*)
+ echo i586-pc-haiku
+ exit ;;
SX-4:SUPER-UX:*:*)
echo sx4-nec-superux${UNAME_RELEASE}
exit ;;
Only in automake-1.10.1/lib: config.guess~
@@ -1,20 +1,0 @@
--- bison-2.3-orig/lib/stdbool_.h 2006-01-26 13:31:49.000000000 +0000
+++ bison-2.3/lib/stdbool_.h 2008-03-28 05:24:05.000000000 +0000
@@ -55,7 +55,7 @@
/* BeOS <sys/socket.h> already #defines false 0, true 1. We use the same
definitions below, but temporarily we have to #undef them. */
-#ifdef __BEOS__
+#if defined(__BEOS__) && !defined(__HAIKU__)
# include <OS.h> /* defines bool but not _Bool */
# undef false
# undef true
@@ -70,7 +70,7 @@
(see ISO C 99 6.7.2.2.(4)); however, '_Bool' must promote to 'int'
(see ISO C 99 6.3.1.1.(2)). So we add a negative value to the
enum; this ensures that '_Bool' promotes to 'int'. */
-#if defined __cplusplus || defined __BEOS__
+#if defined __cplusplus || (defined __BEOS__ && !defined(__HAIKU__))
/* A compiler known to have 'bool'. */
/* If the compiler already has both 'bool' and '_Bool', we can assume they
are the same types. */
@@ -1,123 +1,0 @@
diff -ur libtool-1.5.26-orig/libltdl/ltdl.c libtool-1.5.26/libltdl/ltdl.c
--- libtool-1.5.26-orig/libltdl/ltdl.c 2007-11-15 19:36:41.000000000 +0000
+++ libtool-1.5.26/libltdl/ltdl.c 2008-03-20 16:21:34.000000000 +0000
@@ -1458,7 +1458,7 @@
/* --- LOAD_ADD_ON() INTERFACE LOADER --- */
-#ifdef __BEOS__
+#if defined(__BEOS__) && !defined(__HAIKU__)
/* dynamic linking for BeOS */
@@ -2241,7 +2241,7 @@
#ifdef __WINDOWS__
errors += lt_dlloader_add (lt_dlloader_next (0), &sys_wll, "dlopen");
#endif
-#ifdef __BEOS__
+#if defined(__BEOS__) && !defined(__HAIKU__)
errors += lt_dlloader_add (lt_dlloader_next (0), &sys_bedl, "dlopen");
#endif
#if HAVE_DLD
diff -ur libtool-1.5.26-orig/libtool.m4 libtool-1.5.26/libtool.m4
--- libtool-1.5.26-orig/libtool.m4 2008-02-01 16:26:47.000000000 +0000
+++ libtool-1.5.26/libtool.m4 2008-03-24 22:35:06.000000000 +0000
@@ -1579,6 +1579,18 @@
hardcode_into_libs=yes
;;
+haiku*)
+ version_type=linux
+ need_lib_prefix=no
+ need_version=no
+ dynamic_linker="$host_os runtime_loader"
+ library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+ soname_spec='${libname}${release}${shared_ext}$major'
+ shlibpath_var=LIBRARY_PATH
+ sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
+ hardcode_into_libs=yes
+ ;;
+
hpux9* | hpux10* | hpux11*)
# Give a soname corresponding to the major version so that dld.sl refuses to
# link against other versions.
@@ -2452,6 +2464,10 @@
lt_cv_deplibs_check_method=pass_all
;;
+haiku*)
+ lt_cv_deplibs_check_method=pass_all
+ ;;
+
hpux10.20* | hpux11*)
lt_cv_file_magic_cmd=/usr/bin/file
case $host_cpu in
@@ -2625,7 +2641,7 @@
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
LIBM=
case $host in
-*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
+*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin* | *-*-haiku*)
# These system don't have libm, or don't need it
;;
*-ncr-sysv4.3*)
@@ -3226,6 +3242,9 @@
;;
gnu*)
;;
+ haiku*)
+ _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+ ;;
hpux9*)
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
@@ -5021,7 +5040,7 @@
# like `-m68040'.
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | haiku* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
mingw* | cygwin* | os2* | pw32*)
@@ -5305,7 +5324,7 @@
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | haiku* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
@@ -5736,6 +5755,10 @@
fi
;;
+ haiku*)
+ _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+ ;;
+
interix[[3-9]]*)
_LT_AC_TAGVAR(hardcode_direct, $1)=no
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
diff -ur libtool-1.5.26-orig/ltmain.in libtool-1.5.26/ltmain.in
--- libtool-1.5.26-orig/ltmain.in 2008-02-01 16:12:00.000000000 +0000
+++ libtool-1.5.26/ltmain.in 2008-03-20 14:02:27.000000000 +0000
@@ -1599,7 +1599,7 @@
-l*)
if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*)
+ *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-*-haiku*)
# These systems don't actually have a C or math library (as such)
continue
;;
@@ -3526,7 +3526,7 @@
if test "$build_libtool_libs" = yes; then
if test -n "$rpath"; then
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*)
+ *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-*-haiku*)
# these systems don't actually have a c library (as such)!
;;
*-*-rhapsody* | *-*-darwin1.[012])
@@ -1,5 +1,0 @@
Package: OpenSSH
Version: 5.0p1
Copyright: 2005-2008 Tatu Ylonen et al.
License: OpenSSH
URL: http://www.openssh.org/
@@ -1,31 +1,0 @@
Notes for OpenSSH 5.0p1 (Haiku r25311)
======================================
configure
---------
rm config.sub config.guess
automake --add-missing
autoreconf --force
./configure --prefix=/boot/home/config --with-ssl-dir=/boot/home/config --sbindir=/boot/home/config/bin --libexecdir=/boot/home/config/bin --localstatedir=/var
* automake will fail, but it will replace config.{sub,guess} anyway, which is
all we want.
* Note, the /boot/home/config paths are temporary only. This has to be changed
to /boot/common.
make/install
------------
make
make install
packaging
---------
* Remove the generated host keys (in /boot/home/config/etc).
* Add the post install script (ssh.sh) that generates the host keys on the first
run.
@@ -1,20 +1,0 @@
Patch against OpenSSH 5.0p1 to add Haiku support.
Date: 2008-05-04
diff -urN openssh-5.0p1-orig/configure.ac openssh-5.0p1/configure.ac
--- openssh-5.0p1-orig/configure.ac 2008-03-27 01:33:07.000000000 +0000
+++ openssh-5.0p1/configure.ac 2008-05-04 00:29:35.000000000 +0000
@@ -468,6 +468,13 @@
*-*-dragonfly*)
SSHDLIBS="$SSHDLIBS -lcrypt"
;;
+*-*-haiku*)
+ CPPFLAGS="$CPPFLAGS -I/boot/develop/headers/bsd"
+ LIBS="$LIBS -lbsd -lnetwork"
+ dnl u_int64_t is defined, just not through <sys/types.h>
+ AC_DEFINE(HAVE_U_INT64_T)
+ MANTYPE=man
+ ;;
*-*-hpux*)
# first we define all of the options common to all HP-UX releases
CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1"
@@ -1,17 +1,0 @@
hostKeyDir=/boot/home/config/etc
if [ ! -f "$hostKeyDir/ssh_host_key" ] ; then
ssh-keygen -t rsa1 -f "$hostKeyDir/ssh_host_key" -N ""
fi
if [ ! -f "$hostKeyDir/ssh_host_dsa_key" ] ; then
ssh-keygen -t dsa -f "$hostKeyDir/ssh_host_dsa_key" -N ""
fi
if [ ! -f "$hostKeyDir/ssh_host_rsa_key" ] ; then
ssh-keygen -t rsa -f "$hostKeyDir/ssh_host_rsa_key" -N ""
fi
@@ -1,17 +1,0 @@
Notes for OpenSSL 0.9.8g (Haiku r24681)
=======================================
configure
---------
./config --prefix=/boot/home/config zlib shared no-sse2
* zlib instead of zlib-dynamic: dlopen() in Haiku needs fixing.
* no-sse2: Haiku SSE2 support is broken/non-existent.
make/install
------------
make
make install
@@ -1,54 +1,0 @@
diff -ur openssl-0.9.8g-orig/Configure openssl-0.9.8g/Configure
--- openssl-0.9.8g-orig/Configure 2007-09-16 12:24:17.000000000 +0000
+++ openssl-0.9.8g/Configure 2008-03-29 00:02:46.000000000 +0000
@@ -527,6 +527,9 @@
##### Compaq Non-Stop Kernel (Tandem)
"tandem-c89","c89:-Ww -D__TANDEM -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1 -D_TANDEM_SOURCE -DB_ENDIAN::(unknown):::THIRTY_TWO_BIT:::",
+##### Haiku
+"haiku-x86", "gcc:-DL_ENDIAN -O2 -fomit-frame-pointer -Wall::-D_REENTRANT::-lnetwork:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:haiku-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
+
);
my @MK1MF_Builds=qw(VC-WIN64I VC-WIN64A
diff -ur openssl-0.9.8g-orig/Makefile.shared openssl-0.9.8g/Makefile.shared
--- openssl-0.9.8g-orig/Makefile.shared 2007-09-16 14:11:51.000000000 +0000
+++ openssl-0.9.8g/Makefile.shared 2008-03-28 19:24:17.000000000 +0000
@@ -552,10 +552,10 @@
symlink.cygwin symlink.alpha-osf1 symlink.tru64 symlink.tru64-rpath:
# Compatibility targets
-link_o.bsd-gcc-shared link_o.linux-shared link_o.gnu-shared: link_o.gnu
-link_a.bsd-gcc-shared link_a.linux-shared link_a.gnu-shared: link_a.gnu
-link_app.bsd-gcc-shared link_app.linux-shared link_app.gnu-shared: link_app.gnu
-symlink.bsd-gcc-shared symlink.bsd-shared symlink.linux-shared symlink.gnu-shared: symlink.gnu
+link_o.bsd-gcc-shared link_o.linux-shared link_o.gnu-shared link_o.haiku-shared: link_o.gnu
+link_a.bsd-gcc-shared link_a.linux-shared link_a.gnu-shared link_a.haiku-shared: link_a.gnu
+link_app.bsd-gcc-shared link_app.linux-shared link_app.gnu-shared link_app.haiku-shared: link_app.gnu
+symlink.bsd-gcc-shared symlink.bsd-shared symlink.linux-shared symlink.gnu-shared symlink.haiku-shared: symlink.gnu
link_o.bsd-shared: link_o.bsd
link_a.bsd-shared: link_a.bsd
link_app.bsd-shared: link_app.bsd
diff -ur openssl-0.9.8g-orig/config openssl-0.9.8g/config
--- openssl-0.9.8g-orig/config 2007-08-01 11:21:35.000000000 +0000
+++ openssl-0.9.8g/config 2008-03-28 19:17:06.000000000 +0000
@@ -126,6 +126,10 @@
echo "${MACHINE}-dg-dgux"; exit 0
;;
+ Haiku:*:BePC)
+ echo "i586-pc-haiku"; exit 0
+ ;;
+
HI-UX:*)
echo "${MACHINE}-hi-hiux"; exit 0
;;
@@ -755,6 +759,8 @@
options="$options no-asm"
fi
;;
+ i586-*-haiku) OUT="haiku-x86" ;;
+
# these are all covered by the catchall below
# *-dgux) OUT="dgux" ;;
mips-sony-newsos4) OUT="newsos4-gcc" ;;
@@ -1,617 +1,0 @@
Index: perlio.h
===================================================================
--- perlio.h (.../vendor/perl/current) (revision 21)
+++ perlio.h (.../trunk) (revision 21)
@@ -64,7 +64,7 @@
*/
#include <stdio.h>
-#ifdef __BEOS__
+#if defined(__BEOS__) && !defined(__HAIKU__)
int fseeko(FILE *stream, off_t offset, int whence);
off_t ftello(FILE *stream);
#endif
Index: haiku/haikuish.h
===================================================================
--- haiku/haikuish.h (.../vendor/perl/current) (revision 0)
+++ haiku/haikuish.h (.../trunk) (revision 21)
@@ -0,0 +1,11 @@
+#ifndef PERL_HAIKU_HAIKUISH_H
+#define PERL_HAIKU_HAIKUISH_H
+
+#include "../unixish.h"
+
+/* We need <sys/wait.h> or else the W* macros aren't defined in perl.h. */
+
+#include <sys/wait.h>
+
+#endif
+
Index: perl.c
===================================================================
--- perl.c (.../vendor/perl/current) (revision 21)
+++ perl.c (.../trunk) (revision 21)
@@ -107,7 +107,7 @@
#endif
-#ifdef __BEOS__
+#if defined(__BEOS__) && !defined(__HAIKU__)
# define HZ 1000000
#endif
@@ -381,7 +381,7 @@
* BeOS has those, but returns the wrong value.
* The HZ if not originally defined has been by now
* been defined as CLK_TCK, if available. */
-#if defined(HAS_SYSCONF) && defined(_SC_CLK_TCK) && !defined(__BEOS__)
+#if defined(HAS_SYSCONF) && defined(_SC_CLK_TCK) && (!defined(__BEOS__) || defined(__HAIKU__))
PL_clocktick = sysconf(_SC_CLK_TCK);
if (PL_clocktick <= 0)
#endif
Index: perl.h
===================================================================
--- perl.h (.../vendor/perl/current) (revision 21)
+++ perl.h (.../trunk) (revision 21)
@@ -2551,7 +2551,10 @@
# define ISHISH "macos classic"
#endif
-#if defined(__BEOS__)
+#if defined(__HAIKU__)
+# include "haiku/haikuish.h"
+# define ISHISH "haiku"
+#elif defined(__BEOS__)
# include "beos/beosish.h"
# define ISHISH "beos"
#endif
@@ -5609,9 +5612,10 @@
#if O_TEXT != O_BINARY
/* If you have different O_TEXT and O_BINARY and you are a CLRF shop,
* that is, you are somehow DOSish. */
-# if defined(__BEOS__) || defined(__VOS__) || defined(__CYGWIN__)
- /* BeOS has O_TEXT != O_BINARY but O_TEXT and O_BINARY have no effect;
- * BeOS is always UNIXoid (LF), not DOSish (CRLF). */
+# if defined(__BEOS__) || defined(__HAIKU__) || defined(__VOS__) || \
+ defined(__CYGWIN__)
+ /* BeOS/Haiku has O_TEXT != O_BINARY but O_TEXT and O_BINARY have no effect;
+ * BeOS/Haiku is always UNIXoid (LF), not DOSish (CRLF). */
/* VOS has O_TEXT != O_BINARY, and they have effect,
* but VOS always uses LF, never CRLF. */
/* If you have O_TEXT different from your O_BINARY but you still are
Index: lib/CPANPLUS/Internals/Constants/Report.pm
===================================================================
--- lib/CPANPLUS/Internals/Constants/Report.pm (.../vendor/perl/current) (revision 21)
+++ lib/CPANPLUS/Internals/Constants/Report.pm (.../trunk) (revision 21)
@@ -29,6 +29,7 @@
Cygwin => 'cygwin',
Darwin => 'darwin',
EBCDIC => 'os390|os400|posix-bc|vmesa',
+ Haiku => 'haiku',
HPUX => 'hpux',
Linux => 'linux',
MSDOS => 'dos|os2|MSWin32|cygwin',
Index: lib/CPANPLUS/t/20_CPANPLUS-Dist-MM.t
===================================================================
--- lib/CPANPLUS/t/20_CPANPLUS-Dist-MM.t (.../vendor/perl/current) (revision 21)
+++ lib/CPANPLUS/t/20_CPANPLUS-Dist-MM.t (.../trunk) (revision 21)
@@ -45,7 +45,13 @@
$conf->set_conf( cpantest => 0 );
### Redirect errors to file ###
-*STDERR = output_handle() unless $Verbose;
+### The code in IPC::Cmd::_open3_run() uses a pipe to get the child's stderr
+### output and IPC::Open3::_open3() will not dup the child's error end to the
+### original STDERR FD. Instead it will assign the pipe's write end FD, which
+### will be CLOEXEC. On exec() this FD will be closed and the select()+read()
+### loop in IPC::Cmd::_open3_run() will become very busy, since select()
+### will always return immediately due to the half-closed pipe.
+#*STDERR = output_handle() unless $Verbose;
### dont uncomment this, it screws up where STDOUT goes and makes
### test::harness create test counter mismatches
Index: lib/Module/Build.pm
===================================================================
--- lib/Module/Build.pm (.../vendor/perl/current) (revision 21)
+++ lib/Module/Build.pm (.../trunk) (revision 21)
@@ -30,6 +30,7 @@
dynixptx Unix
freebsd Unix
linux Unix
+ haiku Unix
hpux Unix
irix Unix
darwin Unix
Index: lib/Term/ReadLine.pm
===================================================================
--- lib/Term/ReadLine.pm (.../vendor/perl/current) (revision 21)
+++ lib/Term/ReadLine.pm (.../trunk) (revision 21)
@@ -222,7 +222,8 @@
$console = "sys\$command";
}
- if (($^O eq 'amigaos') || ($^O eq 'beos') || ($^O eq 'epoc')) {
+ if (($^O eq 'amigaos') || ($^O eq 'beos') || ($^O eq 'epoc') ||
+ ($^O eq 'haiku')) {
$console = undef;
}
elsif ($^O eq 'os2') {
Index: lib/ExtUtils/MM.pm
===================================================================
--- lib/ExtUtils/MM.pm (.../vendor/perl/current) (revision 21)
+++ lib/ExtUtils/MM.pm (.../trunk) (revision 21)
@@ -69,6 +69,7 @@
$Is{VOS} = $^O eq 'vos';
$Is{QNX} = $^O eq 'qnx';
$Is{AIX} = $^O eq 'aix';
+$Is{Haiku} = $^O eq 'haiku';
$Is{Unix} = !grep { $_ } values %Is;
Index: lib/ExtUtils/MM_Haiku.pm
===================================================================
--- lib/ExtUtils/MM_Haiku.pm (.../vendor/perl/current) (revision 0)
+++ lib/ExtUtils/MM_Haiku.pm (.../trunk) (revision 21)
@@ -0,0 +1,62 @@
+package ExtUtils::MM_Haiku;
+
+use strict;
+
+=head1 NAME
+
+ExtUtils::MM_Haiku - methods to override UN*X behaviour in ExtUtils::MakeMaker
+
+=head1 SYNOPSIS
+
+ use ExtUtils::MM_Haiku; # Done internally by ExtUtils::MakeMaker if needed
+
+=head1 DESCRIPTION
+
+See ExtUtils::MM_Unix for a documentation of the methods provided
+there. This package overrides the implementation of these methods, not
+the semantics.
+
+=over 4
+
+=cut
+
+use ExtUtils::MakeMaker::Config;
+use File::Spec;
+require ExtUtils::MM_Any;
+require ExtUtils::MM_Unix;
+
+use vars qw(@ISA $VERSION);
+@ISA = qw( ExtUtils::MM_Any ExtUtils::MM_Unix );
+$VERSION = '6.42';
+
+
+=item os_flavor
+
+Haiku is Haiku.
+
+=cut
+
+sub os_flavor {
+ return('Haiku');
+}
+
+=item init_linker
+
+libperl.a equivalent to be linked to dynamic extensions.
+
+=cut
+
+sub init_linker {
+ my($self) = shift;
+
+ $self->{PERL_ARCHIVE} ||=
+ File::Spec->catdir('$(PERL_INC)',$Config{libperl});
+ $self->{PERL_ARCHIVE_AFTER} ||= '';
+ $self->{EXPORT_LIST} ||= '';
+}
+
+=back
+
+1;
+__END__
+
Index: t/io/fs.t
===================================================================
--- t/io/fs.t (.../vendor/perl/current) (revision 21)
+++ t/io/fs.t (.../trunk) (revision 21)
@@ -275,7 +275,7 @@
is( $atime, 500000001, 'atime' );
is( $mtime, 500000000 + $delta, 'mtime' );
}
- elsif ($^O eq 'beos') {
+ elsif ($^O eq 'beos' || $^O eq 'haiku') {
SKIP: {
skip "atime not updated", 1;
}
Index: hints/haiku.sh
===================================================================
--- hints/haiku.sh (.../vendor/perl/current) (revision 0)
+++ hints/haiku.sh (.../trunk) (revision 21)
@@ -0,0 +1,56 @@
+# Haiku hints file
+# $Id$
+
+prefix="/boot/home/config"
+
+libpth='/boot/home/config/lib /boot/common/lib /boot/system/lib'
+usrinc='/boot/develop/headers/posix'
+locinc='/boot/home/config/include /boot/common/include /boot/develop/headers'
+
+libc='/boot/system/lib/libroot.so'
+libs=' '
+
+#d_bcmp='define'
+#d_bcopy='define'
+#d_bzero='define'
+#d_index='define'
+#d_htonl='define' # It exists, but much hackery would be required to support.
+# a bunch of extra includes would have to be added, and it's only used at
+# one place in the non-socket perl code.
+
+#these are all in libdll.a, which my version of nm doesn't know how to parse.
+#if I can get it to both do that, and scan multiple library files, perhaps
+#these can be gotten rid of.
+
+case "$usemymalloc" in
+'') usemymalloc='n' ;;
+esac
+# Hopefully, Be's malloc knows better than perl's.
+
+d_link='undef'
+dont_use_nlink='define'
+# no posix (aka hard) links for us!
+
+d_syserrlst='undef'
+# the array syserrlst[] is useless for the most part.
+# large negative numbers really kind of suck in arrays.
+
+# Sockets didn't use to be real sockets but BONE changes this.
+#if [ ! -f /boot/develop/headers/be/bone/sys/socket.h ]; then
+# d_socket='undef'
+# d_gethbyaddr='undef'
+# d_gethbyname='undef'
+# d_getsbyname='undef'
+#
+# libs='-lnet'
+#fi
+
+
+cc="gcc"
+ld='gcc'
+
+export PATH="$PATH:$PWD/haiku"
+
+case "$ldlibpthname" in
+'') ldlibpthname=LIBRARY_PATH ;;
+esac
Index: ext/Errno/Errno_pm.PL
===================================================================
--- ext/Errno/Errno_pm.PL (.../vendor/perl/current) (revision 21)
+++ ext/Errno/Errno_pm.PL (.../trunk) (revision 21)
@@ -155,7 +155,7 @@
# we might miss out on compiler-specific ones
$file{"$ENV{GUSI}include:sys:errno.h"} = 1;
- } elsif ($^O eq 'beos') {
+ } elsif ($^O eq 'beos' || $^O eq 'haiku') {
# hidden in a special place
$file{'/boot/develop/headers/posix/errno.h'} = 1;
@@ -250,7 +250,8 @@
close(CPPI);
- unless ($^O eq 'MacOS' || $^O eq 'beos') { # trust what we have / get later
+ unless ($^O eq 'MacOS' || $^O eq 'beos' || $^O eq 'haiku') {
+ # trust what we have / get later
# invoke CPP and read the output
if ($^O eq 'VMS') {
@@ -293,12 +294,12 @@
# Many of the E constants (including ENOENT, which is being
# used in the Perl test suite a lot), are available only as
- # enums in BeOS, so compiling and executing some code is about
+ # enums in BeOS/Haiku, so compiling and executing some code is about
# only way to find out what the numeric Evalues are. In fact above, we
# didn't even bother to get the values of the ones that have numeric
# values, since we can get all of them here, anyway.
- if ($^O eq 'beos') {
+ if ($^O eq 'beos' || $^O eq 'haiku') {
if (open(C, ">errno.c")) {
my @allerrs = keys %err;
print C <<EOF;
Index: ext/Compress/Raw/Zlib/zlib-src/zutil.h
===================================================================
--- ext/Compress/Raw/Zlib/zlib-src/zutil.h (.../vendor/perl/current) (revision 21)
+++ ext/Compress/Raw/Zlib/zlib-src/zutil.h (.../trunk) (revision 21)
@@ -147,7 +147,7 @@
# define OS_CODE 0x0f
#endif
-#if defined(_BEOS_) || defined(RISCOS)
+#if (defined(_BEOS_) && !defined(__HAIKU__)) || defined(RISCOS)
# define fdopen(fd,mode) NULL /* No fdopen() */
#endif
Index: ext/Time/HiRes/t/HiRes.t
===================================================================
--- ext/Time/HiRes/t/HiRes.t (.../vendor/perl/current) (revision 21)
+++ ext/Time/HiRes/t/HiRes.t (.../trunk) (revision 21)
@@ -337,7 +337,8 @@
&& defined &Time::HiRes::getitimer
&& has_symbol('ITIMER_VIRTUAL')
&& $Config{sig_name} =~ m/\bVTALRM\b/
- && $^O !~ /^(nto)$/) { # nto: QNX 6 has the API but no implementation
+ && $^O !~ /^(nto)$/ # nto: QNX 6 has the API but no implementation
+ && $^O ne 'haiku') { # same for Haiku
for (18..19) {
print "ok $_ # Skip: no virtual interval timers\n";
}
Index: ext/Haiku/Makefile.PL
===================================================================
--- ext/Haiku/Makefile.PL (.../vendor/perl/current) (revision 0)
+++ ext/Haiku/Makefile.PL (.../trunk) (revision 21)
@@ -0,0 +1,20 @@
+use 5.006;
+use ExtUtils::MakeMaker;
+
+unless ($^O eq "haiku") {
+ die "OS unsupported\n";
+}
+
+#my @libs;
+#push @libs, '-L/lib/w32api -lole32 -lversion' if $^O eq "cygwin";
+
+WriteMakefile(
+ NAME => 'Haiku',
+ VERSION_FROM => 'Haiku.pm',
+# LIBS => \@libs,
+ INSTALLDIRS => ($] >= 5.008004 ? 'perl' : 'site'),
+ NO_META => 1,
+
+ AUTHOR => 'Ingo Weinhold <ingo_weinhold@gmx.de>',
+ ABSTRACT_FROM => 'Haiku.pm',
+);
Index: ext/Haiku/Haiku.xs
===================================================================
--- ext/Haiku/Haiku.xs (.../vendor/perl/current) (revision 0)
+++ ext/Haiku/Haiku.xs (.../trunk) (revision 21)
@@ -0,0 +1,141 @@
+#define PERL_NO_GET_CONTEXT
+#include "EXTERN.h"
+#include "perl.h"
+#include "XSUB.h"
+
+#include <stdarg.h>
+
+#include <OS.h>
+
+static void
+haiku_do_debugger(const char* format,...)
+{
+ char buffer[1024];
+ va_list args;
+ va_start(args, format);
+ my_vsnprintf(buffer, sizeof(buffer), format, args);
+ va_end(args);
+
+ debugger(buffer);
+}
+
+static void
+haiku_do_debug_printf(pTHX_ register SV *sv,
+ void (*printfFunc)(const char*,...))
+{
+ dVAR;
+
+ if (!sv)
+ return;
+ if (SvTYPE(sv) == SVt_IV && SvIOK(sv)) {
+ assert(!SvGMAGICAL(sv));
+ if (SvIsUV(sv))
+ (*printfFunc)("%"UVuf, (UV)SvUVX(sv));
+ else
+ (*printfFunc)("%"IVdf, (IV)SvIVX(sv));
+ return;
+ }
+ else {
+ STRLEN len;
+ /* Do this first to trigger any overloading. */
+ const char *tmps = SvPV_const(sv, len);
+ U8 *tmpbuf = NULL;
+#undef strnlen
+if (strnlen(tmps, len) != len)
+haiku_do_debugger("haiku_do_debug_printf(): len: %lu, acually: %lu",
+len, strnlen(tmps, len));
+
+ if (!SvUTF8(sv)) {
+ /* We don't modify the original scalar. */
+ tmpbuf = bytes_to_utf8((const U8*) tmps, &len);
+ tmps = (char *) tmpbuf;
+ }
+
+ if (len)
+ (*printfFunc)("%.*s", (int)len, tmps);
+ Safefree(tmpbuf);
+ }
+}
+
+XS(haiku_debug_printf)
+{
+ dVAR;
+ dXSARGS;
+ dORIGMARK;
+ SV *sv;
+
+ if (items < 1)
+ Perl_croak(aTHX_ "usage: Haiku::debug_printf($format,...)");
+
+ sv = newSV(0);
+
+ if (SvTAINTED(MARK[1]))
+ TAINT_PROPER("debug_printf");
+ do_sprintf(sv, SP - MARK, MARK + 1);
+
+ haiku_do_debug_printf(sv, &debug_printf);
+
+ SvREFCNT_dec(sv);
+ SP = ORIGMARK;
+ PUSHs(&PL_sv_yes);
+}
+
+XS(haiku_ktrace_printf)
+{
+ dVAR;
+ dXSARGS;
+ dORIGMARK;
+ SV *sv;
+
+ if (items < 1)
+ Perl_croak(aTHX_ "usage: Haiku::debug_printf($format,...)");
+
+ sv = newSV(0);
+
+ if (SvTAINTED(MARK[1]))
+ TAINT_PROPER("ktrace_printf");
+ do_sprintf(sv, SP - MARK, MARK + 1);
+
+ haiku_do_debug_printf(sv, &ktrace_printf);
+
+ SvREFCNT_dec(sv);
+ SP = ORIGMARK;
+ PUSHs(&PL_sv_yes);
+}
+
+XS(haiku_debugger)
+{
+ dVAR;
+ dXSARGS;
+ dORIGMARK;
+ SV *sv;
+
+ if (items < 1)
+ Perl_croak(aTHX_ "usage: Haiku::debugger($format,...)");
+
+ sv = newSV(0);
+
+ if (SvTAINTED(MARK[1]))
+ TAINT_PROPER("debugger");
+ do_sprintf(sv, SP - MARK, MARK + 1);
+
+ haiku_do_debug_printf(sv, &haiku_do_debugger);
+
+ SvREFCNT_dec(sv);
+ SP = ORIGMARK;
+ PUSHs(&PL_sv_yes);
+}
+
+MODULE = Haiku PACKAGE = Haiku
+
+PROTOTYPES: DISABLE
+
+BOOT:
+{
+ char *file = __FILE__;
+
+ newXS("Haiku::debug_printf", haiku_debug_printf, file);
+ newXS("Haiku::ktrace_printf", haiku_ktrace_printf, file);
+ newXS("Haiku::debugger", haiku_debugger, file);
+ XSRETURN_YES;
+}
Index: ext/Haiku/Haiku.pm
===================================================================
--- ext/Haiku/Haiku.pm (.../vendor/perl/current) (revision 0)
+++ ext/Haiku/Haiku.pm (.../trunk) (revision 21)
@@ -0,0 +1,54 @@
+package Haiku;
+
+BEGIN {
+ use strict;
+ use vars qw|$VERSION $XS_VERSION @ISA @EXPORT @EXPORT_OK|;
+
+ require Exporter;
+ require DynaLoader;
+
+ @ISA = qw|Exporter DynaLoader|;
+ $VERSION = '0.34';
+ $XS_VERSION = $VERSION;
+ $VERSION = eval $VERSION;
+
+ @EXPORT = qw(
+ );
+ @EXPORT_OK = qw(
+ );
+}
+
+bootstrap Haiku;
+
+1;
+
+__END__
+
+=head1 NAME
+
+Haiku - Interfaces to some Haiku API Functions
+
+=head1 DESCRIPTION
+
+The Haiku module contains functions to access Haiku APIs.
+
+=head2 Alphabetical Listing of Haiku Functions
+
+=over
+
+=item Haiku::debug_printf(FORMAT,...)
+
+Similar to printf, but prints to system debug output.
+
+=item Haiku::debugger(FORMAT,...)
+
+Drops the program into the debugger. The printf like arguments define the
+debugger message.
+
+=item Haiku::ktrace_printf(FORMAT,...)
+
+Similar to printf, but prints to a kernel tracing entry.
+
+=back
+
+=cut
Index: Configure
===================================================================
--- Configure (.../vendor/perl/current) (revision 21)
+++ Configure (.../trunk) (revision 21)
@@ -7864,6 +7864,7 @@
case "$lddlflags" in
'') case "$osname" in
beos) dflt='-nostart' ;;
+ haiku) dflt='-nostart' ;;
hpux) dflt='-b';
case "$gccversion" in
'') dflt="$dflt +vnocompatwarnings" ;;
@@ -7946,7 +7947,7 @@
;;
*) case "$useshrplib" in
'') case "$osname" in
- svr4*|nonstopux|dgux|dynixptx|esix|powerux|beos|cygwin*)
+ svr4*|nonstopux|dgux|dynixptx|esix|powerux|beos|cygwin*|haiku)
dflt=y
also='Building a shared libperl is required for dynamic loading to work on your system.'
;;
@@ -8109,6 +8110,9 @@
beos)
# beos doesn't like the default, either.
;;
+ haiku)
+ # Haiku doesn't like the default, either.
+ ;;
hpux*)
# hpux doesn't like the default, either.
tmp_shrpenv="env LDOPTS=\"+s +b${shrpdir}\""
@@ -1,12 +1,0 @@
diff -ur texinfo-4.11-orig/system.h texinfo-4.11/system.h
--- texinfo-4.11-orig/system.h 2007-07-01 21:20:28.000000000 +0000
+++ texinfo-4.11/system.h 2008-03-24 01:02:31.000000000 +0000
@@ -154,7 +154,7 @@
# define va_end(args)
#endif
-#if O_BINARY
+#if O_BINARY && !defined(__BEOS__)
# ifdef HAVE_IO_H
# include <io.h>
# endif