[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Mingw-users] Re: MSYS ln -s to directory
From: |
Ralf Wildenhues |
Subject: |
Re: [Mingw-users] Re: MSYS ln -s to directory |
Date: |
Mon, 10 Apr 2006 10:55:03 +0200 |
User-agent: |
Mutt/1.5.11 |
Hi Ross,
* Ross Ridge wrote on Sun, Apr 09, 2006 at 06:54:38AM CEST:
> Ralf Wildenhues wrote:
> >Yes. New version attached, tested on MinGW (selects cp -p) and Cygwin
> >(selects ln -s) now. OK?
>
> Hmm... it would be nice to have a way to override it selecting ln -s
> on Cygwin. Bootstrapping a MinGW build of gcc head currently fails
> while building libstdc++ on Cygwin because a bunch of symlinks are
> created that the newly built MinGW compiler can't see.
I guess the followup patch below would do the job. However, I'm not so
sure whether it's the right thing to do: Autoconf internally has two
variables for this, $as_ln_s for M4sh and $LN_S for Autoconf. The patch
only overrides the latter; should be sufficient for your needs (except
of course for the hardcoded LN_S macros in parts of GCC that came up
here before).
BTW, as an ugly workaround you could put a script like the following
early in your PATH, assuming you still want hard links to work:
#! /bin/sh
for arg
do
case $arg in -s) exit 1;; esac
done
exec /bin/ln "$@"
Cheers,
Ralf
* lib/autoconf/programs.m4 (AC_PROG_LN_S): Allow the user to
override `$LN_S'.
Suggested by Ross Ridge <address@hidden>.
Index: lib/autoconf/programs.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/programs.m4,v
retrieving revision 1.50
diff -u -r1.50 programs.m4
--- lib/autoconf/programs.m4 17 Mar 2006 20:37:26 -0000 1.50
+++ lib/autoconf/programs.m4 10 Apr 2006 06:25:43 -0000
@@ -678,7 +678,10 @@
AN_PROGRAM([ln], [AC_PROG_LN_S])
AC_DEFUN([AC_PROG_LN_S],
[AC_MSG_CHECKING([whether ln -s works])
-AC_SUBST([LN_S], [$as_ln_s])dnl
+if test -z "$LN_S"; then
+ LN_S=$as_ln_s
+fi
+AC_SUBST([LN_S])dnl
if test "$LN_S" = "ln -s"; then
AC_MSG_RESULT([yes])
else
- Re: [Mingw-users] Re: MSYS ln -s to directory,
Ralf Wildenhues <=