mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
sbsigntool: Fix cross-compilation
```
> Running phase: configurePhase
> substituteStream() in derivation sbsigntool-aarch64-unknown-linux-gnu-0.9.5: WARNING: '--replace' is deprecated, use --replace-{fail,warn,quiet}. (file 'configure.ac')
> lib/ccan.git/tools/create-ccan-tree: line 21: getopt: command not found
> Usage: create-ccan-tree [options] <outdir> <depends>...
>
> options:
> -a, --copy-all copy all files in module tree (not just sources
> required for build)
> -b, --build-type=TYPE generate build infrastructure of TYPE
> (one of 'make', 'make+config', 'automake', 'waf')
For full logs, run:
```
is the error before the changes to address the cross-compilation issues.
This commit is contained in:
parent
19a053f28c
commit
abfe15ab4e
1 changed files with 15 additions and 10 deletions
|
|
@ -10,6 +10,11 @@
|
|||
libuuid,
|
||||
gnu-efi,
|
||||
libbfd,
|
||||
util-linux,
|
||||
buildPackages,
|
||||
deterministic-host-uname,
|
||||
# help2man runs host executables
|
||||
withMan ? stdenv.buildPlatform.canExecute stdenv.hostPlatform,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
|
|
@ -31,6 +36,8 @@ stdenv.mkDerivation (finalAttrs: {
|
|||
automake
|
||||
pkg-config
|
||||
help2man
|
||||
util-linux # for getopt used by create-ccan-tree
|
||||
deterministic-host-uname # build system incorrectly uses uname to determine host CPU
|
||||
];
|
||||
buildInputs = [
|
||||
openssl
|
||||
|
|
@ -39,27 +46,25 @@ stdenv.mkDerivation (finalAttrs: {
|
|||
gnu-efi
|
||||
];
|
||||
|
||||
configurePhase = ''
|
||||
runHook preConfigure
|
||||
preConfigure = ''
|
||||
substituteInPlace configure.ac --replace-fail "@@NIX_GNUEFI@@" "${gnu-efi}"
|
||||
|
||||
substituteInPlace configure.ac --replace "@@NIX_GNUEFI@@" "${gnu-efi}"
|
||||
|
||||
lib/ccan.git/tools/create-ccan-tree --build-type=automake lib/ccan "talloc read_write_all build_assert array_size endian"
|
||||
CC=${lib.getExe buildPackages.stdenv.cc} lib/ccan.git/tools/create-ccan-tree --build-type=automake lib/ccan "talloc read_write_all build_assert array_size endian"
|
||||
touch AUTHORS
|
||||
touch ChangeLog
|
||||
|
||||
echo "SUBDIRS = lib/ccan src docs" >> Makefile.am
|
||||
echo "SUBDIRS = lib/ccan src ${lib.optionalString withMan "docs"}" > Makefile.am
|
||||
|
||||
aclocal
|
||||
autoheader
|
||||
autoconf
|
||||
automake --add-missing -Wno-portability
|
||||
|
||||
./configure --prefix=$out
|
||||
|
||||
runHook postConfigure
|
||||
'';
|
||||
|
||||
makeFlags = [
|
||||
"AR=${stdenv.cc.targetPrefix}ar"
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "Tools for maintaining UEFI signature databases";
|
||||
homepage = "http://jk.ozlabs.org/docs/sbkeysync-maintaing-uefi-key-databases";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue