mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 04:00:05 +02:00
swi_prolog, bump version, leave disabled for further testing (#9555)
This commit is contained in:
@@ -1,5 +0,0 @@
|
||||
The SWI-Prolog Prolog libraries
|
||||
|
||||
Lacking a satisfactory technical solution to handle article 6 of the LGPL, this license cannot be used for the Prolog source code that is part of the SWI-Prolog system (both libraries and kernel code). This situation is comparable to libgcc, the runtime library used with the GNU C-compiler. Therefore, we use the same proven license terms as this library. The libgcc license is the GPL, accompanied with a special exception. Below we rephrased this exception adjusted to our needs:
|
||||
|
||||
As a special exception, if you link this library with other files, compiled with a Free Software compiler, to produce an executable, this library does not by itself cause the resulting executable to be covered by the GNU General Public License. This exception does not however invalidate any other reasons why the executable file might be covered by the GNU General Public License.
|
||||
@@ -1,68 +0,0 @@
|
||||
diff -Naur pl-6.0.2/src/configure.in pl-6.0.2-haiku/src/configure.in
|
||||
--- pl-6.0.2/src/configure.in 2012-03-04 13:12:01.001835008 +0000
|
||||
+++ pl-6.0.2-haiku/src/configure.in 2012-08-20 21:39:21.649330688 +0100
|
||||
@@ -689,6 +689,10 @@
|
||||
AC_DEFINE(_THREAD_SAFE, 1,
|
||||
[Required in FreeBSD for compiling thread-safe code])
|
||||
;;
|
||||
+ *haiku*)
|
||||
+ pthread_ok=true
|
||||
+ CFLAGS="$CFLAGS -lroot"
|
||||
+ ;;
|
||||
*-win32|*-win64)
|
||||
pthread_ok=true
|
||||
AC_CHECK_LIB(pthreadGC2, pthread_create)
|
||||
diff -Naur pl-6.0.2/src/os/pl-files.c pl-6.0.2-haiku/src/os/pl-files.c
|
||||
--- pl-6.0.2/src/os/pl-files.c 2012-03-04 13:12:01.011272192 +0000
|
||||
+++ pl-6.0.2-haiku/src/os/pl-files.c 2012-08-23 14:45:48.981204992 +0100
|
||||
@@ -239,7 +239,7 @@
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
-#ifdef __unix__ /* doesn't work on most not Unix's */
|
||||
+#if defined(__unix__) || defined(__HAIKU__) /* doesn't work on most not Unix's */
|
||||
{ statstruct buf1;
|
||||
statstruct buf2;
|
||||
char tmp[MAXPATHLEN];
|
||||
diff -Naur pl-6.0.2/src/os/pl-os.c pl-6.0.2-haiku/src/os/pl-os.c
|
||||
--- pl-6.0.2/src/os/pl-os.c 2012-03-04 13:12:01.011796480 +0000
|
||||
+++ pl-6.0.2-haiku/src/os/pl-os.c 2012-08-23 16:02:11.794034176 +0100
|
||||
@@ -590,7 +590,7 @@
|
||||
}
|
||||
|
||||
retry:
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
{ static int MTOK_temp_counter = 0;
|
||||
const char *sep = id[0] ? "_" : "";
|
||||
|
||||
@@ -732,7 +732,7 @@
|
||||
}
|
||||
#endif /* O_HPFS */
|
||||
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
char *
|
||||
PrologPath(const char *p, char *buf, size_t len)
|
||||
{ strncpy(buf, p, len);
|
||||
@@ -2436,7 +2436,7 @@
|
||||
return strcpy(buffer, file ? file : buf);
|
||||
}
|
||||
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
static char *
|
||||
okToExec(const char *s)
|
||||
{ statstruct stbuff;
|
||||
diff -Naur pl-6.0.2/src/pl-term.c pl-6.0.2-haiku/src/pl-term.c
|
||||
--- pl-6.0.2/src/pl-term.c 2012-03-04 13:12:01.023592960 +0000
|
||||
+++ pl-6.0.2-haiku/src/pl-term.c 2012-08-08 20:03:23.111673344 +0100
|
||||
@@ -296,7 +296,7 @@
|
||||
term_t r = A1;
|
||||
term_t c = A2;
|
||||
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
int iorval;
|
||||
|
||||
#ifdef TIOCGSIZE
|
||||
@@ -1,67 +0,0 @@
|
||||
diff -Naur pl-6.2.0/src/configure.in pl-6.2.0-haiku/src/configure.in
|
||||
--- pl-6.2.0/src/configure.in 2012-08-21 13:12:53.016777216 +0100
|
||||
+++ pl-6.2.0-haiku/src/configure.in 2012-08-23 17:06:25.987758592 +0100
|
||||
@@ -728,6 +728,9 @@
|
||||
AC_DEFINE(_THREAD_SAFE, 1,
|
||||
[Required in FreeBSD for compiling thread-safe code])
|
||||
;;
|
||||
+ *-haiku*)
|
||||
+ pthread_ok=true
|
||||
+ ;;
|
||||
*-win32|*-win64)
|
||||
pthread_ok=true
|
||||
AC_CHECK_LIB(pthreadGC2, pthread_create)
|
||||
diff -Naur pl-6.2.0/src/os/pl-files.c pl-6.2.0-haiku/src/os/pl-files.c
|
||||
--- pl-6.2.0/src/os/pl-files.c 2012-08-21 13:12:53.026214400 +0100
|
||||
+++ pl-6.2.0-haiku/src/os/pl-files.c 2012-08-23 17:07:04.695992320 +0100
|
||||
@@ -302,7 +302,7 @@
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
-#ifdef __unix__ /* doesn't work on most not Unix's */
|
||||
+#if defined(__unix__) || defined(__HAIKU__) /* doesn't work on most not Unix's */
|
||||
{ statstruct buf1;
|
||||
statstruct buf2;
|
||||
char tmp[MAXPATHLEN];
|
||||
diff -Naur pl-6.2.0/src/os/pl-os.c pl-6.2.0-haiku/src/os/pl-os.c
|
||||
--- pl-6.2.0/src/os/pl-os.c 2012-08-21 13:12:53.027000832 +0100
|
||||
+++ pl-6.2.0-haiku/src/os/pl-os.c 2012-08-23 17:09:14.962330624 +0100
|
||||
@@ -601,7 +601,7 @@
|
||||
}
|
||||
|
||||
retry:
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
{ static int MTOK_temp_counter = 0;
|
||||
const char *sep = id[0] ? "_" : "";
|
||||
|
||||
@@ -743,7 +743,7 @@
|
||||
}
|
||||
#endif /* O_HPFS */
|
||||
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
char *
|
||||
PrologPath(const char *p, char *buf, size_t len)
|
||||
{ strncpy(buf, p, len);
|
||||
@@ -2507,7 +2507,7 @@
|
||||
return strcpy(buffer, file ? file : buf);
|
||||
}
|
||||
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
static char *
|
||||
okToExec(const char *s)
|
||||
{ statstruct stbuff;
|
||||
diff -Naur pl-6.2.0/src/pl-term.c pl-6.2.0-haiku/src/pl-term.c
|
||||
--- pl-6.2.0/src/pl-term.c 2012-08-21 13:12:53.038535168 +0100
|
||||
+++ pl-6.2.0-haiku/src/pl-term.c 2012-08-23 17:09:57.306708480 +0100
|
||||
@@ -296,7 +296,7 @@
|
||||
term_t r = A1;
|
||||
term_t c = A2;
|
||||
|
||||
-#ifdef __unix__
|
||||
+#if defined(__unix__) || defined(__HAIKU__)
|
||||
int iorval;
|
||||
|
||||
#ifdef TIOCGSIZE
|
||||
47
dev-lang/swi_prolog/patches/swi_prolog-9.0.4.patchset
Normal file
47
dev-lang/swi_prolog/patches/swi_prolog-9.0.4.patchset
Normal file
@@ -0,0 +1,47 @@
|
||||
From 54c0a0873946998edc4655fac7decc8b1a415f45 Mon Sep 17 00:00:00 2001
|
||||
From: Begasus <begasus@gmail.com>
|
||||
Date: Mon, 2 Oct 2023 10:14:07 +0200
|
||||
Subject: Add linker flag for libnetwork (cmake)
|
||||
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 700acba..fee6330 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -117,6 +117,10 @@ endif()
|
||||
# Verbosity
|
||||
set(CMAKE_INSTALL_MESSAGE NEVER)
|
||||
|
||||
+if(HAIKU)
|
||||
+ set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -lnetwork")
|
||||
+endif(HAIKU)
|
||||
+
|
||||
################
|
||||
# Installation directories
|
||||
|
||||
--
|
||||
2.37.3
|
||||
|
||||
|
||||
From e0054ec443d5f62f1f86ffb56922a4d28388009b Mon Sep 17 00:00:00 2001
|
||||
From: Begasus <begasus@gmail.com>
|
||||
Date: Sun, 1 Oct 2023 21:53:47 +0200
|
||||
Subject: Build fixes
|
||||
|
||||
|
||||
diff --git a/packages/clib/sha1/brg_endian.h b/packages/clib/sha1/brg_endian.h
|
||||
index e43d690..bb6a885 100644
|
||||
--- a/packages/clib/sha1/brg_endian.h
|
||||
+++ b/packages/clib/sha1/brg_endian.h
|
||||
@@ -47,7 +47,7 @@
|
||||
#elif defined( __linux__ ) || defined( __GNUC__ ) || defined( __GNU_LIBRARY__ )
|
||||
# if !defined( __MINGW32__ )
|
||||
# include <endian.h>
|
||||
-# if !defined( __BEOS__ )
|
||||
+# if !defined( __BEOS__ ) && !defined(__HAIKU__)
|
||||
# include <byteswap.h>
|
||||
# endif
|
||||
# endif
|
||||
--
|
||||
2.37.3
|
||||
|
||||
@@ -1,69 +0,0 @@
|
||||
SUMMARY="SWI Prolog. Stable and free standard Prolog implementation"
|
||||
DESCRIPTION="
|
||||
SWI-Prolog is an open source implementation of the programming language Prolog, \
|
||||
commonly used for teaching and semantic web applications. It has a rich set of \
|
||||
features, libraries for constraint logic programming, multithreading, unit \
|
||||
testing, GUI, interfacing to Java, ODBC and others, literate programming, a web \
|
||||
server, SGML, RDF, RDFS, developer tools (including an IDE with a GUI debugger \
|
||||
and GUI profiler), and extensive documentation."
|
||||
HOMEPAGE="https://www.swi-prolog.org/"
|
||||
COPYRIGHT="1985-2012, University of Amsterdam, VU University Amsterdam"
|
||||
LICENSE="GNU LGPL v2.1
|
||||
SWI-Prolog"
|
||||
REVISION="3"
|
||||
SOURCE_URI="https://www.swi-prolog.org/download/stable/src/pl-6.2.0.tar.gz"
|
||||
CHECKSUM_SHA256="be358eacd50bc7013cdcdd1aa763e67c5b1d40f7bbf1833a7a48c0123a6455a8"
|
||||
SOURCE_DIR="pl-6.2.0"
|
||||
PATCHES="swi_prolog-6.2.0.patch"
|
||||
|
||||
ARCHITECTURES="x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
swi_prolog$secondaryArchSuffix = $portVersion
|
||||
cmd:swipl$secondaryArchSuffix
|
||||
cmd:swipl_ld$secondaryArchSuffix
|
||||
cmd:swipl_rc$secondaryArchSuffix
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libgmp$secondaryArchSuffix >= 10
|
||||
lib:libncurses$secondaryArchSuffix
|
||||
lib:libreadline$secondaryArchSuffix >= 6
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libgmp$secondaryArchSuffix >= 10
|
||||
devel:libncurses$secondaryArchSuffix
|
||||
devel:libreadline$secondaryArchSuffix >= 6
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:autoreconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cd src
|
||||
libtoolize -fci
|
||||
autoreconf
|
||||
LDFLAGS="-L/system/lib -L/system/develop/lib" CFLAGS="-I/system/develop/include -I/system/include" ./configure $configureDirArgs
|
||||
#runConfigure ./configure
|
||||
make
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
cd src
|
||||
make install
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
cd src
|
||||
make check
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
SUMMARY="SWI Prolog. Stable and free standard Prolog implementation"
|
||||
DESCRIPTION="
|
||||
SWI-Prolog is an open source implementation of the programming language Prolog, \
|
||||
commonly used for teaching and semantic web applications. It has a rich set of \
|
||||
features, libraries for constraint logic programming, multithreading, unit \
|
||||
testing, GUI, interfacing to Java, ODBC and others, literate programming, a web \
|
||||
server, SGML, RDF, RDFS, developer tools (including an IDE with a GUI debugger \
|
||||
and GUI profiler), and extensive documentation."
|
||||
HOMEPAGE="https://www.swi-prolog.org/"
|
||||
COPYRIGHT="1985-2012, University of Amsterdam, VU University Amsterdam"
|
||||
LICENSE="GNU LGPL v2.1
|
||||
SWI-Prolog"
|
||||
REVISION="3"
|
||||
SOURCE_URI="https://www.swi-prolog.org/download/stable/src/pl-6.6.6.tar.gz"
|
||||
CHECKSUM_SHA256="9f80bb274e2f31fd68b0acbe35982c012d5f8311dbe44ec1d8d04351a776996d"
|
||||
SOURCE_DIR="pl-6.6.6"
|
||||
PATCHES="swi_prolog-6.2.0.patch"
|
||||
|
||||
ARCHITECTURES="!x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
swi_prolog$secondaryArchSuffix = $portVersion
|
||||
cmd:swipl$secondaryArchSuffix
|
||||
cmd:swipl_ld$secondaryArchSuffix
|
||||
cmd:swipl_rc$secondaryArchSuffix
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libgmp$secondaryArchSuffix >= 10
|
||||
lib:libncurses$secondaryArchSuffix
|
||||
lib:libreadline$secondaryArchSuffix >= 6
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libgmp$secondaryArchSuffix >= 10
|
||||
devel:libncurses$secondaryArchSuffix
|
||||
devel:libreadline$secondaryArchSuffix >= 6
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:autoreconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cd src
|
||||
libtoolize -fci
|
||||
autoreconf
|
||||
LDFLAGS="-L/system/lib -L/system/develop/lib" CFLAGS="-I/system/develop/include -I/system/include" ./configure $configureDirArgs
|
||||
#runConfigure ./configure
|
||||
make
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
cd src
|
||||
make install
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
cd src
|
||||
make check
|
||||
}
|
||||
100
dev-lang/swi_prolog/swi_prolog-9.0.4.recipe
Normal file
100
dev-lang/swi_prolog/swi_prolog-9.0.4.recipe
Normal file
@@ -0,0 +1,100 @@
|
||||
SUMMARY="SWI Prolog. Stable and free standard Prolog implementation"
|
||||
DESCRIPTION="SWI-Prolog is an open source implementation of the programming language Prolog, \
|
||||
commonly used for teaching and semantic web applications. It has a rich set of \
|
||||
features, libraries for constraint logic programming, multithreading, unit \
|
||||
testing, GUI, interfacing to Java, ODBC and others, literate programming, a web \
|
||||
server, SGML, RDF, RDFS, developer tools (including an IDE with a GUI debugger \
|
||||
and GUI profiler), and extensive documentation."
|
||||
HOMEPAGE="https://www.swi-prolog.org/"
|
||||
COPYRIGHT="1985-2018 VU University Amsterdam
|
||||
CWI Amsterdam"
|
||||
LICENSE="BSD (2-clause)"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://www.swi-prolog.org/download/stable/src/swipl-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="feb2815a51d34fa81cb34e8149830405935a7e1d1c1950461239750baa8b49f0"
|
||||
SOURCE_DIR="swipl-$portVersion"
|
||||
PATCHES="swi_prolog-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="?all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="?x86"
|
||||
|
||||
libVersion="9.0.4"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
swi_prolog$secondaryArchSuffix = $portVersion
|
||||
cmd:swipl$secondaryArchSuffix
|
||||
cmd:swipl_ld$secondaryArchSuffix
|
||||
cmd:swipl_rc$secondaryArchSuffix
|
||||
lib:libswipl$secondaryArchSuffix = libVersionCompat
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libatomic$secondaryArchSuffix
|
||||
lib:libgmp$secondaryArchSuffix
|
||||
lib:libncurses$secondaryArchSuffix
|
||||
# lib:libreadline$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
gcc_syslibs${secondaryArchSuffix}_devel
|
||||
# devel:libarchive$secondaryArchSuffix
|
||||
devel:libexecinfo$secondaryArchSuffix
|
||||
devel:libgmp$secondaryArchSuffix
|
||||
devel:libncurses$secondaryArchSuffix
|
||||
# devel:libodbc$secondaryArchSuffix
|
||||
# devel:libpcre2_8$secondaryArchSuffix
|
||||
# devel:libQt5Core$secondaryArchSuffix
|
||||
# devel:libQt5Widgets$secondaryArchSuffix
|
||||
# devel:libreadline$secondaryArchSuffix
|
||||
# devel:libssl$secondaryArchSuffix
|
||||
# devel:libuuid$secondaryArchSuffix >= 1.3
|
||||
# devel:libyaml$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
# cmd:python3
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cmake -Bbuild -S. -DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX=$prefix \
|
||||
-DSWIPL_INSTALL_IN_LIB=$libDir \
|
||||
-DSWIPL_INSTALL_IN_SHARE=$dataDir \
|
||||
-DSWIPL_INSTALL_MANPAGES=$manDir/man1 \
|
||||
-DSWIPL_INSTALL_PKGCONFIG=$libDir/pkgconfig \
|
||||
-DHAVE_LIBATOMIC=ON \
|
||||
-DBUILD_TESTING=OFF \
|
||||
-DSWIPL_PACKAGES=OFF \
|
||||
-DSWIPL_PACKAGES_ARCHIVE:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_BASIC:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_BDB:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_JAVA:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_ODBC:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_PCRE:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_QT:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_SSL:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_TERM:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_TIPC:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_X:BOOL=OFF \
|
||||
-DSWIPL_PACKAGES_YAML:BOOL=OFF
|
||||
|
||||
make -C build $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make -C build install
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
ctest --test-dir build
|
||||
}
|
||||
Reference in New Issue
Block a user