diff options
86 files changed, 178 insertions, 17 deletions
diff --git a/doc/stdenv.xml b/doc/stdenv.xml index 8eb6fadd3c86..00fa7567c078 100644 --- a/doc/stdenv.xml +++ b/doc/stdenv.xml @@ -854,12 +854,6 @@ following: </varlistentry> <varlistentry> - <term><varname>dontPatchSourceShebangs</varname></term> - <listitem><para>Same as <varname>dontPatchShebangs</varname>, but applied - to the source code before configurePhase.</para></listitem> - </varlistentry> - - <varlistentry> <term><varname>forceShare</varname></term> <listitem><para>The list of directories that must be moved from <filename>$out</filename> to <filename>$out/share</filename>. diff --git a/pkgs/applications/audio/caudec/default.nix b/pkgs/applications/audio/caudec/default.nix index fb2970ed5fa5..24613d4dd965 100644 --- a/pkgs/applications/audio/caudec/default.nix +++ b/pkgs/applications/audio/caudec/default.nix @@ -12,6 +12,10 @@ stdenv.mkDerivation rec { sha256 = "5d1f5ab3286bb748bd29cbf45df2ad2faf5ed86070f90deccf71c60be832f3d5"; }; + preBuild = '' + patchShebangs ./install.sh + ''; + buildInputs = [ bash makeWrapper ]; installPhase = '' diff --git a/pkgs/applications/editors/geany/default.nix b/pkgs/applications/editors/geany/default.nix index 9b3ee6d4f887..8d4002c9ef85 100644 --- a/pkgs/applications/editors/geany/default.nix +++ b/pkgs/applications/editors/geany/default.nix @@ -18,6 +18,8 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; + patchPhase = "patchShebangs ."; + # This file should normally require a gtk-update-icon-cache -q /usr/share/icons/hicolor command # It have no reasons to exist in a redistribuable package postInstall = "rm $out/share/icons/hicolor/icon-theme.cache"; diff --git a/pkgs/applications/graphics/shotwell/default.nix b/pkgs/applications/graphics/shotwell/default.nix index 5f3b96ba16e3..223f632f937d 100644 --- a/pkgs/applications/graphics/shotwell/default.nix +++ b/pkgs/applications/graphics/shotwell/default.nix @@ -30,6 +30,10 @@ in stdenv.mkDerivation rec { configureFlags = [ "--disable-gsettings-convert-install" ]; + preConfigure = '' + patchShebangs . + ''; + postInstall = '' mkdir -p $out/share/gsettings-schemas/$name mv $out/share/glib-2.0 $out/share/gsettings-schemas/$name/ diff --git a/pkgs/applications/graphics/xara/default.nix b/pkgs/applications/graphics/xara/default.nix index e53514a6c1f6..cd3a09887d0f 100644 --- a/pkgs/applications/graphics/xara/default.nix +++ b/pkgs/applications/graphics/xara/default.nix @@ -16,4 +16,5 @@ stdenv.mkDerivation { patches = map fetchurl (import ./debian-patches.nix); + prePatch = "patchShebangs Scripts"; } diff --git a/pkgs/applications/misc/bibletime/default.nix b/pkgs/applications/misc/bibletime/default.nix index df6a3a271b67..41184d6e9492 100644 --- a/pkgs/applications/misc/bibletime/default.nix +++ b/pkgs/applications/misc/bibletime/default.nix @@ -12,6 +12,7 @@ stdenv.mkDerivation rec { }; prePatch = '' + patchShebangs .; ''; preConfigure = '' diff --git a/pkgs/applications/misc/xiphos/default.nix b/pkgs/applications/misc/xiphos/default.nix index bce45286d1f3..d2739dbec505 100644 --- a/pkgs/applications/misc/xiphos/default.nix +++ b/pkgs/applications/misc/xiphos/default.nix @@ -24,6 +24,7 @@ stdenv.mkDerivation rec { libglade scrollkeeper webkitgtk dbus_glib enchant isocodes libuuid ]; prePatch = '' + patchShebangs .; ''; preConfigure = '' diff --git a/pkgs/applications/networking/browsers/chromium/source/default.nix b/pkgs/applications/networking/browsers/chromium/source/default.nix index f4e54c533236..adac4baa29cd 100644 --- a/pkgs/applications/networking/browsers/chromium/source/default.nix +++ b/pkgs/applications/networking/browsers/chromium/source/default.nix @@ -20,6 +20,8 @@ stdenv.mkDerivation { opensslPatches = optional useOpenSSL openssl.patches; + prePatch = "patchShebangs ."; + patches = [ ./sandbox_userns_36.patch ./nix_plugin_paths.patch ]; postPatch = '' diff --git a/pkgs/applications/networking/cluster/kubernetes/default.nix b/pkgs/applications/networking/cluster/kubernetes/default.nix index 7f3eef7554c6..7931da602d6e 100644 --- a/pkgs/applications/networking/cluster/kubernetes/default.nix +++ b/pkgs/applications/networking/cluster/kubernetes/default.nix @@ -13,6 +13,8 @@ stdenv.mkDerivation rec { buildInputs = [ makeWrapper which go iptables rsync ]; + preBuild = "patchShebangs ./hack"; + postBuild = ''go build --ldflags '-extldflags "-static" -s' build/pause/pause.go''; installPhase = '' diff --git a/pkgs/applications/networking/instant-messengers/freetalk/default.nix b/pkgs/applications/networking/instant-messengers/freetalk/default.nix index fd545ee7f587..320e7094d484 100644 --- a/pkgs/applications/networking/instant-messengers/freetalk/default.nix +++ b/pkgs/applications/networking/instant-messengers/freetalk/default.nix @@ -28,6 +28,7 @@ stdenv.mkDerivation { }; preConfigure = '' + patchShebangs . ./autogen.sh ''; diff --git a/pkgs/applications/networking/instant-messengers/jitsi/default.nix b/pkgs/applications/networking/instant-messengers/jitsi/default.nix index 575c6c044643..e6dd6569a55f 100644 --- a/pkgs/applications/networking/instant-messengers/jitsi/default.nix +++ b/pkgs/applications/networking/instant-messengers/jitsi/default.nix @@ -33,6 +33,7 @@ stdenv.mkDerivation rec { cp resources/install/generic/run.sh $out/bin/jitsi chmod +x $out/bin/jitsi sed -i 's| java | ${jdk}/bin/java |' $out/bin/jitsi + patchShebangs $out ''; meta = { diff --git a/pkgs/applications/networking/instant-messengers/kadu/default.nix b/pkgs/applications/networking/instant-messengers/kadu/default.nix index df8846c36b11..44cf13e2917c 100644 --- a/pkgs/applications/networking/instant-messengers/kadu/default.nix +++ b/pkgs/applications/networking/instant-messengers/kadu/default.nix @@ -21,6 +21,10 @@ stdenv.mkDerivation { cmakeFlags = "-DENABLE_AUTODOWNLOAD=OFF -DBUILD_DESCRIPTION='NixOS' -DCMAKE_BUILD_TYPE=Release"; + prePatch = '' + patchShebangs . + ''; + # Disable the kadu plugins I wasn't able to get to work patchPhase = '' sed -i -e '/mpd_mediaplayer/d' \ diff --git a/pkgs/applications/networking/mailreaders/thunderbird/default.nix b/pkgs/applications/networking/mailreaders/thunderbird/default.nix index 6e628dc081cb..e6ba7e21dc8e 100644 --- a/pkgs/applications/networking/mailreaders/thunderbird/default.nix +++ b/pkgs/applications/networking/mailreaders/thunderbird/default.nix @@ -71,6 +71,8 @@ stdenv.mkDerivation rec { ++ stdenv.lib.optional enableOfficialBranding "--enable-official-branding"; configurePhase = '' + patchShebangs . + echo '${stdenv.lib.concatMapStrings (s : "ac_add_options ${s}\n") configureFlags}' > .mozconfig echo "ac_add_options --prefix='$out'" >> .mozconfig echo "mk_add_options MOZ_MAKE_FLAGS='-j$NIX_BUILD_CORES'" >> .mozconfig diff --git a/pkgs/applications/networking/p2p/gnunet/default.nix b/pkgs/applications/networking/p2p/gnunet/default.nix index 2475adadefbf..052c53112536 100644 --- a/pkgs/applications/networking/p2p/gnunet/default.nix +++ b/pkgs/applications/networking/p2p/gnunet/default.nix @@ -38,6 +38,7 @@ stdenv.mkDerivation rec { # Ensure NSS installation works fine configureFlags="$configureFlags --with-nssdir=$out/lib" + patchShebangs src/gns/nss/install-nss-plugin.sh ''; doCheck = false; diff --git a/pkgs/applications/networking/p2p/gnunet/svn.nix b/pkgs/applications/networking/p2p/gnunet/svn.nix index 9e593975412d..25a51b3c9365 100644 --- a/pkgs/applications/networking/p2p/gnunet/svn.nix +++ b/pkgs/applications/networking/p2p/gnunet/svn.nix @@ -47,6 +47,7 @@ stdenv.mkDerivation rec { # Ensure NSS installation works fine configureFlags="$configureFlags --with-nssdir=$out/lib" + patchShebangs src/gns/nss/install-nss-plugin.sh sh contrib/pogen.sh sh bootstrap diff --git a/pkgs/applications/science/logic/cvc4/default.nix b/pkgs/applications/science/logic/cvc4/default.nix index a2618d88918f..5b2e9c54d6f8 100644 --- a/pkgs/applications/science/logic/cvc4/default.nix +++ b/pkgs/applications/science/logic/cvc4/default.nix @@ -9,6 +9,8 @@ stdenv.mkDerivation { buildInputs = [ gmp libantlr3c boost ]; + preConfigure = "patchShebangs ./src/"; + doChecks = true; meta = with stdenv.lib; { diff --git a/pkgs/applications/science/logic/isabelle/default.nix b/pkgs/applications/science/logic/isabelle/default.nix index 4b68f0e3cd6b..88bbe820e2f3 100644 --- a/pkgs/applications/science/logic/isabelle/default.nix +++ b/pkgs/applications/science/logic/isabelle/default.nix @@ -27,6 +27,7 @@ stdenv.mkDerivation { postPatch = '' ENV=$(type -p env) + patchShebangs "." substituteInPlace lib/Tools/env \ --replace /usr/bin/env $ENV substituteInPlace lib/Tools/install \ diff --git a/pkgs/applications/video/cmplayer/default.nix b/pkgs/applications/video/cmplayer/default.nix index fe02f9a33011..3fa38646d9df 100644 --- a/pkgs/applications/video/cmplayer/default.nix +++ b/pkgs/applications/video/cmplayer/default.nix @@ -54,6 +54,10 @@ stdenv.mkDerivation rec { ++ optional cddaSupport libcdda |