summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2021-01-08 11:06:19 +0100
committerFabian Groffen <grobian@gentoo.org>2021-01-08 11:07:59 +0100
commit08889d5fcd75867abec7c2dc201a1323fbb735be (patch)
treef62a2af932d57653bc2b6cc82bd3c5a05b5ad252 /dev-util/pkgconf
parentwww-client/chromium: stable channel bump to 87.0.4280.141 (diff)
downloadgentoo-08889d5fcd75867abec7c2dc201a1323fbb735be.tar.gz
gentoo-08889d5fcd75867abec7c2dc201a1323fbb735be.tar.bz2
gentoo-08889d5fcd75867abec7c2dc201a1323fbb735be.zip
dev-util/pkgconf-1.7.3-r1: add fix for ppc-macos
Package-Manager: Portage-3.0.12, Repoman-3.0.2 Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Diffstat (limited to 'dev-util/pkgconf')
-rw-r--r--dev-util/pkgconf/files/pkgconf-1.7.3-darwin9.patch24
-rw-r--r--dev-util/pkgconf/pkgconf-1.7.3-r1.ebuild2
2 files changed, 26 insertions, 0 deletions
diff --git a/dev-util/pkgconf/files/pkgconf-1.7.3-darwin9.patch b/dev-util/pkgconf/files/pkgconf-1.7.3-darwin9.patch
new file mode 100644
index 000000000000..f41de43b97c5
--- /dev/null
+++ b/dev-util/pkgconf/files/pkgconf-1.7.3-darwin9.patch
@@ -0,0 +1,24 @@
+darwin9 does not malloc on NULL resolved_path
+
+https://github.com/pkgconf/pkgconf/pull/208
+
+--- a/libpkgconf/path.c
++++ b/libpkgconf/path.c
+@@ -92,15 +92,11 @@
+ return;
+ if (S_ISLNK(st.st_mode))
+ {
+- char *linkdest = realpath(path, NULL);
++ char pathbuf[PATH_MAX];
++ char *linkdest = realpath(path, pathbuf);
+
+ if (linkdest != NULL && stat(linkdest, &st) == -1)
+- {
+- free(linkdest);
+ return;
+- }
+-
+- free(linkdest);
+ }
+ if (path_list_contains_entry(path, dirlist, &st))
+ return;
diff --git a/dev-util/pkgconf/pkgconf-1.7.3-r1.ebuild b/dev-util/pkgconf/pkgconf-1.7.3-r1.ebuild
index 257e865e259d..3923dd6417ea 100644
--- a/dev-util/pkgconf/pkgconf-1.7.3-r1.ebuild
+++ b/dev-util/pkgconf/pkgconf-1.7.3-r1.ebuild
@@ -40,6 +40,8 @@ MULTILIB_CHOST_TOOLS=(
src_prepare() {
default
+ [[ ${CHOST} == *-darwin9 ]] && eapply "${FILESDIR}"/${P}-darwin9.patch
+
[[ ${PV} == "9999" ]] && eautoreconf
if use pkg-config; then
MULTILIB_CHOST_TOOLS+=(