p/f/prefix/standalone/kernel-2.6.32+/profile.bashrc: remove O_PATH
authorBenda Xu <heroxbd@gentoo.org>
Sat, 11 Apr 2020 15:30:07 +0000 (23:30 +0800)
committerBenda Xu <heroxbd@gentoo.org>
Sat, 11 Apr 2020 15:34:49 +0000 (23:34 +0800)
O_PATH is not available until Linux-2.6.39.

Reported-By: Harry Chen, Yiqun Hui
Suggested-by: Pengcheng Xu
Signed-off-by: Benda Xu <heroxbd@gentoo.org>
profiles/features/prefix/standalone/kernel-2.6.32+/profile.bashrc [new file with mode: 0644]

diff --git a/profiles/features/prefix/standalone/kernel-2.6.32+/profile.bashrc b/profiles/features/prefix/standalone/kernel-2.6.32+/profile.bashrc
new file mode 100644 (file)
index 0000000..eb05932
--- /dev/null
@@ -0,0 +1,10 @@
+# tricks to circumvent false positive checks of old kernel
+
+if [[ ${CATEGORY}/${PN} == sys-libs/glibc && ${EBUILD_PHASE} == configure ]]; then
+    einfo "Removing O_PATH definitions..."
+    sed -e '/define.*O_PATH/d' -i "${S}"/sysdeps/unix/sysv/linux/bits/fcntl-linux.h || die
+fi
+
+# Local Variables:
+# mode: shell-script
+# End: