mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
added bep file for ocaml 4.00.0
This commit is contained in:
22
dev-lang/ocaml/ocaml-4.00.0.bep
Normal file
22
dev-lang/ocaml/ocaml-4.00.0.bep
Normal file
@@ -0,0 +1,22 @@
|
||||
DESCRIPTION="Implementation of the Caml language"
|
||||
HOMEPAGE="http://caml.inria.fr/index.en.html"
|
||||
SRC_URI="http://caml.inria.fr/pub/distrib/ocaml-4.00/ocaml-4.00.0.tar.gz"
|
||||
CHECKSUM_MD5="fa11560a45793bd9fa45c1295a6f4a91"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="untested"
|
||||
DEPEND=""
|
||||
BUILD {
|
||||
cd ocaml-4.00.0
|
||||
COMMON_DOCS=`finddir B_COMMON_DOCUMENTATION_DIRECTORY`
|
||||
./configure --prefix `finddir B_COMMON_DIRECTORY` \
|
||||
--mandir $COMMON_DOCS/man
|
||||
make world.opt
|
||||
}
|
||||
|
||||
INSTALL {
|
||||
cd ocaml-4.00.0
|
||||
make install PREFIX=${DESTDIR}`finddir B_COMMON_DIRECTORY`
|
||||
|
||||
}
|
||||
LICENSE="GNU LGPL v2"
|
||||
COPYRIGHT="1996-2012 Institut National de Recherche en Informatique et en Automatique (INRIA)."
|
||||
59
dev-lang/ocaml/patches/ocaml-4.00.0.patch
Normal file
59
dev-lang/ocaml/patches/ocaml-4.00.0.patch
Normal file
@@ -0,0 +1,59 @@
|
||||
diff -ruN ocaml-4.00.0/configure ocaml-4.00.0/configure
|
||||
--- ocaml-4.00.0/configure 2012-06-26 15:33:50.060555264 +0000
|
||||
+++ ocaml-4.00.0/configure 2012-09-25 21:21:50.419168256 +0000
|
||||
@@ -285,6 +285,10 @@
|
||||
bytecccompopts="-fno-defer-pop $gcc_warnings"
|
||||
# No -lm library
|
||||
mathlib="";;
|
||||
+ *,*-*-haiku*)
|
||||
+ bytecccompopts="-fno-defer-pop $gcc_warnings"
|
||||
+ # No -lm library
|
||||
+ mathlib="";;
|
||||
gcc,alpha*-*-osf*)
|
||||
bytecccompopts="-fno-defer-pop $gcc_warnings"
|
||||
if cc="$bytecc" sh ./hasgot -mieee; then
|
||||
@@ -614,6 +618,9 @@
|
||||
byteccrpath="-Wl,-rpath,"
|
||||
mksharedlibrpath="-Wl,-rpath,"
|
||||
shared_libraries_supported=true;;
|
||||
+ *-*haiku*)
|
||||
+ mksharedlib="$bytecc -shared"
|
||||
+ shared_libraries_supported=true;;
|
||||
esac
|
||||
fi
|
||||
|
||||
@@ -679,6 +686,7 @@
|
||||
arch=i386; system=solaris
|
||||
fi;;
|
||||
i[3456]86-*-beos*) arch=i386; system=beos;;
|
||||
+ i[3456]86-*-haiku*) arch=i386; system=beos;;
|
||||
i[3456]86-*-cygwin*) arch=i386; system=cygwin;;
|
||||
i[3456]86-*-darwin*) if $arch64; then
|
||||
arch=amd64; system=macosx
|
||||
@@ -901,6 +909,11 @@
|
||||
cclibs="$cclibs -lnsl -lsocket"
|
||||
echo "#define HAS_SOCKETS" >> s.h
|
||||
has_sockets=yes
|
||||
+elif sh ./hasgot -lnetwork socket socketpair bind listen accept connect; then
|
||||
+ echo "You have BSD sockets (with libraries '-lnetwork')"
|
||||
+ cclibs="$cclibs -lnetwork"
|
||||
+ echo "#define HAS_SOCKETS" >> s.h
|
||||
+ has_sockets=yes
|
||||
fi
|
||||
|
||||
if sh ./hasgot -i sys/socket.h -t socklen_t; then
|
||||
diff -uN ocaml-4.00.0/otherlibs/unix/nice.c ocaml-4.00.0/otherlibs/unix/nice.c
|
||||
--- ocaml-4.00.0/otherlibs/unix/nice.c 2012-09-25 21:31:10.443809792 +0000
|
||||
+++ ocaml-4.00.0/otherlibs/unix/nice.c 2012-09-25 21:31:51.582221824 +0000
|
||||
@@ -24,7 +24,11 @@
|
||||
{
|
||||
int ret;
|
||||
errno = 0;
|
||||
+#ifdef __HAIKU__
|
||||
+ ret = 0;
|
||||
+#else
|
||||
ret = nice(Int_val(incr));
|
||||
+#endif
|
||||
if (ret == -1 && errno != 0) uerror("nice", Nothing);
|
||||
return Val_int(ret);
|
||||
}
|
||||
Reference in New Issue
Block a user