This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: suffix and prefix support
- To: mrs at wrs dot com (Mike Stump)
- Subject: Re: suffix and prefix support
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Sun, 28 Jun 1998 00:53:39 -0600
- cc: egcs-patches at cygnus dot com
- Reply-To: law at cygnus dot com
In message <199806190613.XAA07559@kankakee.wrs.com>you write:
> These patches fix program_suffix and program_prefix support so they
> work. The autoconf patches I think should and can go back to the
> autoconf people.
>
> 1998-06-18 Mike Stump <mrs@wrs.com>
>
> * aclocal.m4 (AC_ARG_PROGRAM_FIXED): Remove spaces in sed
> commands.
> * configure.in: Use AC_ARG_PROGRAM_FIXED.
Seems like we should do something similar for program_transform_cross_name?
It has also been argued that autoconf has built-in support for the
tranform name stuff and that we should drop the manual implementation
found in gcc. If that's the case, maybe the autoconf implementation
actually handles this stuff correctly.
Jeff
>
> Doing diffs in aclocal.m4.~1~:
> *** aclocal.m4.~1~ Thu Jun 18 21:46:49 1998
> --- aclocal.m4 Thu Jun 18 21:58:44 1998
> *************** AC_SUBST(INSTALL_PROGRAM)dnl
> *** 153,155 ****
> --- 153,180 ----
> test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
> AC_SUBST(INSTALL_DATA)dnl
> ])
> +
> + dnl ### Transforming program names.
> +
> + dnl AC_ARG_PROGRAM_FIXED()
> + AC_DEFUN(AC_ARG_PROGRAM_FIXED,
> + [if test "$program_transform_name" = s,x,x,; then
> + program_transform_name=
> + else
> + # Double any \ or $. echo might interpret backslashes.
> + cat <<\EOF_SED > conftestsed
> + s,\\,\\\\,g; s,\$,$$,g
> + EOF_SED
> + program_transform_name="`echo $program_transform_name|sed -f conftestse
> d`"
> + rm -f conftestsed
> + fi
> + test "$program_prefix" != NONE &&
> + program_transform_name="s,^,${program_prefix},;$program_transform_name"
> + # Use a double $ so make ignores it.
> + test "$program_suffix" != NONE &&
> + program_transform_name="s,\$\$,${program_suffix},;$program_transform_na
> me"
> +
> + # sed with no file args requires a program.
> + test "$program_transform_name" = "" && program_transform_name="s,x,x,"
> + ])
> +
> --------------
> Doing diffs in configure.in.~1~:
> *** configure.in.~1~ Thu Jun 18 21:37:49 1998
> --- configure.in Thu Jun 18 21:58:19 1998
> *************** esac
> *** 126,131 ****
> --- 126,134 ----
> # Determine the host, build, and target systems
> AC_CANONICAL_SYSTEM
>
> + # Program prefix and suffix
> + AC_ARG_PROGRAM_FIXED
> +
> # Find some useful tools
> AC_PROG_AWK
> AC_PROG_LEX
> --------------