llvm.org GIT mirror llvm / e2be5d5
Add the ability to pass the path to binutils source to configure. This is needed to build the LLVM gold plugin. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63621 91177308-0d34-0410-b5e6-96231b3b80d8 Nick Lewycky 10 years ago
2 changed file(s) with 21 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
282282 else
283283 SYSPATH = $(1)
284284 endif
285
286 # Location of the plugin header file for gold.
287 BINUTILS_INCDIR := @BINUTILS_INCDIR@
513513 *) AC_MSG_ERROR([Invalid path for --with-ocaml-libdir. Provide full path]) ;;
514514 esac
515515
516 dnl Allow linking of LLVM with GPLv3 binutils code.
517 AC_ARG_WITH(binutils-include,
518 AS_HELP_STRING([--with-binutils-include],
519 [Specify path to binutils/include/ containing plugin-api.h file for gold plugin.]),,
520 withval=default)
521 case "$withval" in
522 default) WITH_BINUTILS_INCDIR=default ;;
523 /* | [[A-Za-z]]:[[\\/]]*) WITH_BINUTILS_INCDIR=$withval ;;
524 *) AC_MSG_ERROR([Invalid path for --with-binutils-include. Provide full path]) ;;
525 esac
526 if test "x$WITH_BINUTILS_INCDIR" != xdefault ; then
527 AC_SUBST(BINUTILS_INCDIR,$WITH_BINUTILS_INCDIR)
528 if test ! -f "$WITH_BINUTILS_INCDIR/plugin-api.h"; then
529 echo "$WITH_BINUTILS_INCDIR/plugin-api.h"
530 AC_MSG_ERROR([Invalid path to directory containing plugin-api.h.]);
531 fi
532 fi
533
516534 dnl===-----------------------------------------------------------------------===
517535 dnl===
518536 dnl=== SECTION 4: Check for programs we need and that they are the right version