Commit 8009a5e8 authored by Glenn Morris's avatar Glenn Morris
Browse files

Move some stuff from LD_SWITCH_SYSTEM to LD_SWITCH_SYSTEM_TEMACS.

* configure.in (LD_SWITCH_SYSTEM): Move some gnu-linux stuff...
(LD_SWITCH_SYSTEM_TEMACS): ... to here.

* src/Makefile.in (LD_SWITCH_SYSTEM_TEMACS): Move definition after some
variables it may reference.
parent e5458003
2010-05-25 Glenn Morris <rgm@gnu.org>
* configure.in (LD_SWITCH_SYSTEM): Move some gnu-linux stuff...
(LD_SWITCH_SYSTEM_TEMACS): ... to here.
* configure.in (LD_SWITCH_SYSTEM_EXTRA): Remove.
(LD_SWITCH_SYSTEM_TEMACS): Put darwin stuff from LD_SWITCH_SYSTEM_EXTRA
here instead.
......
......@@ -955,16 +955,17 @@ AC_SUBST(LD_SWITCH_SYSTEM)
ac_link="$ac_link $LD_SWITCH_SYSTEM"
## This is fun. Some settings of LD_SWITCH_SYSTEM reference
## LD_SWITCH_X_SITE_AUX, which has not been defined yet. When using
## cpp, it was expanded to null. Thus LD_SWITCH_SYSTEM had different
## values in configure and the Makefiles. How helpful.
## FIXME why not use LD_SWITCH_SYSTEM_TEMACS (or somesuch) instead?
## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
## which has not been defined yet. When this was handled with cpp,
## it was expanded to null when configure sourced the s/*.h file.
## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
## (or somesuch), but because it is supposed to go at the _front_
## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
## Compare with the gnu-linux case below, which added to the end
## of LD_SWITCH_SYSTEM, and so can instead go at the front of
## LD_SWITCH_SYSTEM_TEMACS.
case "$opsys" in
gnu-linux)
## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
LD_SWITCH_SYSTEM="$LD_SWITCH_SYSTEM \$(LD_SWITCH_X_SITE_AUX)" ;;
netbsd|openbsd)
## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
......@@ -3300,6 +3301,14 @@ case "$opsys" in
LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
;;
## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
## had different values in configure (in ac_link) and src/Makefile.in.
## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
*) LD_SWITCH_SYSTEM_TEMACS= ;;
esac
AC_SUBST(LD_SWITCH_SYSTEM_TEMACS)
......@@ -3783,7 +3792,6 @@ for dir in etc lisp ; do
done
# Build src/Makefile from ${srcdir}/src/Makefile.c
# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
# This must be done after src/config.h is built, since we rely on that file.
echo creating src/epaths.h
......
2010-05-25 Glenn Morris <rgm@gnu.org>
* Makefile.in (LD_SWITCH_SYSTEM_TEMACS): Move definition after some
variables it may reference.
* Makefile.in (LD_SWITCH_SYSTEM_EXTRA): Remove.
(TEMACS_LDFLAGS): Remove LD_SWITCH_SYSTEM_EXTRA.
......
......@@ -96,12 +96,6 @@ C_SWITCH_X_SITE=@C_SWITCH_X_SITE@
## substituted in this or any other Makefile. Cf C_SWITCH_X_SITE.
LD_SWITCH_X_SITE=
## This holds any special options for linking temacs only (ie, not
## used by configure). Not used elsewhere because it sometimes
## contains options that have to do with using Emacs's crt0,
## which are only good with temacs.
LD_SWITCH_SYSTEM_TEMACS=@LD_SWITCH_SYSTEM_TEMACS@
## Next two must come before LD_SWITCH_SYSTEM.
## If needed, a -R option that says where to find X windows at run time.
LD_SWITCH_X_SITE_AUX=@LD_SWITCH_X_SITE_AUX@
......@@ -111,6 +105,12 @@ LD_SWITCH_X_SITE_AUX_RPATH=@LD_SWITCH_X_SITE_AUX_RPATH@
## System-specific LDFLAGS.
LD_SWITCH_SYSTEM=@LD_SWITCH_SYSTEM@
## This holds any special options for linking temacs only (ie, not
## used by configure). Not used elsewhere because it sometimes
## contains options that have to do with using Emacs's crt0,
## which are only good with temacs.
LD_SWITCH_SYSTEM_TEMACS=@LD_SWITCH_SYSTEM_TEMACS@
## Flags to pass to ld only for temacs.
TEMACS_LDFLAGS = $(LD_SWITCH_SYSTEM) $(LD_SWITCH_SYSTEM_TEMACS)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment