From 9111c760d9baea4e59db0066eb592bba127b5341 Mon Sep 17 00:00:00 2001 From: Wang Mingyu Date: Wed, 6 Mar 2024 16:43:10 +0800 Subject: libtalloc: upgrade 2.4.1 -> 2.4.2 0001-talloc-Add-configure-options-for-packages.patch refreshed for 2.4.2 Signed-off-by: Wang Mingyu Signed-off-by: Khem Raj --- ...talloc-Add-configure-options-for-packages.patch | 39 +++++++++++--- .../recipes-support/libtalloc/libtalloc_2.4.1.bb | 61 ---------------------- .../recipes-support/libtalloc/libtalloc_2.4.2.bb | 61 ++++++++++++++++++++++ 3 files changed, 93 insertions(+), 68 deletions(-) delete mode 100644 meta-networking/recipes-support/libtalloc/libtalloc_2.4.1.bb create mode 100644 meta-networking/recipes-support/libtalloc/libtalloc_2.4.2.bb diff --git a/meta-networking/recipes-support/libtalloc/libtalloc/0001-talloc-Add-configure-options-for-packages.patch b/meta-networking/recipes-support/libtalloc/libtalloc/0001-talloc-Add-configure-options-for-packages.patch index 45d847c852..6c92beb30b 100644 --- a/meta-networking/recipes-support/libtalloc/libtalloc/0001-talloc-Add-configure-options-for-packages.patch +++ b/meta-networking/recipes-support/libtalloc/libtalloc/0001-talloc-Add-configure-options-for-packages.patch @@ -24,13 +24,16 @@ Signed-off-by: Changqing Li Rebase to 2.4.1 Remove libaio option Signed-off-by: Yi Zhao + +Rebase to 2.4.2 +Signed-off-by: Wang Mingyu --- - lib/replace/wscript | 78 +++++++++++++++++++++++++++++++++------------ - wscript | 7 +++- - 2 files changed, 64 insertions(+), 21 deletions(-) + lib/replace/wscript | 100 ++++++++++++++++++++++++++++++-------------- + wscript | 7 +++- + 2 files changed, 75 insertions(+), 32 deletions(-) diff --git a/lib/replace/wscript b/lib/replace/wscript -index 199e636..3593eaf 100644 +index 77e655b..2fd7dfb 100644 --- a/lib/replace/wscript +++ b/lib/replace/wscript @@ -25,6 +25,34 @@ def options(opt): @@ -112,7 +115,7 @@ index 199e636..3593eaf 100644 conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h') conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h') conf.CHECK_HEADERS('utmp.h utmpx.h lastlog.h') -@@ -443,20 +481,20 @@ def configure(conf): +@@ -443,31 +481,31 @@ def configure(conf): strlcpy_in_bsd = False @@ -121,6 +124,17 @@ index 199e636..3593eaf 100644 - if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h', - checklibc=True): - strlcpy_in_bsd = True +- elif conf.env.enable_fuzzing: +- # Just to complicate it more, some versions of Honggfuzz have +- # got strlcpy and strlcat in libc, but not in +- # (unless it is there coincidentally, on a BSD). Therefore we +- # can't use CHECK_FUNCS alone to decide whether to add the +- # headers to replace.h. +- # +- # As this is only known to happen on a fuzzing compiler, we'll +- # skip the check when not in fuzzing mode. +- conf.CHECK_HEADERS('bsd/string.h') +- - if not conf.CHECK_FUNCS('getpeereid'): - conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h') - if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'): @@ -136,6 +150,17 @@ index 199e636..3593eaf 100644 + if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h', + checklibc=True): + strlcpy_in_bsd = True ++ elif conf.env.enable_fuzzing: ++ # Just to complicate it more, some versions of Honggfuzz have ++ # got strlcpy and strlcat in libc, but not in ++ # (unless it is there coincidentally, on a BSD). Therefore we ++ # can't use CHECK_FUNCS alone to decide whether to add the ++ # headers to replace.h. ++ # ++ # As this is only known to happen on a fuzzing compiler, we'll ++ # skip the check when not in fuzzing mode. ++ conf.CHECK_HEADERS('bsd/string.h') ++ + if not conf.CHECK_FUNCS('getpeereid'): + conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h') + if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'): @@ -148,7 +173,7 @@ index 199e636..3593eaf 100644 conf.CHECK_CODE(''' struct ucred cred; diff --git a/wscript b/wscript -index 075f1ec..6b4f273 100644 +index 8b5e02d..b6e2614 100644 --- a/wscript +++ b/wscript @@ -31,7 +31,12 @@ def options(opt): @@ -166,5 +191,5 @@ index 075f1ec..6b4f273 100644 def configure(conf): conf.RECURSE('lib/replace') -- -2.25.1 +2.34.1 diff --git a/meta-networking/recipes-support/libtalloc/libtalloc_2.4.1.bb b/meta-networking/recipes-support/libtalloc/libtalloc_2.4.1.bb deleted file mode 100644 index 92da03e1a1..0000000000 --- a/meta-networking/recipes-support/libtalloc/libtalloc_2.4.1.bb +++ /dev/null @@ -1,61 +0,0 @@ -SUMMARY = "Hierarchical, reference counted memory pool system with destructors" -HOMEPAGE = "https://talloc.samba.org" -SECTION = "libs" -LICENSE = "LGPL-3.0-or-later & GPL-3.0-or-later" -LIC_FILES_CHKSUM = "file://talloc.h;beginline=3;endline=27;md5=a301712782cad6dd6d5228bfa7825249 \ - file://pytalloc.h;beginline=1;endline=18;md5=21ab13bd853679d7d47a1739cb3b7db6 \ - " - -export PYTHONHASHSEED="1" -export PYTHONARCHDIR = "${PYTHON_SITEPACKAGES_DIR}" - -SRC_URI = "https://www.samba.org/ftp/talloc/talloc-${PV}.tar.gz \ - file://0001-talloc-Add-configure-options-for-packages.patch \ - file://0002-Fix-pyext_PATTERN-for-cross-compilation.patch \ - file://run-ptest \ -" -SRC_URI[sha256sum] = "410a547f08557007be0e88194f218868358edc0ab98c98ba8c167930db3d33f9" - -inherit waf-samba pkgconfig ptest - -PACKAGECONFIG ??= "\ - ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \ - ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \ -" -PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl" -PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr" -PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd" -PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap" -PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind" - -SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'attr', '', 'file://avoid-attr-unless-wanted.patch', d)}" - -S = "${WORKDIR}/talloc-${PV}" - -# Cross_compile cannot use preforked process, since fork process earlier than point subproces.popen -# to cross Popen -export WAF_NO_PREFORK="yes" - -EXTRA_OECONF += "--disable-rpath \ - --disable-rpath-install \ - --bundled-libraries=NONE \ - --builtin-libraries=replace \ - --disable-silent-rules \ - --with-libiconv=${STAGING_DIR_HOST}${prefix}\ - " - -do_install_ptest() { - install -d ${D}${PTEST_PATH}/tests - install -m 0755 ${B}/bin/*_testsuite ${D}${PTEST_PATH}/tests/ -} - -PACKAGES += "pytalloc pytalloc-dev" - -RPROVIDES:${PN}-dbg += "pytalloc-dbg" - -FILES:pytalloc = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \ - ${libdir}/libpytalloc-util.so.2 \ - ${libdir}/libpytalloc-util.so.2.1.1 \ - " -FILES:pytalloc-dev = "${libdir}/libpytalloc-util.so" -RDEPENDS:pytalloc = "python3" diff --git a/meta-networking/recipes-support/libtalloc/libtalloc_2.4.2.bb b/meta-networking/recipes-support/libtalloc/libtalloc_2.4.2.bb new file mode 100644 index 0000000000..394c176287 --- /dev/null +++ b/meta-networking/recipes-support/libtalloc/libtalloc_2.4.2.bb @@ -0,0 +1,61 @@ +SUMMARY = "Hierarchical, reference counted memory pool system with destructors" +HOMEPAGE = "https://talloc.samba.org" +SECTION = "libs" +LICENSE = "LGPL-3.0-or-later & GPL-3.0-or-later" +LIC_FILES_CHKSUM = "file://talloc.h;beginline=3;endline=27;md5=a301712782cad6dd6d5228bfa7825249 \ + file://pytalloc.h;beginline=1;endline=18;md5=21ab13bd853679d7d47a1739cb3b7db6 \ + " + +export PYTHONHASHSEED="1" +export PYTHONARCHDIR = "${PYTHON_SITEPACKAGES_DIR}" + +SRC_URI = "https://www.samba.org/ftp/talloc/talloc-${PV}.tar.gz \ + file://0001-talloc-Add-configure-options-for-packages.patch \ + file://0002-Fix-pyext_PATTERN-for-cross-compilation.patch \ + file://run-ptest \ +" +SRC_URI[sha256sum] = "85ecf9e465e20f98f9950a52e9a411e14320bc555fa257d87697b7e7a9b1d8a6" + +inherit waf-samba pkgconfig ptest + +PACKAGECONFIG ??= "\ + ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \ + ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \ +" +PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl" +PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr" +PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd" +PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap" +PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind" + +SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'attr', '', 'file://avoid-attr-unless-wanted.patch', d)}" + +S = "${WORKDIR}/talloc-${PV}" + +# Cross_compile cannot use preforked process, since fork process earlier than point subproces.popen +# to cross Popen +export WAF_NO_PREFORK="yes" + +EXTRA_OECONF += "--disable-rpath \ + --disable-rpath-install \ + --bundled-libraries=NONE \ + --builtin-libraries=replace \ + --disable-silent-rules \ + --with-libiconv=${STAGING_DIR_HOST}${prefix}\ + " + +do_install_ptest() { + install -d ${D}${PTEST_PATH}/tests + install -m 0755 ${B}/bin/*_testsuite ${D}${PTEST_PATH}/tests/ +} + +PACKAGES += "pytalloc pytalloc-dev" + +RPROVIDES:${PN}-dbg += "pytalloc-dbg" + +FILES:pytalloc = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \ + ${libdir}/libpytalloc-util.so.2 \ + ${libdir}/libpytalloc-util.so.2.1.1 \ + " +FILES:pytalloc-dev = "${libdir}/libpytalloc-util.so" +RDEPENDS:pytalloc = "python3" -- cgit 1.2.3-korg