Fix builds/ links to survive configuring twice with different prefixes
authorMorgan Deters <mdeters@cs.nyu.edu>
Fri, 15 Feb 2013 17:00:29 +0000 (12:00 -0500)
committerMorgan Deters <mdeters@cs.nyu.edu>
Fri, 15 Feb 2013 17:37:23 +0000 (12:37 -0500)
Makefile.builds.in

index 6f9c7aaabef0c0c45a434f249112b509dffdbdd7..be6df95d3a9c30cc55828b4c1ecf62db40f1511c 100644 (file)
@@ -137,8 +137,8 @@ else
        done
 endif
 #      set up builds/$(CURRENT_BUILD)/bin and builds/$(CURRENT_BUILD)/lib
-       $(AM_V_at)test -e $(CURRENT_BUILD)/lib || ln -sf "$(abs_builddir)$(libdir)" $(CURRENT_BUILD)/lib
-       $(AM_V_at)test -e $(CURRENT_BUILD)/bin || ln -sf "$(abs_builddir)$(bindir)" $(CURRENT_BUILD)/bin
+       rm -f $(CURRENT_BUILD)/lib; ln -sf "$(abs_builddir)$(libdir)" $(CURRENT_BUILD)/lib
+       rm -f $(CURRENT_BUILD)/bin; ln -sf "$(abs_builddir)$(bindir)" $(CURRENT_BUILD)/bin
 #      set up builds/...prefix.../bin and builds/...prefix.../lib
        $(AM_V_mkdir) ".$(bindir)"
        $(AM_V_mkdir) ".$(libdir)"
@@ -184,8 +184,8 @@ else
        done
 endif
 #      set up builds/bin and builds/lib
-       $(AM_V_at)test -e lib || ln -sf ".$(libdir)" lib
-       $(AM_V_at)test -e bin || ln -sf ".$(bindir)" bin
+       rm -f lib; ln -sf ".$(libdir)" lib
+       rm -f bin; ln -sf ".$(bindir)" bin
        rm -f doc; ln -sf "$(CURRENT_BUILD)/doc" doc
        rm -f examples; ln -sf "$(CURRENT_BUILD)/examples" examples