summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorDan Nicolaescu <dann@ics.uci.edu>2010-09-21 01:35:37 +0300
committerDan Nicolaescu <dann@ics.uci.edu>2010-09-21 01:35:37 +0300
commitf5ea3ba7ccf9174cbb1c115cf185632cfe44f655 (patch)
tree8f1268550b6d437a785f7aea69ae0317a3bc0178 /configure.in
parent984edd2215e74d54d387c7e8fa2fd14ee43ff5f0 (diff)
downloademacs-f5ea3ba7ccf9174cbb1c115cf185632cfe44f655.tar.gz
Link temacs using $(CC) not $(LD).
* configure.in (LINKER): Rename to LD_FIRSTFLAG, do not include $(CC). * src/Makefile.in (temacs): Link using $(CC) not $(LD). (LD_FIRSTFLAG): Define using autoconf. (LD): Remove.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in21
1 files changed, 10 insertions, 11 deletions
diff --git a/configure.in b/configure.in
index b814b1a0236..47f3e0d7538 100644
--- a/configure.in
+++ b/configure.in
@@ -3373,7 +3373,7 @@ fi
AC_SUBST(LD_SWITCH_SYSTEM_TEMACS)
-LINKER=
+LD_FIRSTFLAG=
ORDINARY_LINK=
case "$opsys" in
## gnu: GNU needs its own crt0.
@@ -3383,14 +3383,14 @@ case "$opsys" in
## library search parth, i.e. it won't search /usr/lib for libc and
## friends. Using -nostartfiles instead avoids this problem, and
## will also work on earlier NetBSD releases.
- netbsd|openbsd) LINKER="\$(CC) -nostartfiles" ;;
+ netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
## MkLinux/LinuxPPC needs this.
## ibms390x only supports opsys = gnu-linux so it can be added here.
gnu-*)
case "$machine" in
- macppc|ibms390x) LINKER="\$(CC) -nostdlib" ;;
+ macppc|ibms390x) LD_FIRSTFLAG="-nostdlib" ;;
esac
;;
esac
@@ -3398,12 +3398,12 @@ esac
if test "x$ORDINARY_LINK" = "xyes"; then
- LINKER="\$(CC)"
+ LD_FIRSTFLAG=""
AC_DEFINE(ORDINARY_LINK, 1, [Define if the C compiler is the linker.])
-## The system files defining neither ORDINARY_LINK nor LINKER are:
+## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
## freebsd, gnu-* not on macppc|ibms390x.
-elif test "x$GCC" = "xyes" && test "x$LINKER" = "x"; then
+elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
## places that are difficult to figure out at make time. Fortunately,
@@ -3413,18 +3413,17 @@ elif test "x$GCC" = "xyes" && test "x$LINKER" = "x"; then
## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
## searching for libraries in its internal directories, so we have to
## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
- LINKER="\$(CC) -nostdlib"
+ LD_FIRSTFLAG="-nostdlib"
fi
-test "x$LINKER" = "x" && LINKER=ld
## FIXME? What setting of EDIT_LDFLAGS should this have?
-test "$NS_IMPL_GNUSTEP" = "yes" && LINKER="\$(CC) -rdynamic"
+test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
-AC_SUBST(LINKER)
+AC_SUBST(LD_FIRSTFLAG)
## FIXME? The logic here is not precisely the same as that above.
-## There is no check here for a pre-defined LINKER.
+## There is no check here for a pre-defined LD_FIRSTFLAG.
## Should we only be setting LIB_GCC if LD ~ -nostdlib?
LIB_GCC=
if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then