1 ## am/bin_links.am: Makefile fragment for bindir links.
3 ## Copyright (C) 2011-2013 Peter Breitenlohner <tex-live@tug.org>
4 ## You may freely use, modify and/or distribute this file.
6 ## requires conditional WIN32
7 ## requires $(bin_links)
8 ## Symlinks within $(bindir): FILE:LINK indicates LINK->FILE
9 ## for binaries and scripts use, e.g.,
10 ## binprog$(EXEEXT):foo
12 ## respectively, such that the links created on cygwin are
13 ## 'foo->binprog.exe' and 'bar->script'.
14 .PHONY: install-bin-links uninstall-bin-links
18 @cd $(DESTDIR)$(bindir) && \
19 for s in $(bin_links); do \
20 link=`echo $$s | sed 's,.*:,,'`; \
21 file=`echo $$s | sed 's,:.*,,'`; \
23 echo "creating link '$$link' -> '$$file'"; \
24 $(LN_S) $$file $$link || exit 1; \
30 @for s in $(bin_links); do \
31 link=`echo $$s | sed 's,.*:,,'`; \
32 rm -f $(DESTDIR)$(bindir)/$$link; \