More robust install.sh: do runnability test in fresh subdirectory.

Fix #15558.
This commit is contained in:
Felix S. Klock II 2014-07-10 19:18:46 +02:00
parent a1bd5d359b
commit 59ab65b2d9

View File

@ -14,16 +14,18 @@ else
MAYBE_DISABLE_VERIFY=
endif
install: dist-install-dir-$(CFG_BUILD)-with-target-libs
$(Q)sh tmp/dist/$(PKG_NAME)-$(CFG_BUILD)/install.sh --prefix="$(DESTDIR)$(CFG_PREFIX)" --libdir="$(DESTDIR)$(CFG_LIBDIR)" --mandir="$(DESTDIR)$(CFG_MANDIR)" "$(MAYBE_DISABLE_VERIFY)"
install: dist-install-dir-$(CFG_BUILD)-with-target-libs | tmp/empty_dir
$(Q)cd tmp/empty_dir && sh ../../tmp/dist/$(PKG_NAME)-$(CFG_BUILD)/install.sh --prefix="$(DESTDIR)$(CFG_PREFIX)" --libdir="$(DESTDIR)$(CFG_LIBDIR)" --mandir="$(DESTDIR)$(CFG_MANDIR)" "$(MAYBE_DISABLE_VERIFY)"
# Remove tmp files while we can because they may have been created under sudo
$(Q)rm -R tmp/dist
uninstall: dist-install-dir-$(CFG_BUILD)-with-target-libs
$(Q)sh tmp/dist/$(PKG_NAME)-$(CFG_BUILD)/install.sh --uninstall --prefix="$(DESTDIR)$(CFG_PREFIX)" --libdir="$(DESTDIR)$(CFG_LIBDIR)" --mandir="$(DESTDIR)$(CFG_MANDIR)"
uninstall: dist-install-dir-$(CFG_BUILD)-with-target-libs | tmp/empty_dir
$(Q)cd tmp/empty_dir && sh ../../tmp/dist/$(PKG_NAME)-$(CFG_BUILD)/install.sh --uninstall --prefix="$(DESTDIR)$(CFG_PREFIX)" --libdir="$(DESTDIR)$(CFG_LIBDIR)" --mandir="$(DESTDIR)$(CFG_MANDIR)"
# Remove tmp files while we can because they may have been created under sudo
$(Q)rm -R tmp/dist
tmp/empty_dir:
mkdir -p $@
######################################################################
# Android remote installation