Commit 04384b2d authored by Glenn Morris's avatar Glenn Morris

Build simplifications for oldxmenu.

* configure.in (OLDXMENU): Set to "nothing" if !HAVE_X11 || USE_GTK.
(OLDXMENU_TARGET): Set to empty if USE_GTK.

* src/Makefile.in (../src/$(OLDXMENU), $(OLDXMENU)): Always define rules.

* msdos/sed1x.inp (OLDXMENU): Replace any initial value.
* msdos/sed1v2.inp (OLDXMENU): Edit to "nothing".
parent 7e222e4e
2010-05-21 Glenn Morris <rgm@gnu.org>
* configure.in (OLDXMENU): Set to "nothing" if !HAVE_X11 || USE_GTK.
(OLDXMENU_TARGET): Set to empty if USE_GTK.
* configure.in (cannot_dump): New output variable.
2010-05-20 enami tsugutomo <tsugutomo.enami@jp.sony.com>
......
......@@ -3181,7 +3181,6 @@ else
OLDXMENU_TARGET="really-lwlib"
fi
AC_SUBST(LIBXT_OTHER)
AC_SUBST(OLDXMENU_TARGET)
## The X Menu stuff is present in the X10 distribution, but missing
## from X11. If we have X10, just use the installed library;
......@@ -3200,7 +3199,9 @@ if test "${HAVE_X11}" = "yes" ; then
LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
else
OLDXMENU=
## For a syntactically valid Makefile; not actually used for anything.
## See comments in src/Makefile.in.
OLDXMENU=nothing
## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
if test "${HAVE_X_WINDOWS}" = "yes"; then
LIBXMENU="-lXMenu"
......@@ -3212,11 +3213,13 @@ else
fi
if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
OLDXMENU=
OLDXMENU_TARGET=
OLDXMENU=nothing
LIBXMENU=
OLDXMENU_DEPS=
fi
AC_SUBST(OLDXMENU_TARGET)
AC_SUBST(OLDXMENU)
AC_SUBST(LIBXMENU)
AC_SUBST(LIBX_OTHER)
......
2010-05-21 Glenn Morris <rgm@gnu.org>
* sed1x.inp (OLDXMENU): Replace any initial value.
* sed1v2.inp (OLDXMENU): Edit to "nothing".
* sed1v2.inp (CANNOT_DUMP): Edit to no.
2010-05-20 Glenn Morris <rgm@gnu.org>
......
......@@ -114,7 +114,7 @@ s/\.h\.in/.h-in/
/^WINDOW_SUPPORT *=/s/@WINDOW_SUPPORT@//
/^LIBGPM *=/s/@LIBGPM@//
/^EXEEXT *=/s/@EXEEXT@/.exe/
/^OLDXMENU *=/s/@OLDXMENU@//
/^OLDXMENU *=/s/@OLDXMENU@/nothing/
/^LIBXMENU *=/s/@LIBXMENU@//
/^LIBX_OTHER *=/s/@LIBX_OTHER@//
/^GMALLOC_OBJ *=/s/@GMALLOC_OBJ@/gmalloc.o/
......
......@@ -19,7 +19,7 @@
s!^ cd \${oldXMenudir}; \${MAKE}.*$! ${MAKE} -C ${oldXMenudir}.!
s!^ @true *$! @rem!
s/DOC/DOC-X/g
/^OLDXMENU *=/s!= *!= ${oldXMenudir}libXMenu11.a!
/^OLDXMENU *=/s!=.*!= ${oldXMenudir}libXMenu11.a!
/^LIBXMENU *=/s!= *!= ${OLDXMENU}!
/^LIBX_OTHER *=/s!= *!= ${LIBXT} ${LIBX_EXTRA}!
/^OLDXMENU_TARGET *=/s!= *!= really-oldxmenu!
......
2010-05-21 Glenn Morris <rgm@gnu.org>
* Makefile.in (../src/$(OLDXMENU), $(OLDXMENU)): Always define rules.
* Makefile.in (CANNOT_DUMP): New, set by configure.
(emacs${EXEEXT}, bootstrap-emacs${EXEEXT}): Use $CANNOT_DUMP.
......
......@@ -173,13 +173,20 @@ LIBXTR6=@LIBXTR6@
## Only used if HAVE_X_WINDOWS.
LIBXT_OTHER=@LIBXT_OTHER@
## Only used if HAVE_X11 && !USE_GTK.
## really-lwlib if USE_X_TOOLKIT, else really-oldxmenu.
## If !HAVE_X11 || USE_GTK, empty.
## Else if USE_X_TOOLKIT really-lwlib, else really-oldxmenu.
OLDXMENU_TARGET=@OLDXMENU_TARGET@
## If !HAVE_X11 || USE_GTK, empty.
## Else if USE_X_TOOLKIT, ${lwlibdir}liblw.a.
## Else ${oldXMenudir}libXMenu11.a.
## (Actually, rather than being empty, it is set to "nothing".
## It is never actually used for anything in this case.
## This is done because there is a rule with target $(OLDXMENU) below,
## and I think it might be a syntax error with some makes to have
## an empty target, even if the associated rule is never run.
## http://lists.gnu.org/archive/html/help-make/2010-05/msg00058.html
## The alternative would be to put that rule in a makefile fragment.)
OLDXMENU=@OLDXMENU@
## If HAVE_X11 && !USE_GTK, ${OLDXMENU} ../src/${OLDXMENU}; else empty.
......@@ -290,6 +297,7 @@ DEPDIR=deps
## -MMD -MF ${DEPDIR}/$*.d if AUTO_DEPEND; else empty.
DEPFLAGS=@DEPFLAGS@
## test -d ${DEPDIR} || mkdir ${DEPDIR} (if AUTO_DEPEND); else ':'.
## FIXME This can fail in parallel builds. Use mkinstalldirs instead?
MKDEPDIR=@MKDEPDIR@
# ========================== start of cpp stuff =======================
......@@ -651,8 +659,9 @@ prefix-args${EXEEXT}: prefix-args.o $(config_h)
$(CC) $(LDFLAGS) prefix-args.o -o prefix-args
/* Only (possibly) used if HAVE_X11 && !USE_GTK, but no harm in always
defining. */
/* The following oldxmenu-related rules are only (possibly) used if
HAVE_X11 && !USE_GTK, but there is no harm in always defining them
(provided we take a little care that OLDXMENU is never empty). */
really-lwlib:
cd ${lwlibdir}; ${MAKE} ${MFLAGS} \
CC='${CC}' CFLAGS='${CFLAGS}' MAKE='${MAKE}'
......@@ -670,13 +679,10 @@ really-oldXMenu:
stamp-oldxmenu: ${OLDXMENU_DEPS}
touch stamp-oldxmenu
/* HAVE_X11 implies HAVE_X_WINDOWS and HAVE_MENUS. */
#if defined (HAVE_X11) && ! defined (USE_GTK)
/* Supply an ordering for parallel make. */
../src/$(OLDXMENU): ${OLDXMENU}
$(OLDXMENU): $(OLDXMENU_TARGET)
#endif /* HAVE_X11 && !USE_GTK */
../config.status:: epaths.in
@echo "The file epaths.h needs to be set up from epaths.in."
......
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