diff options
3 files changed, 24 insertions, 58 deletions
diff --git a/meta-networking/recipes-support/libtevent/libtevent/cmocka-fix-musl-libc-conflicting-types-error.patch b/meta-networking/recipes-support/libtevent/libtevent/cmocka-fix-musl-libc-conflicting-types-error.patch deleted file mode 100644 index 5795ff3bd1..0000000000 --- a/meta-networking/recipes-support/libtevent/libtevent/cmocka-fix-musl-libc-conflicting-types-error.patch +++ /dev/null | |||
| @@ -1,45 +0,0 @@ | |||
| 1 | From 1d4dedab5039bb671f44566d8573ee3532ba7176 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Changqing Li <changqing.li@windriver.com> | ||
| 3 | Date: Wed, 25 Jul 2018 09:55:25 +0800 | ||
| 4 | Subject: [PATCH] cmocka: fix musl libc conflicting types error | ||
| 5 | |||
| 6 | /third_party/cmocka/cmocka.h:126:28: error: conflicting types for 'uintptr_t' | ||
| 7 | typedef unsigned int uintptr_t; | ||
| 8 | ^~~~~~~~~ | ||
| 9 | use __DEFINED_uintptr_t in alltypes.h to check if uintptr already defined | ||
| 10 | |||
| 11 | Upstream-Status: Pending | ||
| 12 | |||
| 13 | Signed-off-by: Changqing Li <changqing.li@windriver.com> | ||
| 14 | --- | ||
| 15 | third_party/cmocka/cmocka.h | 7 +++---- | ||
| 16 | 1 file changed, 3 insertions(+), 4 deletions(-) | ||
| 17 | |||
| 18 | diff --git a/third_party/cmocka/cmocka.h b/third_party/cmocka/cmocka.h | ||
| 19 | index e6861c8..238201d 100644 | ||
| 20 | --- a/third_party/cmocka/cmocka.h | ||
| 21 | +++ b/third_party/cmocka/cmocka.h | ||
| 22 | @@ -111,7 +111,7 @@ typedef uintmax_t LargestIntegralType; | ||
| 23 | ((LargestIntegralType)(value)) | ||
| 24 | |||
| 25 | /* Smallest integral type capable of holding a pointer. */ | ||
| 26 | -#if !defined(_UINTPTR_T) && !defined(_UINTPTR_T_DEFINED) | ||
| 27 | +#if !defined(__DEFINED_uintptr_t) | ||
| 28 | # if defined(_WIN32) | ||
| 29 | /* WIN32 is an ILP32 platform */ | ||
| 30 | typedef unsigned int uintptr_t; | ||
| 31 | @@ -135,9 +135,8 @@ typedef uintmax_t LargestIntegralType; | ||
| 32 | # endif /* __WORDSIZE */ | ||
| 33 | # endif /* _WIN32 */ | ||
| 34 | |||
| 35 | -# define _UINTPTR_T | ||
| 36 | -# define _UINTPTR_T_DEFINED | ||
| 37 | -#endif /* !defined(_UINTPTR_T) || !defined(_UINTPTR_T_DEFINED) */ | ||
| 38 | +# define __DEFINED_uintptr_t | ||
| 39 | +#endif /* !defined(__DEFINED_uintptr_t) */ | ||
| 40 | |||
| 41 | /* Perform an unsigned cast to uintptr_t. */ | ||
| 42 | #define cast_to_pointer_integral_type(value) \ | ||
| 43 | -- | ||
| 44 | 2.25.1 | ||
| 45 | |||
diff --git a/meta-networking/recipes-support/libtevent/libtevent/run-ptest b/meta-networking/recipes-support/libtevent/libtevent/run-ptest new file mode 100644 index 0000000000..19f7a4a3a6 --- /dev/null +++ b/meta-networking/recipes-support/libtevent/libtevent/run-ptest | |||
| @@ -0,0 +1,17 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | |||
| 3 | ptestdir=$(dirname "$(readlink -f "$0")") | ||
| 4 | cd "$ptestdir"/tests || exit | ||
| 5 | |||
| 6 | tests="replace_testsuite test_tevent_tag test_tevent_trace" | ||
| 7 | |||
| 8 | for f in $tests | ||
| 9 | do | ||
| 10 | if test -x ./"$f"; then | ||
| 11 | if ./"$f" > ./"$f".out 2> ./"$f".err; then | ||
| 12 | echo "PASS: $f" | ||
| 13 | else | ||
| 14 | echo "FAIL: $f" | ||
| 15 | fi | ||
| 16 | fi | ||
| 17 | done | ||
diff --git a/meta-networking/recipes-support/libtevent/libtevent_0.14.1.bb b/meta-networking/recipes-support/libtevent/libtevent_0.14.1.bb index b34c186ca5..9a2b5ede27 100644 --- a/meta-networking/recipes-support/libtevent/libtevent_0.14.1.bb +++ b/meta-networking/recipes-support/libtevent/libtevent_0.14.1.bb | |||
| @@ -3,7 +3,7 @@ HOMEPAGE = "https://tevent.samba.org" | |||
| 3 | SECTION = "libs" | 3 | SECTION = "libs" |
| 4 | LICENSE = "LGPL-3.0-or-later" | 4 | LICENSE = "LGPL-3.0-or-later" |
| 5 | 5 | ||
| 6 | DEPENDS += "libtalloc libtirpc" | 6 | DEPENDS += "libtalloc libtirpc cmocka" |
| 7 | RDEPENDS:python3-tevent = "python3" | 7 | RDEPENDS:python3-tevent = "python3" |
| 8 | 8 | ||
| 9 | export PYTHONHASHSEED="1" | 9 | export PYTHONHASHSEED="1" |
| @@ -11,10 +11,9 @@ export PYTHONHASHSEED="1" | |||
| 11 | SRC_URI = "https://samba.org/ftp/tevent/tevent-${PV}.tar.gz \ | 11 | SRC_URI = "https://samba.org/ftp/tevent/tevent-${PV}.tar.gz \ |
| 12 | file://0001-Add-configure-options-for-packages.patch \ | 12 | file://0001-Add-configure-options-for-packages.patch \ |
| 13 | file://0002-Fix-pyext_PATTERN-for-cross-compilation.patch \ | 13 | file://0002-Fix-pyext_PATTERN-for-cross-compilation.patch \ |
| 14 | file://run-ptest \ | ||
| 14 | " | 15 | " |
| 15 | 16 | ||
| 16 | SRC_URI:append:libc-musl = " file://cmocka-fix-musl-libc-conflicting-types-error.patch" | ||
| 17 | |||
| 18 | LIC_FILES_CHKSUM = "file://tevent.h;endline=26;md5=47386b7c539bf2706b7ce52dc9341681" | 17 | LIC_FILES_CHKSUM = "file://tevent.h;endline=26;md5=47386b7c539bf2706b7ce52dc9341681" |
| 19 | 18 | ||
| 20 | SRC_URI[sha256sum] = "ef85fcaa80ffd2351036ba4b347630fef2a1ac3da964a7f1820466bad03cd00d" | 19 | SRC_URI[sha256sum] = "ef85fcaa80ffd2351036ba4b347630fef2a1ac3da964a7f1820466bad03cd00d" |
| @@ -42,27 +41,22 @@ export WAF_NO_PREFORK="yes" | |||
| 42 | 41 | ||
| 43 | EXTRA_OECONF += "--disable-rpath \ | 42 | EXTRA_OECONF += "--disable-rpath \ |
| 44 | --disable-rpath-install \ | 43 | --disable-rpath-install \ |
| 45 | --bundled-libraries=cmocka \ | 44 | --bundled-libraries=NONE \ |
| 46 | --builtin-libraries=replace \ | 45 | --builtin-libraries=replace \ |
| 47 | --with-libiconv=${STAGING_DIR_HOST}${prefix}\ | 46 | --with-libiconv=${STAGING_DIR_HOST}${prefix}\ |
| 48 | --without-gettext \ | 47 | --without-gettext \ |
| 49 | " | 48 | " |
| 50 | 49 | ||
| 51 | do_install:append() { | 50 | do_install_ptest() { |
| 52 | install -Dm 0755 ${B}/bin/test_tevent_trace ${D}${bindir}/test_tevent_trace | 51 | install -d ${D}${PTEST_PATH}/tests |
| 53 | install -Dm 0755 ${B}/bin/test_tevent_tag ${D}${bindir}/test_tevent_tag | 52 | install -m 0755 ${B}/bin/test_tevent_* ${D}${PTEST_PATH}/tests/ |
| 54 | install -Dm 0755 ${B}/bin/replace_testsuite ${D}${bindir}/replace_testsuite | 53 | install -m 0755 ${B}/bin/replace_testsuite ${D}${PTEST_PATH}/tests/ |
| 55 | } | 54 | } |
| 56 | 55 | ||
| 57 | PACKAGES += "python3-tevent" | 56 | PACKAGES += "python3-tevent" |
| 58 | 57 | ||
| 59 | RPROVIDES:${PN}-dbg += "python3-tevent-dbg" | 58 | RPROVIDES:${PN}-dbg += "python3-tevent-dbg" |
| 60 | 59 | ||
| 61 | FILES:${PN} += "${libdir}/tevent/*" | ||
| 62 | FILES:${PN}-ptest += "${bindir}/replace_testsuite \ | ||
| 63 | ${bindir}/test_tevent_tag \ | ||
| 64 | ${bindir}/test_tevent_trace \ | ||
| 65 | ${libdir}/libcmocka-tevent.so" | ||
| 66 | FILES:python3-tevent = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*" | 60 | FILES:python3-tevent = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*" |
| 67 | 61 | ||
| 68 | INSANE_SKIP:${MLPREFIX}python3-tevent = "dev-so" | 62 | INSANE_SKIP:${MLPREFIX}python3-tevent = "dev-so" |
