My personal project and infrastructure archive
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nomicon/pkgs/development/compilers/gcc/6/fix-objdump-check.patch

43 lines
1.5 KiB

commit 4c38abe0967bad78dd6baa61c86923e4d4b346d3
Author: Ben Gamari <ben@smart-cactus.org>
Date: Sun Nov 5 13:14:19 2017 -0500
Fix it
diff --git a/config/gcc-plugin.m4 b/config/gcc-plugin.m4
index dd06a58..f4435b8 100644
--- a/config/gcc-plugin.m4
+++ b/config/gcc-plugin.m4
@@ -13,6 +13,32 @@ dnl the same distribution terms as the rest of that program.
# Sets the shell variables enable_plugin and pluginlibs.
AC_DEFUN([GCC_ENABLE_PLUGINS],
[# Check for plugin support
+
+ # Figure out what objdump we will be using.
+ AS_VAR_SET_IF(gcc_cv_objdump,, [
+ if test -f $gcc_cv_binutils_srcdir/configure.ac \
+ && test -f ../binutils/Makefile \
+ && test x$build = x$host; then
+ # Single tree build which includes binutils.
+ gcc_cv_objdump=../binutils/objdump$build_exeext
+ elif test -x objdump$build_exeext; then
+ gcc_cv_objdump=./objdump$build_exeext
+ elif ( set dummy $OBJDUMP_FOR_TARGET; test -x $[2] ); then
+ gcc_cv_objdump="$OBJDUMP_FOR_TARGET"
+ else
+ AC_PATH_PROG(gcc_cv_objdump, $OBJDUMP_FOR_TARGET)
+ fi])
+
+ AC_MSG_CHECKING(what objdump to use)
+ if test "$gcc_cv_objdump" = ../binutils/objdump$build_exeext; then
+ # Single tree build which includes binutils.
+ AC_MSG_RESULT(newly built objdump)
+ elif test x$gcc_cv_objdump = x; then
+ AC_MSG_RESULT(not found)
+ else
+ AC_MSG_RESULT($gcc_cv_objdump)
+ fi
+
AC_ARG_ENABLE(plugin,
[AS_HELP_STRING([--enable-plugin], [enable plugin support])],
enable_plugin=$enableval,