This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH, contrib] download_prerequisites: check for existing symlinks before making new ones
- From: Bernd Edlinger <bernd dot edlinger at hotmail dot de>
- To: Jeff Law <law at redhat dot com>, Eric Gallager <egall at gwmail dot gwu dot edu>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 21 Jul 2016 18:15:00 +0000
- Subject: Re: [PATCH, contrib] download_prerequisites: check for existing symlinks before making new ones
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=softfail (sender IP is 10.152.2.57) smtp.mailfrom=hotmail.de; redhat.com; dkim=none (message not signed) header.d=none;redhat.com; dmarc=none action=none header.from=hotmail.de;
> So rather than relying on ln to remove the link, why don't we just
> explicitly remove it with rm -f?
sounds good, I ran into similar issues already.
ln -nfs does not follow the target if it is a symlink
treat LINK_NAME as a normal file if it is a symbolic
link to a
but I think a simple rm -f will do as well, and avoid potential
However wget has a similar issue, if the $MPFR.tar.gz file is already
there, maybe incomplete, the wget chooses a new name, so I'd suggest
to rm -f that file as well, and the whole $MPFR subtree while you are