diff --git a/meta-oe/recipes-support/cabextract/cabextract/fix-fnmatch.patch b/meta-oe/recipes-support/cabextract/cabextract/fix-fnmatch.patch new file mode 100644 index 0000000000..bd486283b6 --- /dev/null +++ b/meta-oe/recipes-support/cabextract/cabextract/fix-fnmatch.patch @@ -0,0 +1,40 @@ +From - Mon Jun 11 00:00:00 2024 +From: Dmitry Baryshkov +Subject: [PATCH] Don't play with fnmatch.c replacement + +Currently fnmatch.c, even if it is selected, conditionally disables compilation +of fnmatch() funciton even though the rest of the code expects to get it (e.g. +because Autoconf didn't detect the working implementation and enabled fnmatch.c +to replace it). Drop the extra conditionals, to fix Autoconf magic. + +Observed error: + +ld: src/cabextract.o: in function `process_cabinet': +/usr/src/debug/cabextract/1.11/src/cabextract.c:499:(.text.startup+0xf1c): undefined reference to `rpl_fnmatch' +collect2: error: ld returned 1 exit status + +Upstream-Status: Submitted [https://github.com/kyz/libmspack/pull/51] +Signed-off-by: Dmitry Baryshkov + +Index: cabextract-1.11/fnmatch.c +=================================================================== +--- cabextract-1.11.orig/fnmatch.c ++++ cabextract-1.11/fnmatch.c +@@ -49,11 +49,6 @@ static const char rcsid[] = + it is simpler to just do this in the source for each such file. + */ + +-#if defined (_LIBC) || !defined (__GNU_LIBRARY__) +- +-#if !defined(__GNU_LIBRARY__) && !defined(STDC_HEADERS) +-#endif +- + /* Match STRING against the filename pattern PATTERN, returning zero if + it matches, nonzero if not. */ + int +@@ -216,5 +211,3 @@ int flags; + + return FNM_NOMATCH; + } +- +-#endif /* _LIBC or not __GNU_LIBRARY__. */ diff --git a/meta-oe/recipes-support/cabextract/cabextract_1.11.bb b/meta-oe/recipes-support/cabextract/cabextract_1.11.bb new file mode 100644 index 0000000000..0f06489ca9 --- /dev/null +++ b/meta-oe/recipes-support/cabextract/cabextract_1.11.bb @@ -0,0 +1,22 @@ +SUMMARY = "Software for extracting Microsoft cabinet files" +DESCRIPTION = "tool for extracting Microsoft cabinet files" +HOMEPAGE = "http://www.cabextract.org.uk/" +SECTION = "console/utils" + +LICENSE = "GPL-3.0-or-later" +LIC_FILES_CHKSUM = "file://src/cabextract.c;beginline=4;endline=11;md5=b0a10c6d3843f262114e7ecf91fc7e78" + +SRC_URI = "\ + https://www.cabextract.org.uk/cabextract-${PV}.tar.gz \ + file://fix-fnmatch.patch \ +" + +SRC_URI[sha256sum] = "b5546db1155e4c718ff3d4b278573604f30dd64c3c5bfd4657cd089b823a3ac6" + +DEPENDS = "libmspack" + +EXTRA_OECONF = "--with-external-libmspack" + +inherit autotools pkgconfig + +BBCLASSEXTEND += "native nativesdk" diff --git a/meta-oe/recipes-support/cabextract/libmspack_0.11alpha.bb b/meta-oe/recipes-support/cabextract/libmspack_0.11alpha.bb new file mode 100644 index 0000000000..169a5f271b --- /dev/null +++ b/meta-oe/recipes-support/cabextract/libmspack_0.11alpha.bb @@ -0,0 +1,16 @@ +SUMMARY = "A library for Microsoft compression formats" +DESCRIPTION = "The library provides compressors and decompressors,\ +archivers and dearchivers for Microsoft compression formats: CAB, CHM, WIM,\ +LIT, HLP, KWAJ and SZDD." +HOMEPAGE = "http://www.cabextract.org.uk/libmspack/" +SECTION = "lib" +LICENSE = "LGPL-2.1-only" + +LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=7fbc338309ac38fefcd64b04bb903e34" + +SRC_URI = "https://www.cabextract.org.uk/libmspack/libmspack-${PV}.tar.gz" +SRC_URI[sha256sum] = "70dd1fb2f0aecc36791b71a1e1840e62173079eadaa081192d1c323a0eeea21b" + +inherit autotools + +BBCLASSEXTEND += "native nativesdk"