aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2024-12-13 05:22:47 +0800
committerH.J. Lu <hjl.tools@gmail.com>2024-12-14 20:15:52 +0800
commit65817569adf011b66d197c773df2d9337da5adb3 (patch)
tree6bb26f94c6c79855a6b249fe58bd23731bb9d888
parented377c952a673683507066506e4c88a7299a2447 (diff)
downloadglibc-65817569adf011b66d197c773df2d9337da5adb3.zip
glibc-65817569adf011b66d197c773df2d9337da5adb3.tar.gz
glibc-65817569adf011b66d197c773df2d9337da5adb3.tar.bz2
ifuncmain9.c: Return EXIT_UNSUPPORTED for GCC 5.4 or older
Since elf/ifuncmain9.c fails at run-time when compiled with GCC 5.4 or older (PR ipa/81128), return EXIT_UNSUPPORTED for GCC 5.4 or older. Signed-off-by: H.J. Lu <hjl.tools@gmail.com> Reviewed-by: Sam James <sam@gentoo.org>
-rw-r--r--elf/ifuncmain9.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/elf/ifuncmain9.c b/elf/ifuncmain9.c
index 4301145..654beea 100644
--- a/elf/ifuncmain9.c
+++ b/elf/ifuncmain9.c
@@ -20,9 +20,10 @@
#include <config.h>
-# include <stdbool.h>
-# include <stdio.h>
+#include <stdbool.h>
+#include <stdio.h>
+#if __GNUC_PREREQ (5, 5)
/* Do not use the test framework, so that the process setup is not
disturbed. */
@@ -90,3 +91,12 @@ main (void)
return errors;
}
+#else
+#include <support/test-driver.h>
+
+int
+main (void)
+{
+ return EXIT_UNSUPPORTED;
+}
+#endif