diff options
author | Dennis Camera <dennis.camera+gentoo@riiengineering.ch> | 2024-03-27 12:06:54 +0100 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2024-04-30 07:39:08 +0100 |
commit | ae4f92a526d6ceeb975ecb970d61e3ef2687f62e (patch) | |
tree | a94c9097564b5f7c4655a6b0f974306464960c4d /sys-libs/ldb | |
parent | sys-libs/tevent: fix redefinition of uintptr_t in bundled cmocka library (diff) | |
download | gentoo-ae4f92a526d6ceeb975ecb970d61e3ef2687f62e.tar.gz gentoo-ae4f92a526d6ceeb975ecb970d61e3ef2687f62e.tar.bz2 gentoo-ae4f92a526d6ceeb975ecb970d61e3ef2687f62e.zip |
sys-libs/ldb: fix redefinition of uintptr_t in bundled cmocka library
Build failed with musl libc:
In file included from ../../tests/test_tevent_tag.c:34:
../../third_party/cmocka/cmocka.h:127:28: error: conflicting types for 'uintptr_t'; have 'unsigned int'
127 | typedef unsigned int uintptr_t;
| ^~~~~~~~~
In file included from /usr/include/stdint.h:20,
from ../../tests/test_tevent_tag.c:29:
/usr/include/bits/alltypes.h:47:24: note: previous declaration of 'uintptr_t' with type 'uintptr_t' {aka 'long unsigned int'}
47 | typedef unsigned _Addr uintptr_t;
| ^~~~~~~~~
Signed-off-by: Dennis Camera <dennis.camera+gentoo@riiengineering.ch>
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-libs/ldb')
-rw-r--r-- | sys-libs/ldb/files/cmocka-config_h.patch | 23 | ||||
-rw-r--r-- | sys-libs/ldb/ldb-2.6.2.ebuild | 1 | ||||
-rw-r--r-- | sys-libs/ldb/ldb-2.7.2.ebuild | 1 | ||||
-rw-r--r-- | sys-libs/ldb/ldb-2.8.0.ebuild | 1 |
4 files changed, 26 insertions, 0 deletions
diff --git a/sys-libs/ldb/files/cmocka-config_h.patch b/sys-libs/ldb/files/cmocka-config_h.patch new file mode 100644 index 000000000000..124928450cd6 --- /dev/null +++ b/sys-libs/ldb/files/cmocka-config_h.patch @@ -0,0 +1,23 @@ +--- ./third_party/cmocka/cmocka.h.orig 2024-03-26 10:23:03.378410042 +0100 ++++ ./third_party/cmocka/cmocka.h 2024-03-26 10:24:51.526922405 +0100 +@@ -14,6 +14,11 @@ + * See the License for the specific language governing permissions and + * limitations under the License. + */ ++ ++#ifdef HAVE_CONFIG_H ++#include "config.h" ++#endif ++ + #ifndef CMOCKA_H_ + #define CMOCKA_H_ + +@@ -111,7 +114,7 @@ + ((LargestIntegralType)(value)) + + /* Smallest integral type capable of holding a pointer. */ +-#if !defined(_UINTPTR_T) && !defined(_UINTPTR_T_DEFINED) ++#if !defined(HAVE_UINTPTR_T) && !defined(_UINTPTR_T) && !defined(_UINTPTR_T_DEFINED) && !defined(__DEFINED_uintptr_t) + # if defined(_WIN32) + /* WIN32 is an ILP32 platform */ + typedef unsigned int uintptr_t; diff --git a/sys-libs/ldb/ldb-2.6.2.ebuild b/sys-libs/ldb/ldb-2.6.2.ebuild index 192c588a358d..dd88cd473194 100644 --- a/sys-libs/ldb/ldb-2.6.2.ebuild +++ b/sys-libs/ldb/ldb-2.6.2.ebuild @@ -60,6 +60,7 @@ PATCHES=( "${FILESDIR}"/${PN}-1.1.31-fix_PKGCONFIGDIR-when-python-disabled.patch "${FILESDIR}"/${PN}-2.4.2-skip-32bit-time_t-tests.patch "${FILESDIR}"/${PN}-2.5.2-skip-waf-tevent-check.patch + "${FILESDIR}"/cmocka-config_h.patch ) pkg_setup() { diff --git a/sys-libs/ldb/ldb-2.7.2.ebuild b/sys-libs/ldb/ldb-2.7.2.ebuild index 104e3ff13045..7efbfffe0bcc 100644 --- a/sys-libs/ldb/ldb-2.7.2.ebuild +++ b/sys-libs/ldb/ldb-2.7.2.ebuild @@ -60,6 +60,7 @@ PATCHES=( "${FILESDIR}"/${PN}-1.1.31-fix_PKGCONFIGDIR-when-python-disabled.patch "${FILESDIR}"/${PN}-2.4.2-skip-32bit-time_t-tests.patch "${FILESDIR}"/${PN}-2.5.2-skip-waf-tevent-check.patch + "${FILESDIR}"/cmocka-config_h.patch ) pkg_setup() { diff --git a/sys-libs/ldb/ldb-2.8.0.ebuild b/sys-libs/ldb/ldb-2.8.0.ebuild index 695c2e00e998..9a9ef754e6f3 100644 --- a/sys-libs/ldb/ldb-2.8.0.ebuild +++ b/sys-libs/ldb/ldb-2.8.0.ebuild @@ -60,6 +60,7 @@ PATCHES=( "${FILESDIR}"/${PN}-1.1.31-fix_PKGCONFIGDIR-when-python-disabled.patch "${FILESDIR}"/${PN}-2.4.2-skip-32bit-time_t-tests.patch "${FILESDIR}"/${PN}-2.5.2-skip-waf-tevent-check.patch + "${FILESDIR}"/cmocka-config_h.patch ) pkg_setup() { |