mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 23:03:40 +01:00
fwupd: correct aarch64 support
This commit is contained in:
parent
6f86c002dd
commit
441f2525ba
1 changed files with 29 additions and 6 deletions
|
@ -17,6 +17,18 @@ let
|
|||
fontsConf = makeFontsConf {
|
||||
fontDirectories = [ freefont_ttf ];
|
||||
};
|
||||
|
||||
isx86 = stdenv.isx86_64 || stdenv.isi686;
|
||||
|
||||
# Dell isn't supported on Aarch64
|
||||
haveDell = isx86;
|
||||
|
||||
# only redfish for x86_64
|
||||
haveRedfish = stdenv.isx86_64;
|
||||
|
||||
# Currently broken on Aarch64
|
||||
haveFlashrom = isx86;
|
||||
|
||||
in stdenv.mkDerivation rec {
|
||||
pname = "fwupd";
|
||||
version = "1.2.8";
|
||||
|
@ -32,11 +44,12 @@ in stdenv.mkDerivation rec {
|
|||
meson ninja gtk-doc pkgconfig gobject-introspection intltool shared-mime-info
|
||||
valgrind gcab docbook_xml_dtd_43 docbook_xsl help2man libxslt python wrapGAppsHook vala
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
polkit libxmlb gusb sqlite libarchive libsoup elfutils libsmbios gnu-efi libyaml
|
||||
libgudev colord gpgme libuuid gnutls glib-networking efivar json-glib umockdev
|
||||
bash-completion cairo freetype fontconfig pango
|
||||
];
|
||||
polkit libxmlb gusb sqlite libarchive libsoup elfutils gnu-efi libyaml
|
||||
libgudev colord gpgme libuuid gnutls glib-networking json-glib umockdev
|
||||
bash-completion cairo freetype fontconfig pango efivar
|
||||
] ++ stdenv.lib.optionals haveDell [ libsmbios ];
|
||||
|
||||
patches = [
|
||||
./fix-paths.patch
|
||||
|
@ -71,11 +84,14 @@ in stdenv.mkDerivation rec {
|
|||
# /etc/os-release not available in sandbox
|
||||
# doCheck = true;
|
||||
|
||||
preFixup = ''
|
||||
preFixup = let
|
||||
binPath = [ efibootmgr bubblewrap tpm2-tools ] ++ stdenv.lib.optional haveFlashrom flashrom;
|
||||
in
|
||||
''
|
||||
gappsWrapperArgs+=(
|
||||
--prefix XDG_DATA_DIRS : "${shared-mime-info}/share"
|
||||
# See programs reached with fu_common_find_program_in_path in source
|
||||
--prefix PATH : "${stdenv.lib.makeBinPath [ flashrom efibootmgr bubblewrap tpm2-tools ]}"
|
||||
--prefix PATH : "${stdenv.lib.makeBinPath binPath}"
|
||||
)
|
||||
'';
|
||||
|
||||
|
@ -89,6 +105,13 @@ in stdenv.mkDerivation rec {
|
|||
"--localstatedir=/var"
|
||||
"--sysconfdir=/etc"
|
||||
"-Dsysconfdir_install=${placeholder "out"}/etc"
|
||||
] ++ stdenv.lib.optionals (!haveDell) [
|
||||
"-Dplugin_dell=false"
|
||||
"-Dplugin_synaptics=false"
|
||||
] ++ stdenv.lib.optionals (!haveRedfish) [
|
||||
"-Dplugin_redfish=false"
|
||||
] ++ stdenv.lib.optionals (!haveFlashrom) [
|
||||
"-Dplugin_flashrom=false"
|
||||
];
|
||||
|
||||
# TODO: We need to be able to override the directory flags from meson setup hook
|
||||
|
|
Loading…
Reference in a new issue