diff options
author | Peter Breitenlohner <peb@mppmu.mpg.de> | 2011-09-29 12:17:38 +0000 |
---|---|---|
committer | Peter Breitenlohner <peb@mppmu.mpg.de> | 2011-09-29 12:17:38 +0000 |
commit | 307a409e5a3cc8c467bbe5d0e0fe9beacf620adf (patch) | |
tree | 77b4d4f00642c3c1c86755e63cd5d2424b058972 /Build/source/utils/xindy | |
parent | 54b9868277dbd900c93d8b750654b9ed43b51b26 (diff) |
somewhat more general way to create symlinks for linked scripts
using build-aux/relpath
git-svn-id: svn://tug.org/texlive/trunk@24137 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/utils/xindy')
-rw-r--r-- | Build/source/utils/xindy/Makefile.in | 28 |
1 files changed, 12 insertions, 16 deletions
diff --git a/Build/source/utils/xindy/Makefile.in b/Build/source/utils/xindy/Makefile.in index f57bd825646..493b454329a 100644 --- a/Build/source/utils/xindy/Makefile.in +++ b/Build/source/utils/xindy/Makefile.in @@ -248,7 +248,8 @@ EXTRA_DIST = README-clisp $(XINDY_TREE)-PATCHES $(XINDY_TREE)/AUTHORS \ $(XINDY_TREE)/configure.ac \ $(XINDY_TREE)/make-rules/alphabets/Makefile.am.not-yet \ $(XINDY_TREE)/make-rules/alphabets/lang.defs \ - $(XINDY_TREE)/make-rules/alphabets/mk-lang.sh + $(XINDY_TREE)/make-rules/alphabets/mk-lang.sh \ + ../../build-aux/relpath SUBDIRS = . $(XINDY_TREE) DIST_SUBDIRS = $(SUBDIRS) perl_scripts = texindy xindy @@ -818,10 +819,8 @@ all-local: config.force config.force: echo timestamp >config.force $(SHELL) ./config.status --recheck - -# .PHONY: install-lua-links install-perl-links install-shell-links \ - install-links make-links uninstall-links + install-links uninstall-links @WIN32_TRUE@@WIN32_WRAP_TRUE@$(wrappers): $(runscript) @WIN32_TRUE@@WIN32_WRAP_TRUE@ $(LN_S) $(runscript) $@ @@ -834,21 +833,18 @@ install-perl-links: install-shell-links: @WIN32_FALSE@ $(MAKE) $(AM_MAKEFLAGS) TYPE=shell EXT=sh install-links -# We support both multiplatform and non-multiplatform builds. +# We support native builds, multiplatform or not, as well as distro builds. install-links: - case "$(bindir)" in \ - */bin) $(MAKE) $(AM_MAKEFLAGS) REL=.. TYPE=$(TYPE) EXT=$(EXT) make-links;; \ - */bin/*) $(MAKE) $(AM_MAKEFLAGS) REL=../.. TYPE=$(TYPE) EXT=$(EXT) make-links;; \ - *) echo "strange directory '$(bindir)' for linked $(TYPE) scripts" >&2; \ - exit 1;; \ - esac - -make-links: - @cd $(DESTDIR)$(bindir) && \ + @REL=`$(SHELL) $(srcdir)/../../build-aux/relpath '$(DESTDIR)' '$(bindir)' '$(prefix)'`; \ + if test -z "$$REL"; then \ + echo 'unable to compute relative path for linked $(TYPE) scripts' >&2; \ + exit 1; \ + fi; \ + cd $(DESTDIR)$(bindir) && \ for f in $($(TYPE)_scripts); do \ rm -f $$f; \ - echo "creating link '$$f' -> '$(REL)/$(scriptsdir)/$$f.$(EXT)'"; \ - $(LN_S) $(REL)/$(scriptsdir)/$$f.$(EXT) $$f || exit 1; \ + echo "creating link '$$f' -> '$$REL/$(scriptsdir)/$$f.$(EXT)'"; \ + $(LN_S) $$REL/$(scriptsdir)/$$f.$(EXT) $$f || exit 1; \ done uninstall-links: |