Skip to content

Commit

Permalink
build/configure: Add support for --with-extra-ld-options flag (to pro…
Browse files Browse the repository at this point in the history
…vide extra

options just to pass to ld).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133206 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
ddunbar committed Jun 16, 2011
1 parent dc9c76a commit e2a91a7
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Makefile.config.in
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,9 @@ TARGET_TRIPLE=@target@
# Extra options to compile LLVM with
EXTRA_OPTIONS=@EXTRA_OPTIONS@

# Extra options to link LLVM with
EXTRA_LD_OPTIONS=@EXTRA_LD_OPTIONS@

# Endian-ness of the target
ENDIAN=@ENDIAN@

Expand Down
4 changes: 4 additions & 0 deletions Makefile.rules
Original file line number Diff line number Diff line change
Expand Up @@ -582,6 +582,10 @@ endif
# Options To Invoke Tools
#----------------------------------------------------------

ifdef EXTRA_LD_OPTIONS
LD.Flags += $(EXTRA_LD_OPTIONS)
endif

ifndef NO_PEDANTIC
CompileCommonOpts += -pedantic -Wno-long-long
endif
Expand Down
11 changes: 11 additions & 0 deletions autoconf/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -831,6 +831,17 @@ case "$withval" in
esac
AC_SUBST(EXTRA_OPTIONS,$EXTRA_OPTIONS)

dnl Specify extra linker build options
AC_ARG_WITH(extra-ld-options,
AS_HELP_STRING([--with-extra-ld-options],
[Specify additional options to link LLVM with]),,
withval=default)
case "$withval" in
default) EXTRA_LD_OPTIONS= ;;
*) EXTRA_LD_OPTIONS=$withval ;;
esac
AC_SUBST(EXTRA_LD_OPTIONS,$EXTRA_LD_OPTIONS)

dnl Allow specific bindings to be specified for building (or not)
AC_ARG_ENABLE([bindings],AS_HELP_STRING([--enable-bindings],
[Build specific language bindings: all,auto,none,{binding-name} (default=auto)]),,
Expand Down

0 comments on commit e2a91a7

Please sign in to comment.