changeset 109169:5df3f77a9df9

Remove src/prefix-args.c. * configure.in (PRE_EDIT_LDFLAGS, POST_EDIT_LDFLAGS): Remove. * msdos/sed1v2.inp: Remove reference to prefix-args. * prefix-args.c: Remove file. * src/autodeps.mk (ALLOBJS): Remove reference to prefix-args. * src/Makefile.in (temacs${EXEEXT}): Remove references to PRE_EDIT_LDFLAGS and POST_EDIT_LDFLAGS. (mostlyclean): Remove reference to prefix-args. (prefix-args): Remove.
author Dan Nicolaescu <dann@ics.uci.edu>
date Wed, 07 Jul 2010 20:31:04 -0700
parents fb5779a6cf4b
children 76e072dbe342
files ChangeLog configure configure.in msdos/ChangeLog msdos/sed1v2.inp src/ChangeLog src/Makefile.in src/autodeps.mk src/prefix-args.c
diffstat 9 files changed, 19 insertions(+), 124 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Wed Jul 07 20:03:52 2010 -0700
+++ b/ChangeLog	Wed Jul 07 20:31:04 2010 -0700
@@ -1,5 +1,7 @@
 2010-07-08  Dan Nicolaescu  <dann@ics.uci.edu>
 
+	* configure.in (PRE_EDIT_LDFLAGS, POST_EDIT_LDFLAGS): Remove.
+
 	* configure.in (UNEXEC_OBJ): Add comment about values for MSDOS
 	and MSWindows.
 
--- a/configure	Wed Jul 07 20:03:52 2010 -0700
+++ b/configure	Wed Jul 07 20:31:04 2010 -0700
@@ -600,8 +600,6 @@
 MOUSE_SUPPORT
 LIB_GCC
 LINKER
-POST_EDIT_LDFLAGS
-PRE_EDIT_LDFLAGS
 LD_SWITCH_SYSTEM_TEMACS
 POST_ALLOC_OBJ
 PRE_ALLOC_OBJ
@@ -14163,8 +14161,6 @@
 esac
 
 
-PRE_EDIT_LDFLAGS=
-POST_EDIT_LDFLAGS=
 if test "x$ORDINARY_LINK" = "xyes"; then
 
   LINKER="\$(CC)"
@@ -14185,17 +14181,7 @@
   ## 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"
-  ## GCC passes any argument prefixed with -Xlinker directly to the linker.
-  ## See prefix-args.c for an explanation of why we do not do this with the
-  ## shell''s ``for'' construct.  Note that sane people do not have '.' in
-  ## their paths, so we must use ./prefix-args.
-  ## TODO either make prefix-args check ORDINARY_LINK internally,
-  ## or remove it altogether (bug#6184), removing the need for this hack.
-  PRE_EDIT_LDFLAGS='`./prefix-args -Xlinker'
-  POST_EDIT_LDFLAGS='`'
-fi
-
-
+fi
 
 test "x$LINKER" = "x" && LINKER=ld
 ## FIXME? What setting of EDIT_LDFLAGS should this have?
--- a/configure.in	Wed Jul 07 20:03:52 2010 -0700
+++ b/configure.in	Wed Jul 07 20:31:04 2010 -0700
@@ -3360,8 +3360,6 @@
 esac
 
 
-PRE_EDIT_LDFLAGS=
-POST_EDIT_LDFLAGS=
 if test "x$ORDINARY_LINK" = "xyes"; then
 
   LINKER="\$(CC)"
@@ -3380,17 +3378,7 @@
   ## 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"
-  ## GCC passes any argument prefixed with -Xlinker directly to the linker.
-  ## See prefix-args.c for an explanation of why we do not do this with the
-  ## shell''s ``for'' construct.  Note that sane people do not have '.' in
-  ## their paths, so we must use ./prefix-args.
-  ## TODO either make prefix-args check ORDINARY_LINK internally,
-  ## or remove it altogether (bug#6184), removing the need for this hack.
-  PRE_EDIT_LDFLAGS='`./prefix-args -Xlinker'
-  POST_EDIT_LDFLAGS='`'
 fi
-AC_SUBST(PRE_EDIT_LDFLAGS)
-AC_SUBST(POST_EDIT_LDFLAGS)
 
 test "x$LINKER" = "x" && LINKER=ld
 ## FIXME? What setting of EDIT_LDFLAGS should this have?
--- a/msdos/ChangeLog	Wed Jul 07 20:03:52 2010 -0700
+++ b/msdos/ChangeLog	Wed Jul 07 20:31:04 2010 -0700
@@ -1,3 +1,7 @@
+2010-07-08  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* sed1v2.inp: Remove reference to prefix-args.
+
 2010-07-07  Andreas Schwab  <schwab@linux-m68k.org>
 
 	* sed2v2.inp (HAVE_MEMCPY, HAVE_MEMSET): Edit to 1.
--- a/msdos/sed1v2.inp	Wed Jul 07 20:03:52 2010 -0700
+++ b/msdos/sed1v2.inp	Wed Jul 07 20:31:04 2010 -0700
@@ -128,7 +128,6 @@
 /^[ 	]*$/d
 /^	if test -f/,/^	fi$/c\
 	command.com /c if exist .gdbinit rm -f _gdbinit
-/^temacs:/s/prefix-args//
 /^temacs:/s/stamp-oldxmenu//
 /^	if test "\${CANNOT_DUMP}" =/,/^	else /d
 /^	fi/d
--- a/src/ChangeLog	Wed Jul 07 20:03:52 2010 -0700
+++ b/src/ChangeLog	Wed Jul 07 20:31:04 2010 -0700
@@ -1,5 +1,13 @@
 2010-07-08  Dan Nicolaescu  <dann@ics.uci.edu>
 
+	Remove prefix-args.c
+	* prefix-args.c: Remove file.
+	* autodeps.mk (ALLOBJS): Remove reference to prefix-args.
+	* Makefile.in (temacs${EXEEXT}): Remove references to
+	PRE_EDIT_LDFLAGS and POST_EDIT_LDFLAGS.
+	(mostlyclean): Remove reference to prefix-args.
+	(prefix-args): Remove.
+
 	Simplify cstart_of_data, start_of_code and related code.
 	* mem-limits.h: Remove !emacs and _LIBC conditional code.
 	(start_of_data): Merge into start_of_data function.
--- a/src/Makefile.in	Wed Jul 07 20:03:52 2010 -0700
+++ b/src/Makefile.in	Wed Jul 07 20:31:04 2010 -0700
@@ -628,20 +628,10 @@
 	echo "#define BUILDOBJ \"${obj} ${otherobj} " "\"" > buildobj.h
 
 
-## We cannot define variables for PRE_EDIT and POST_EDIT.
-## If !ORDINARY_LINK && !LINKER && GCC, they add a
-## `./prefix-args -Xlinker ... ` wrapper, otherwise they are empty.
-## One alternative to this approach would be to always call prefix-args, 
-## and have it DTRT in all cases, by testing the above defines.
-temacs${EXEEXT}: $(START_FILES) stamp-oldxmenu ${obj} ${otherobj} prefix-args${EXEEXT}
-	$(LD) @PRE_EDIT_LDFLAGS@ ${TEMACS_LDFLAGS} @POST_EDIT_LDFLAGS@ \
-	  ${TEMACS_LDFLAGS2} \
+temacs${EXEEXT}: $(START_FILES) stamp-oldxmenu ${obj} ${otherobj}
+	$(LD) ${TEMACS_LDFLAGS} ${TEMACS_LDFLAGS2} \
 	  -o temacs ${START_FILES} ${obj} ${otherobj} ${LIBES}
 
-prefix-args${EXEEXT}: prefix-args.o $(config_h)
-	$(CC) $(LDFLAGS) prefix-args.o -o prefix-args
-
-
 ## 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).
@@ -688,7 +678,7 @@
 
 
 mostlyclean:
-	rm -f temacs${EXEEXT} prefix-args${EXEEXT} core *.core \#* *.o libXMenu11.a liblw.a
+	rm -f temacs${EXEEXT} core *.core \#* *.o libXMenu11.a liblw.a
 	rm -f ../etc/DOC
 	rm -f bootstrap-emacs${EXEEXT} emacs-${version}${EXEEXT}
 	rm -f buildobj.h
--- a/src/autodeps.mk	Wed Jul 07 20:03:52 2010 -0700
+++ b/src/autodeps.mk	Wed Jul 07 20:31:04 2010 -0700
@@ -2,5 +2,5 @@
 
 ## This is inserted in src/Makefile if AUTO_DEPEND=yes.
 
-ALLOBJS=$(START_FILES) ${obj} ${otherobj} prefix-args.o
+ALLOBJS=$(START_FILES) ${obj} ${otherobj}
 -include $(ALLOBJS:%.o=${DEPDIR}/%.d)
--- a/src/prefix-args.c	Wed Jul 07 20:03:52 2010 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,82 +0,0 @@
-/* prefix-args.c - echo each argument, prefixed by a string.
-   Copyright (C) 1992, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
-                 2008, 2009, 2010  Free Software Foundation, Inc.
-
-This file is part of GNU Emacs.
-
-GNU Emacs is free software: you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-GNU Emacs is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.  */
-
-/* Jim Blandy <jimb@occs.cs.oberlin.edu> - September 1992
-
-   When using GCC 2 as the linker in the build process, options
-   intended for the linker need to be prefixed with the "-Xlinker"
-   option.  If an option takes an argument, we need to use -Xlinker
-   twice - once for the option and once for its argument.  For
-   example, to run the linker with the options "-Bstatic" "-e"
-   "_start", you'd need to pass the following options to GCC:
-
-   -Xlinker -Bstatic -Xlinker -e -Xlinker _start.
-
-   The Emacs makefile used to use a Bourne Shell `for' loop to prefix
-   each linker option with "-Xlinker", but 1) the for loop was hairier
-   than one might hope because it had to work when there were no
-   arguments to pass to the linker - the shell barfs on a loop like
-   this:
-
-       for arg in ; do echo -Xlinker "$arg"; done
-
-   and 2) the whole compilation command containing this loop seems to
-   exit with a non-zero status and halt the build under Ultrix.
-
-   If I can't write a completely portable program to do this in C,
-   I'm quitting and taking up gardening.  */
-
-#ifdef HAVE_CONFIG_H
-# include <config.h>
-#endif
-
-#if STDC_HEADERS
-# include <stdlib.h>		/* for proper declaration of `exit' */
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-
-int
-main (int argc, char **argv)
-{
-  char *progname;
-  char *prefix;
-
-  progname = argv[0];
-  argc--, argv++;
-
-  if (argc < 1)
-    {
-      fprintf (stderr, "Usage: %s PREFIX ARGS...\n\
-Echo each ARG preceded by PREFIX and a space.\n", progname);
-      exit (2);
-    }
-
-  prefix = argv[0];
-  argc--, argv++;
-
-  for (; argc > 0; argc--, argv++)
-    printf ("%s %s%c", prefix, argv[0], (argc > 1) ? ' ' : '\n');
-
-  exit (0);
-}
-
-/* arch-tag: 08136d70-e5c0-49c7-bcd8-b4850233977a
-   (do not change this comment) */