On Mon, Aug 25, 2003 at 12:58:07PM -0500, Bob Friesenhahn wrote:
> On Mon, 25 Aug 2003, Albert Chin wrote:
> 
> > If a compiler doesn't support -c -o, libtool creates a lock file by
> > hard linking the libtool binary with the lock file. This is a problem
> > if the libtool binary is on a different file system than the lock
> > file. Why don't we use a symbolic link?
> 
> Creating a hard link is an atomic operation whereas a symbolic link is
> not so it can't be used as a locking mechanism.
> 
> Maybe there is some other hard-link which can be used instead?

Why not use $srcfile and "$srcfile.lock" as the lock file? So, rather
than:
      until $run ln "$0" "$lockfile" 2>/dev/null; do
we would have:
      lockfile="$srcfile.lock"
      ...
      until $run ln "$srcfile" "$lockfile" 2>/dev/null; do

-- 
albert chin ([EMAIL PROTECTED])


_______________________________________________
Libtool mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/libtool

Reply via email to