Mercurial > vim
comparison src/configure.in @ 2629:1ccc1ace9e5b v7.3.050
updated for version 7.3.050
Problem: The link script is clumsy.
Solution: Use the --as-needed linker option if available. (Kirill A.
Shutemov)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Wed, 03 Nov 2010 22:32:24 +0100 |
parents | 5c4b2fc4f067 |
children | b803b2776880 |
comparison
equal
deleted
inserted
replaced
2628:5c4b2fc4f067 | 2629:1ccc1ace9e5b |
---|---|
3525 AC_MSG_RESULT(no) | 3525 AC_MSG_RESULT(no) |
3526 fi | 3526 fi |
3527 fi | 3527 fi |
3528 AC_SUBST(DEPEND_CFLAGS_FILTER) | 3528 AC_SUBST(DEPEND_CFLAGS_FILTER) |
3529 | 3529 |
3530 dnl link.sh tries to avoid overlinking in a hackish way. | |
3531 dnl At least GNU ld supports --as-needed which provides the same functionality | |
3532 dnl at linker level. Let's use it. | |
3533 AC_MSG_CHECKING(linker --as-needed support) | |
3534 LINK_AS_NEEDED= | |
3535 # Check if linker supports --as-needed and --no-as-needed options | |
3536 if $CC -Wl,--help 2>/dev/null | grep as-needed > /dev/null; then | |
3537 LDFLAGS="$LDFLAGS -Wl,--as-needed" | |
3538 LINK_AS_NEEDED=yes | |
3539 fi | |
3540 if test "$LINK_AS_NEEDED" = yes; then | |
3541 AC_MSG_RESULT(yes) | |
3542 else | |
3543 AC_MSG_RESULT(no) | |
3544 fi | |
3545 AC_SUBST(LINK_AS_NEEDED) | |
3546 | |
3530 dnl write output files | 3547 dnl write output files |
3531 AC_OUTPUT(auto/config.mk:config.mk.in) | 3548 AC_OUTPUT(auto/config.mk:config.mk.in) |
3532 | 3549 |
3533 dnl vim: set sw=2 tw=78 fo+=l: | 3550 dnl vim: set sw=2 tw=78 fo+=l: |