3
0
Fork 0
forked from mirrors/nixpkgs

treewide: replace utillinux refs of {u,}mount

umount and mount are now provided top-level
This commit is contained in:
Matthew Bauer 2018-03-27 13:17:10 -05:00
parent 11f0e07d4f
commit 49455d7bae
11 changed files with 22 additions and 38 deletions

View file

@ -1,5 +1,5 @@
{ stdenv, fetchurl, fetchpatch, replace, curl, expat, zlib, bzip2 { stdenv, fetchurl, fetchpatch, replace, curl, expat, zlib, bzip2
, useNcurses ? false, ncurses, useQt4 ? false, qt4 , useNcurses ? false, ncurses, useQt4 ? false, qt4, ps
, buildPlatform, hostPlatform , buildPlatform, hostPlatform
}: }:

View file

@ -6,8 +6,6 @@
, utillinux , utillinux
}: }:
assert stdenv.isLinux -> (utillinux != null);
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "creduce-${version}"; name = "creduce-${version}";
version = "2.7.0"; version = "2.7.0";

View file

@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
}; };
nativeBuildInputs = [ m4 makeWrapper ]; nativeBuildInputs = [ m4 makeWrapper ];
buildInputs = [ libbsd perl SysCPU ]; buildInputs = [ perl SysCPU libbsd ];
postInstall = '' postInstall = ''
substituteInPlace $out/bin/compiler_test.pl \ substituteInPlace $out/bin/compiler_test.pl \

View file

@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
# There is no real reason for a bin/sbin split, so just use bin. # There is no real reason for a bin/sbin split, so just use bin.
preConfigure = '' preConfigure = ''
export ac_cv_path_SHUTDOWN=${systemd}/sbin/shutdown export ac_cv_path_SHUTDOWN=${systemd}/sbin/shutdown
export ac_cv_path_WALL=${utillinux}/bin/wall export ac_cv_path_WALL=${wall}/bin/wall
sed -i 's|/bin/cat|${coreutils}/bin/cat|' configure sed -i 's|/bin/cat|${coreutils}/bin/cat|' configure
export configureFlags="\ export configureFlags="\
--bindir=$out/bin \ --bindir=$out/bin \

View file

@ -1,5 +1,6 @@
{ stdenv, lib, sudo, utillinux, coreutils, systemd, cryptsetup, { stdenv, lib, sudo, coreutils, systemd, cryptsetup
buildGoPackage, fetchFromGitHub }: , mount, umount
, buildGoPackage, fetchFromGitHub }:
buildGoPackage rec { buildGoPackage rec {
name = "interlock-${version}"; name = "interlock-${version}";
@ -23,8 +24,8 @@ buildGoPackage rec {
buildFlags = [ "-tags textsecure" ]; buildFlags = [ "-tags textsecure" ];
postPatch = '' postPatch = ''
grep -lr '/s\?bin/' | xargs sed -i \ grep -lr '/s\?bin/' | xargs sed -i \
-e 's|/bin/mount|${utillinux}/bin/mount|' \ -e 's|/bin/mount|${mount}/bin/mount|' \
-e 's|/bin/umount|${utillinux}/bin/umount|' \ -e 's|/bin/umount|${umount}/bin/umount|' \
-e 's|/bin/cp|${coreutils}/bin/cp|' \ -e 's|/bin/cp|${coreutils}/bin/cp|' \
-e 's|/bin/mv|${coreutils}/bin/mv|' \ -e 's|/bin/mv|${coreutils}/bin/mv|' \
-e 's|/bin/chown|${coreutils}/bin/chown|' \ -e 's|/bin/chown|${coreutils}/bin/chown|' \

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, makeWrapper, jre, utillinux, getopt }: { stdenv, fetchurl, makeWrapper, jre, utillinux }:
with stdenv.lib; with stdenv.lib;
@ -13,8 +13,7 @@ stdenv.mkDerivation rec {
patches = [ ./es-home-2.x.patch ./es-classpath-2.x.patch ]; patches = [ ./es-home-2.x.patch ./es-classpath-2.x.patch ];
buildInputs = [ makeWrapper jre ] ++ buildInputs = [ makeWrapper jre utillinux ];
(if (!stdenv.isDarwin) then [utillinux] else [getopt]);
installPhase = '' installPhase = ''
mkdir -p $out mkdir -p $out
@ -24,9 +23,7 @@ stdenv.mkDerivation rec {
mv $out/bin/plugin $out/bin/elasticsearch-plugin mv $out/bin/plugin $out/bin/elasticsearch-plugin
wrapProgram $out/bin/elasticsearch \ wrapProgram $out/bin/elasticsearch \
--prefix ES_CLASSPATH : "$out/lib/${name}.jar":"$out/lib/*" \ --prefix ES_CLASSPATH : "$out/lib/${name}.jar":"$out/lib/*" \
${if (!stdenv.isDarwin) --prefix PATH : "${utillinux}/bin" \
then ''--prefix PATH : "${utillinux}/bin/"''
else ''--prefix PATH : "${getopt}/bin"''} \
--set JAVA_HOME "${jre}" --set JAVA_HOME "${jre}"
wrapProgram $out/bin/elasticsearch-plugin --set JAVA_HOME "${jre}" wrapProgram $out/bin/elasticsearch-plugin --set JAVA_HOME "${jre}"
''; '';

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, elk5Version, makeWrapper, jre_headless, utillinux, getopt }: { stdenv, fetchurl, elk5Version, makeWrapper, jre_headless, utillinux }:
with stdenv.lib; with stdenv.lib;
@ -13,8 +13,7 @@ stdenv.mkDerivation rec {
patches = [ ./es-home-5.x.patch ./es-classpath-5.x.patch ]; patches = [ ./es-home-5.x.patch ./es-classpath-5.x.patch ];
buildInputs = [ makeWrapper jre_headless ] ++ buildInputs = [ makeWrapper jre_headless utillinux ];
(if (!stdenv.isDarwin) then [utillinux] else [getopt]);
installPhase = '' installPhase = ''
mkdir -p $out mkdir -p $out
@ -24,9 +23,7 @@ stdenv.mkDerivation rec {
wrapProgram $out/bin/elasticsearch \ wrapProgram $out/bin/elasticsearch \
--prefix ES_CLASSPATH : "$out/lib/*" \ --prefix ES_CLASSPATH : "$out/lib/*" \
${if (!stdenv.isDarwin) --prefix PATH : "${utillinux}/bin" \
then ''--prefix PATH : "${utillinux}/bin/"''
else ''--prefix PATH : "${getopt}/bin"''} \
--set JAVA_HOME "${jre_headless}" \ --set JAVA_HOME "${jre_headless}" \
--set ES_JVM_OPTIONS "$out/config/jvm.options" --set ES_JVM_OPTIONS "$out/config/jvm.options"

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, elk6Version, makeWrapper, jre_headless, utillinux, getopt }: { stdenv, fetchurl, elk6Version, makeWrapper, jre_headless, utillinux }:
with stdenv.lib; with stdenv.lib;
@ -17,8 +17,7 @@ stdenv.mkDerivation rec {
sed -i "s|ES_CLASSPATH=\"\$ES_HOME/lib/\*\"|ES_CLASSPATH=\"$out/lib/*\"|" ./bin/elasticsearch-env sed -i "s|ES_CLASSPATH=\"\$ES_HOME/lib/\*\"|ES_CLASSPATH=\"$out/lib/*\"|" ./bin/elasticsearch-env
''; '';
buildInputs = [ makeWrapper jre_headless ] ++ buildInputs = [ makeWrapper jre_headless utillinux ];
(if (!stdenv.isDarwin) then [utillinux] else [getopt]);
installPhase = '' installPhase = ''
mkdir -p $out mkdir -p $out
@ -27,9 +26,7 @@ stdenv.mkDerivation rec {
chmod -x $out/bin/*.* chmod -x $out/bin/*.*
wrapProgram $out/bin/elasticsearch \ wrapProgram $out/bin/elasticsearch \
${if (!stdenv.isDarwin) --prefix PATH : "${utillinux}/bin/" \
then ''--prefix PATH : "${utillinux}/bin/"''
else ''--prefix PATH : "${getopt}/bin"''} \
--set JAVA_HOME "${jre_headless}" \ --set JAVA_HOME "${jre_headless}" \
--set ES_JVM_OPTIONS "$out/config/jvm.options" --set ES_JVM_OPTIONS "$out/config/jvm.options"

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, makeWrapper, jre, utillinux, getopt }: { stdenv, fetchurl, makeWrapper, jre, utillinux }:
with stdenv.lib; with stdenv.lib;
@ -12,8 +12,7 @@ stdenv.mkDerivation rec {
patches = [ ./es-home.patch ]; patches = [ ./es-home.patch ];
buildInputs = [ makeWrapper jre ] ++ buildInputs = [ makeWrapper jre utillinux ];
(if (!stdenv.isDarwin) then [utillinux] else [getopt]);
installPhase = '' installPhase = ''
mkdir -p $out mkdir -p $out
@ -25,9 +24,7 @@ stdenv.mkDerivation rec {
# set ES_CLASSPATH and JAVA_HOME # set ES_CLASSPATH and JAVA_HOME
wrapProgram $out/bin/elasticsearch \ wrapProgram $out/bin/elasticsearch \
--prefix ES_CLASSPATH : "$out/lib/${name}.jar":"$out/lib/*":"$out/lib/sigar/*" \ --prefix ES_CLASSPATH : "$out/lib/${name}.jar":"$out/lib/*":"$out/lib/sigar/*" \
${if (!stdenv.isDarwin) --prefix PATH : "${utillinux}/bin" \
then ''--prefix PATH : "${utillinux}/bin/"''
else ''--prefix PATH : "${getopt}/bin"''} \
--set JAVA_HOME "${jre}" --set JAVA_HOME "${jre}"
wrapProgram $out/bin/elasticsearch-plugin \ wrapProgram $out/bin/elasticsearch-plugin \
--prefix ES_CLASSPATH : "$out/lib/${name}.jar":"$out/lib/*":"$out/lib/sigar/*" \ --prefix ES_CLASSPATH : "$out/lib/${name}.jar":"$out/lib/*":"$out/lib/sigar/*" \

View file

@ -7656,9 +7656,6 @@ with pkgs;
csmith = callPackage ../development/tools/misc/csmith { csmith = callPackage ../development/tools/misc/csmith {
inherit (perlPackages) perl SysCPU; inherit (perlPackages) perl SysCPU;
# Workaround optional dependency on libbsd that's
# currently broken on Darwin.
libbsd = if stdenv.isDarwin then null else libbsd;
}; };
csslint = callPackage ../development/web/csslint { }; csslint = callPackage ../development/web/csslint { };

View file

@ -45,7 +45,7 @@ in rec {
}; };
getopt = singleBinary "getopt" { getopt = singleBinary "getopt" {
linux = pkgs.utillinux; linux = pkgs.utillinux;
darwin = pkgs.darwin.shell_cmds; darwin = pkgs.getopt;
}; };
hexdump = singleBinary "hexdump" { hexdump = singleBinary "hexdump" {
linux = pkgs.procps; linux = pkgs.procps;
@ -67,7 +67,7 @@ in rec {
}; };
more = singleBinary "more" { more = singleBinary "more" {
linux = pkgs.utillinux; linux = pkgs.utillinux;
darwin = pkgs.more_compat; darwin = more_compat;
}; };
mount = singleBinary "mount" { mount = singleBinary "mount" {
linux = pkgs.utillinux; linux = pkgs.utillinux;