mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 12:10:06 +02:00
apr: decide to use standard POSIX methods on Haiku
otherwise BeOS ones are found and used, although unix platform is used
This commit is contained in:
@@ -24,7 +24,7 @@ following:
|
||||
HOMEPAGE="http://apr.apache.org/"
|
||||
COPYRIGHT="2012 The Apache Software Foundation"
|
||||
LICENSE="Apache v2"
|
||||
REVISION="1"
|
||||
REVISION="2"
|
||||
SOURCE_URI="http://archive.apache.org/dist/apr/apr-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="48e9dbf45ae3fdc7b491259ffb6ccf7d63049ffacbc1c0977cced095e4c2d5a2"
|
||||
PATCHES="apr-$portVersion.patchset"
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
From 6face34a456517470d0d06ec1870dfd66b7342d2 Mon Sep 17 00:00:00 2001
|
||||
From 2d2c651eab75b90d38fca36d84a7047d99feea59 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 15 Jul 2017 13:50:02 +0200
|
||||
Subject: apply 1.5.2 patch.
|
||||
|
||||
|
||||
diff --git a/config.layout b/config.layout
|
||||
index 0f42e84..2e29914 100644
|
||||
index fb087a8..a599e0d 100644
|
||||
--- a/config.layout
|
||||
+++ b/config.layout
|
||||
@@ -60,6 +60,23 @@
|
||||
@@ -33,7 +33,7 @@ index 0f42e84..2e29914 100644
|
||||
<Layout Mac OS X Server>
|
||||
prefix: /Local/Library/WebServer
|
||||
diff --git a/configure.in b/configure.in
|
||||
index 927e1e6..606ed16 100644
|
||||
index 6833b32..b6514a3 100644
|
||||
--- a/configure.in
|
||||
+++ b/configure.in
|
||||
@@ -203,7 +203,7 @@ AC_PROG_MAKE_SET
|
||||
@@ -45,7 +45,7 @@ index 927e1e6..606ed16 100644
|
||||
AC_PROG_INSTALL
|
||||
AC_CHECK_PROG(RM, rm, rm)
|
||||
AC_CHECK_PROG(AS, as, as)
|
||||
@@ -718,9 +718,9 @@ case $host in
|
||||
@@ -726,9 +726,9 @@ case $host in
|
||||
ac_cv_func_CreateFileMapping=yes
|
||||
;;
|
||||
*)
|
||||
@@ -57,5 +57,116 @@ index 927e1e6..606ed16 100644
|
||||
AC_CHECK_LIB(truerand, main)
|
||||
AC_SEARCH_LIBS(modf, m)
|
||||
--
|
||||
2.12.2
|
||||
2.30.2
|
||||
|
||||
|
||||
From 0b45801519ddd64fbb25ef8d488e0337fc09c57d Mon Sep 17 00:00:00 2001
|
||||
From: Sergei Trofimovich <slyfox@gentoo.org>
|
||||
Date: Wed, 25 Nov 2020 09:36:25 +0000
|
||||
Subject: build/apr_common.m4: avoid explicit inclusion of '"confdefs.h"'
|
||||
|
||||
The failure is observed on `autoconf-2.69d` (soon to be released
|
||||
as `autoconf-2.70`). There `int64_t` detection fails as:
|
||||
|
||||
```
|
||||
$ autoreconf && ./configure
|
||||
...
|
||||
checking whether int64_t and int use fmt %d... no
|
||||
checking whether int64_t and long use fmt %ld... no
|
||||
checking whether int64_t and long long use fmt %lld... no
|
||||
configure: error: could not determine the string function for int64_t
|
||||
```
|
||||
|
||||
This happens because `./configure` always stumbles on warning:
|
||||
|
||||
```
|
||||
configure:3350: gcc -c -g -O2 -Werror conftest.c >&5
|
||||
In file included from conftest.c:31:
|
||||
confdefs.h:22: error: "__STDC_WANT_IEC_60559_ATTRIBS_EXT__" redefined [-Werror]
|
||||
22 | #define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1
|
||||
|
|
||||
```
|
||||
|
||||
It's triggered by double inclusion of `"confdefs.h"` contents:
|
||||
explicitly in `APR_TRY_COMPILE_NO_WARNING` macro and implicitly
|
||||
via `AC_LANG_SOURCE` use.
|
||||
|
||||
To fix it and avoid having to define `main()` declaration the change
|
||||
uses `AC_LANG_PROGRAM` instead.
|
||||
|
||||
Tested on both `autoconf-2.69` and `autoconf-2.69d`.
|
||||
|
||||
Bug: https://bugs.gentoo.org/738156
|
||||
Bug: https://bugs.gentoo.org/750353
|
||||
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
|
||||
|
||||
diff --git a/build/apr_common.m4 b/build/apr_common.m4
|
||||
index f4e2dfd..6f5782e 100644
|
||||
--- a/build/apr_common.m4
|
||||
+++ b/build/apr_common.m4
|
||||
@@ -504,13 +504,9 @@ AC_DEFUN([APR_TRY_COMPILE_NO_WARNING],
|
||||
CFLAGS="$CFLAGS -Werror"
|
||||
fi
|
||||
AC_COMPILE_IFELSE(
|
||||
- [AC_LANG_SOURCE(
|
||||
- [#include "confdefs.h"
|
||||
- ]
|
||||
- [[$1]]
|
||||
- [int main(int argc, const char *const *argv) {]
|
||||
+ [AC_LANG_PROGRAM(
|
||||
+ [[$1]],
|
||||
[[$2]]
|
||||
- [ return 0; }]
|
||||
)], [CFLAGS=$apr_save_CFLAGS
|
||||
$3], [CFLAGS=$apr_save_CFLAGS
|
||||
$4])
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From ded89174cb19bf46ba9cfc273482b4a3c6350dd0 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Mon, 25 Apr 2022 21:18:48 +0200
|
||||
Subject: Haiku: decide to use standard POSIX methods
|
||||
|
||||
BeOS methods aren't supported in unix platform code.
|
||||
|
||||
diff --git a/configure.in b/configure.in
|
||||
index b6514a3..eb1864c 100644
|
||||
--- a/configure.in
|
||||
+++ b/configure.in
|
||||
@@ -1249,6 +1249,9 @@ case $host in
|
||||
APR_DECISION_OVERRIDE(USE_SHMEM_MMAP_ZERO USE_SHMEM_SHMGET_ANON)
|
||||
fi
|
||||
;;
|
||||
+ *haiku* )
|
||||
+ APR_DECISION_OVERRIDE(USE_SHMEM_MMAP_ANON)
|
||||
+ ;;
|
||||
*hpux11* )
|
||||
APR_DECISION_OVERRIDE(USE_SHMEM_SHMGET_ANON)
|
||||
;;
|
||||
@@ -1325,6 +1328,9 @@ case $host in
|
||||
USE_SHMEM_SHMGET)
|
||||
fi
|
||||
;;
|
||||
+ *haiku* )
|
||||
+ APR_DECISION_OVERRIDE(USE_SHMEM_MMAP_TMP)
|
||||
+ ;;
|
||||
esac
|
||||
APR_END_DECISION
|
||||
AC_DEFINE_UNQUOTED($ac_decision)
|
||||
@@ -2381,6 +2387,11 @@ esac
|
||||
if test "x$apr_lock_method" != "x"; then
|
||||
APR_DECISION_FORCE($apr_lock_method)
|
||||
fi
|
||||
+case $host in
|
||||
+ *haiku* )
|
||||
+ APR_DECISION_OVERRIDE(USE_SYSVSEM_SERIALIZE)
|
||||
+ ;;
|
||||
+esac
|
||||
APR_END_DECISION
|
||||
AC_DEFINE_UNQUOTED($ac_decision)
|
||||
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
Reference in New Issue
Block a user