]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commitdiff
m4: Do not munge locale in ptests for musl
authorKhem Raj <raj.khem@gmail.com>
Fri, 21 Apr 2023 08:00:26 +0000 (01:00 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 27 Apr 2023 13:41:26 +0000 (14:41 +0100)
locale setting are done with glibc in mind and they cause segfaults with
musl. Therefore make these tweaks specific to glibc

Signed-off-by: Khem Raj <raj.khem@gmail.com>
meta/recipes-devtools/m4/m4-1.4.19.inc

index 3b4303b7fd817241150a07c7376a119293d0ba53..fcc9e582701ef235e88d4c4bbd2c3fd84974ed50 100644 (file)
@@ -40,8 +40,6 @@ do_install_ptest() {
                 cp -r ${B}/tests                        ${D}${PTEST_PATH}
                 cp -r ${S}/tests/*                      ${D}${PTEST_PATH}/tests/
                 sed -i '/^Makefile:/c Makefile:'        ${D}${PTEST_PATH}/tests/Makefile
-                sed -i -e  "s;LOCALE_FR='fr_FR';LOCALE_FR='fr_FR.iso88591';g" \
-                       -e  "s;LOCALE_FR_UTF8='none';LOCALE_FR_UTF8='fr_FR.utf8';g" ${D}${PTEST_PATH}/tests/Makefile
                 find ${D}${PTEST_PATH} -type f -name *.[hoc] | xargs -i rm {}
                 cp ${S}/build-aux/update-copyright  ${D}${PTEST_PATH}/tests/
                 sed -i 's;update-copyright;./update-copyright;g' ${D}${PTEST_PATH}/tests/test-update-copyright.sh
@@ -52,6 +50,10 @@ do_install_ptest() {
                 ln -s ptest ${D}${libdir}/${BPN}/${BP} 
 }
 
+do_install_ptest:append:libc-glibc() {
+                sed -i -e  "s;LOCALE_FR='fr_FR';LOCALE_FR='fr_FR.iso88591';g" \
+                       -e  "s;LOCALE_FR_UTF8='none';LOCALE_FR_UTF8='fr_FR.utf8';g" ${D}${PTEST_PATH}/tests/Makefile
+}
 
 RDEPENDS:${PN}-ptest += "make coreutils diffutils bash"
 RDEPENDS:${PN}-ptest:append:libc-glibc = "\