1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-21 13:10:33 +00:00

treewide: Depend on stdenv.cc.bintools instead of binutils directly

One should do this when needed executables at build time. It is more
honest and cross-friendly than refering to binutils directly.
This commit is contained in:
John Ericson 2017-10-10 19:01:42 -04:00
parent 5ae8f18f4d
commit 70d91badf5
8 changed files with 19 additions and 12 deletions

View file

@ -1,7 +1,7 @@
{ config, stdenv, fetchgit, makeWrapper, gnome3, at_spi2_core, libcxx,
boost, epoxy, cmake, aspell, llvmPackages, libgit2, pkgconfig, pcre,
libXdmcp, libxkbcommon, libpthreadstubs, wrapGAppsHook, aspellDicts,
coreutils, glibc, dbus_libs, openssl, libxml2, gnumake, binutils, ctags }:
coreutils, glibc, dbus_libs, openssl, libxml2, gnumake, ctags }:
with stdenv.lib;
@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
postInstall = ''
mv $out/bin/juci $out/bin/.juci
makeWrapper "$out/bin/.juci" "$out/bin/juci" \
--set PATH "${stdenv.lib.makeBinPath [ ctags coreutils llvmPackages.clang.cc cmake gnumake binutils llvmPackages.clang ]}" \
--set PATH "${stdenv.lib.makeBinPath [ ctags coreutils llvmPackages.clang.cc cmake gnumake llvmPackages.clang.bintools llvmPackages.clang ]}" \
--set NO_AT_BRIDGE 1 \
--set ASPELL_CONF "dict-dir ${aspellDicts.en}/lib/aspell"
'';

View file

@ -97,6 +97,11 @@ stdenv.mkDerivation {
outputs = [ "out" "man" ];
passthru = {
# "cc" is the generic name for a C compiler, but there is no one for package
# providing the linker and related tools. The two we use now are GNU
# Binutils, and Apple's "cctools"; "binutils" as an attempt to find an
# unused middle-ground name that evokes both.
bintools = binutils_bin;
inherit libc nativeTools nativeLibc nativePrefix isGNU isClang default_cxx_stdlib_compile
prefix;

View file

@ -1,5 +1,7 @@
{ fetchgit, pkgconfig, gettext, runCommand, makeWrapper
, elfutils, kernel, gnumake, python2, pythonPackages, binutils }:
, elfutils, kernel, gnumake, python2, pythonPackages
}:
let
## fetchgit info
url = git://sourceware.org/git/systemtap.git;
@ -55,5 +57,5 @@ in runCommand "systemtap-${kernel.version}-${version}" {
rm $out/bin/stap
makeWrapper $stapBuild/bin/stap $out/bin/stap \
--add-flags "-r $kernelBuildDir" \
--prefix PATH : ${lib.makeBinPath [ stdenv.cc.cc binutils elfutils gnumake ]}
--prefix PATH : ${lib.makeBinPath [ stdenv.cc.cc stdenv.cc.bintools elfutils gnumake ]}
''

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, SDL, ncurses, libtcod, binutils }:
{ stdenv, fetchurl, SDL, ncurses, libtcod }:
stdenv.mkDerivation rec {
name = "brogue-${version}";

View file

@ -1,4 +1,4 @@
{ stdenv, steamArch, fetchurl, writeText, python2, dpkg, binutils }:
{ stdenv, steamArch, fetchurl, writeText, python2, dpkg }:
let input = builtins.getAttr steamArch (import ./runtime-generated.nix { inherit fetchurl; });
@ -7,7 +7,7 @@ let input = builtins.getAttr steamArch (import ./runtime-generated.nix { inherit
in stdenv.mkDerivation {
name = "steam-runtime-2016-08-13";
nativeBuildInputs = [ python2 dpkg binutils ];
nativeBuildInputs = [ python2 dpkg stdenv.cc.bintools ];
buildCommand = ''
mkdir -p $out

View file

@ -1,6 +1,6 @@
{ stdenv, pkgs, lib, fetchurl, fetchgit, fetchsvn, fetchpatch,
jansson, libxml2, libxslt, ncurses, openssl, sqlite,
utillinux, dmidecode, libuuid, binutils, newt,
utillinux, dmidecode, libuuid, newt,
lua, speex,
srtp, wget, curl
}:
@ -10,7 +10,7 @@ let
inherit version;
name = "asterisk-${version}";
buildInputs = [ jansson libxml2 libxslt ncurses openssl sqlite utillinux dmidecode libuuid binutils newt lua speex srtp wget curl ];
buildInputs = [ jansson libxml2 libxslt ncurses openssl sqlite utillinux dmidecode libuuid newt lua speex srtp wget curl ];
patches = [
# We want the Makefile to install the default /var skeleton

View file

@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
makeFlags = [
"INSTALL=install"
"STRIP=strip"
"STRIP=${stdenv.cc.bintools.prefix}strip"
"prefix=$(out)"
];

View file

@ -13,8 +13,8 @@ stdenv.mkDerivation {
sha256 = "1zvadgsskmpm82id9mbj24a2lyq38qv768ixv7nmfjl3d4wr2biv";
};
nativeBuildInputs = [ bison binutils gettext pkgconfig ];
buildInputs = [ glib gnutls gtk2 libxml2 zlib ];
nativeBuildInputs = [ bison gettext pkgconfig ];
buildInputs = [ binutils glib gnutls gtk2 libxml2 zlib ];
hardeningDisable = [ "bindnow" "fortify" "pic" "relro" ];