uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
88
pkgs/development/tools/abuild/default.nix
Normal file
88
pkgs/development/tools/abuild/default.nix
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitLab
|
||||
, makeWrapper
|
||||
, pkg-config
|
||||
, file
|
||||
, scdoc
|
||||
, openssl
|
||||
, zlib
|
||||
, busybox
|
||||
, apk-tools
|
||||
, perl
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "abuild";
|
||||
version = "3.9.0";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
domain = "gitlab.alpinelinux.org";
|
||||
owner = "alpine";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
sha256 = "1zs8slaqiv8q8bim8mwfy08ymar78rqpkgqksw8y1lsjrj49fqy4";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
openssl
|
||||
zlib
|
||||
busybox
|
||||
# for $out/bin/apkbuild-cpan and $out/bin/apkbuild-pypi
|
||||
(perl.withPackages (ps: with ps; [
|
||||
LWP
|
||||
JSON
|
||||
ModuleBuildTiny
|
||||
LWPProtocolHttps
|
||||
IPCSystemSimple
|
||||
]))
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
scdoc
|
||||
makeWrapper
|
||||
file
|
||||
];
|
||||
|
||||
patchPhase = ''
|
||||
substituteInPlace ./Makefile \
|
||||
--replace 'chmod 4555' '#chmod 4555'
|
||||
'';
|
||||
|
||||
makeFlags = [
|
||||
"prefix=${placeholder "out"}"
|
||||
"CFLAGS=-Wno-error"
|
||||
];
|
||||
|
||||
installFlags = [
|
||||
"sysconfdir=${placeholder "out"}/etc"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
# this script requires unpackaged 'augeas' rubygem, no reason
|
||||
# to ship it if we can't provide the dependencies for it
|
||||
rm -f ${placeholder "out"}/bin/apkbuild-gem-resolver
|
||||
|
||||
# Find all executables that are not compiled binaries and wrap
|
||||
# them, make `apk-tools` available in their PATH and also the
|
||||
# $out directory since many of the binaries provided call into
|
||||
# other binaries
|
||||
for prog in \
|
||||
$(find ${placeholder "out"}/bin -type f -exec ${file}/bin/file -i '{}' + \
|
||||
| grep -v x-executable | cut -d : -f1); do
|
||||
wrapProgram $prog \
|
||||
--prefix PATH : "${lib.makeBinPath [ apk-tools ]}" \
|
||||
--prefix PATH : "${placeholder "out"}/bin"
|
||||
done
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Alpine Linux build tools";
|
||||
homepage = "https://gitlab.alpinelinux.org/alpine/abuild";
|
||||
license = licenses.gpl2Plus;
|
||||
maintainers = with maintainers; [ onny ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue