From a10c2e6e9e9af3addbf91c0bb374257fb6c72553 Mon Sep 17 00:00:00 2001 From: Joachim Breitner Date: Tue, 1 Aug 2017 19:30:09 +0000 Subject: Don't use $SHELL in wrapper scripts Do not use $SHELL as $SHELL is the user's preferred interactive shell. We do not want this to leak into the wrapper scripts. --- driver/ghci/ghc.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'driver/ghci') diff --git a/driver/ghci/ghc.mk b/driver/ghci/ghc.mk index 0f31884080..0e18a5fbbd 100644 --- a/driver/ghci/ghc.mk +++ b/driver/ghci/ghc.mk @@ -21,7 +21,7 @@ install_driver_ghci: $(INSTALL_DIR) "$(DESTDIR)$(bindir)" $(call removeFiles, "$(WRAPPER)") $(CREATE_SCRIPT) "$(WRAPPER)" - echo '#!$(SHELL)' >> "$(WRAPPER)" + echo '#!/bin/sh' >> "$(WRAPPER)" echo 'exec "$(bindir)/$(CrossCompilePrefix)ghc-$(ProjectVersion)" --interactive "$$@"' >> "$(WRAPPER)" $(EXECUTABLE_FILE) "$(WRAPPER)" $(call removeFiles,"$(DESTDIR)$(bindir)/$(CrossCompilePrefix)ghci") @@ -56,7 +56,7 @@ install_driver_ghcii: GHCII_SCRIPT_VERSIONED = $(DESTDIR)$(bindir)/ghcii-$(Proje install_driver_ghcii: $(INSTALL_DIR) "$(DESTDIR)$(bindir)" $(call removeFiles,"$(GHCII_SCRIPT)") - echo "#!$(SHELL)" >> $(GHCII_SCRIPT) + echo "#!/bin/sh" >> $(GHCII_SCRIPT) echo 'exec "$$(dirname "$$0")"/ghc --interactive "$$@"' >> $(GHCII_SCRIPT) $(EXECUTABLE_FILE) $(GHCII_SCRIPT) cp $(GHCII_SCRIPT) $(GHCII_SCRIPT_VERSIONED) -- cgit v1.2.1