]> git.draconx.ca Git - dxcommon.git/commitdiff
fix-ltdl: Delete libobj symlink before attempting to create it.
authorNick Bowler <nbowler@draconx.ca>
Fri, 11 May 2012 02:17:51 +0000 (22:17 -0400)
committerNick Bowler <nbowler@draconx.ca>
Fri, 11 May 2012 02:17:51 +0000 (22:17 -0400)
There seems to be a (rare) race in parallel builds where make for some
reason decides to update the libobj symlink after it already exists,
which fails.  I can't reproduce the failure, but deleting the symlink
(if one exists) before creating it should avoid the issue.

scripts/fix-ltdl.pl

index 806554526ccd7069a56a95e314cef0290c486357..da987be72ac04b2125b378d9e32d14965b7bd9b3 100755 (executable)
@@ -62,6 +62,7 @@ sub handle_libobj {
        print <<EOF;
 ${am_dir_prefix}libobj_la_SOURCES += $distfile
 $ltdl_dir/$base.lo: $ltdl_dir/${am_dir_prefix}libobj_la-$base.lo
+\t\$(AM_V_at)-rm -f \$@
 \t\$(AM_V_at)(cd \$(\@D) && \$(LN_S) ${am_dir_prefix}libobj_la-\$(\@F) \$(\@F))
 EOF