From 1a4515e518b9a52da9ae183d3a00efb983d248b9 Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sun, 17 Dec 2017 09:16:38 +0100 Subject: [PATCH] =?UTF-8?q?fwupd:=201.0.1=20=E2=86=92=201.0.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../linux/firmware/fwupd/default.nix | 32 ++++++++----------- .../firmware/fwupd/fix-missing-deps.patch | 22 ++++++------- 2 files changed, 25 insertions(+), 29 deletions(-) diff --git a/pkgs/os-specific/linux/firmware/fwupd/default.nix b/pkgs/os-specific/linux/firmware/fwupd/default.nix index 9deca1faa6a0f..cf2216d391619 100644 --- a/pkgs/os-specific/linux/firmware/fwupd/default.nix +++ b/pkgs/os-specific/linux/firmware/fwupd/default.nix @@ -1,16 +1,18 @@ -{ stdenv, fetchurl, gtk_doc, pkgconfig, gobjectIntrospection, intltool +{ stdenv, fetchFromGitHub, gtk_doc, pkgconfig, gobjectIntrospection, intltool , libgudev, polkit, appstream-glib, gusb, sqlite, libarchive, glib_networking , libsoup, docbook2x, gpgme, libxslt, libelf, libsmbios, efivar, glibcLocales , fwupdate, libyaml, valgrind, meson, libuuid, pygobject3, colord , pillow, ninja, gcab, gnutls, python3Packages, wrapGAppsHook }: let - version = "1.0.2"; + version = "1.0.3"; in stdenv.mkDerivation { name = "fwupd-${version}"; - src = fetchurl { - url = "https://people.freedesktop.org/~hughsient/releases/fwupd-${version}.tar.xz"; - sha256 = "15hrl6jq2kyvbxgjkv3qafqj2962il27gryakm39kvz2p2l1bacj"; + src = fetchFromGitHub { + owner = "hughsie"; + repo = "fwupd"; + rev = version; + sha256 = "0vg9f1gzcvfd7jnfhvv0ylf04fy7cw31ykrim7qik6gbkhr4gr65"; }; nativeBuildInputs = [ @@ -19,17 +21,11 @@ in stdenv.mkDerivation { ]; buildInputs = [ polkit appstream-glib gusb sqlite libarchive libsoup libelf libsmbios fwupdate libyaml - libgudev colord gpgme libuuid pillow gnutls glib_networking + libgudev colord gpgme libuuid pillow gnutls glib_networking efivar ]; LC_ALL = "en_US.UTF-8"; # For po/make-images - NIX_CFLAGS_COMPILE = [ - "-I${efivar}/include/efivar" - # warning: "__LIBELF_INTERNAL__" is not defined - "-Wno-error=undef" - ]; - patches = [ ./fix-missing-deps.patch ]; @@ -38,12 +34,12 @@ in stdenv.mkDerivation { ''; mesonFlags = [ - "-Denable-man=false" - "-Denable-tests=false" - "-Denable-doc=false" - "-Dwith-bootdir=/boot" - "-Dwith-udevdir=lib/udev" - "-Dwith-systemdunitdir=lib/systemd/system" + "-Dman=false" + "-Dtests=false" + "-Dgtkdoc=false" + "-Dbootdir=/boot" + "-Dudevdir=lib/udev" + "-Dsystemdunitdir=lib/systemd/system" "--localstatedir=/var" ]; diff --git a/pkgs/os-specific/linux/firmware/fwupd/fix-missing-deps.patch b/pkgs/os-specific/linux/firmware/fwupd/fix-missing-deps.patch index 46e11952afe0a..d1d7c06027f9d 100644 --- a/pkgs/os-specific/linux/firmware/fwupd/fix-missing-deps.patch +++ b/pkgs/os-specific/linux/firmware/fwupd/fix-missing-deps.patch @@ -2,7 +2,7 @@ +++ b/data/builder/meson.build @@ -1,3 +0,0 @@ -install_data('README.md', -- install_dir : join_paths(get_option('localstatedir'), 'lib', 'fwupd', 'builder') +- install_dir : join_paths(localstatedir, 'lib', 'fwupd', 'builder') -) --- a/data/meson.build +++ b/data/meson.build @@ -11,15 +11,15 @@ endif -install_data(['daemon.conf'], -- install_dir : join_paths(get_option('sysconfdir'), 'fwupd') +- install_dir : join_paths(sysconfdir, 'fwupd') -) - install_data(['org.freedesktop.fwupd.metainfo.xml'], - install_dir: join_paths(get_option('datadir'), 'metainfo') + install_dir: join_paths(datadir, 'metainfo') ) install_data(['org.freedesktop.fwupd.conf'], -- install_dir : join_paths(get_option('sysconfdir'), 'dbus-1', 'system.d') +- install_dir : join_paths(sysconfdir, 'dbus-1', 'system.d') + install_dir : join_paths(get_option('prefix'), 'etc', 'dbus-1', 'system.d') ) @@ -30,14 +30,14 @@ 'GPG-KEY-Hughski-Limited', 'GPG-KEY-Linux-Vendor-Firmware-Service', ], -- install_dir : join_paths(get_option('sysconfdir'), 'pki', 'fwupd') +- install_dir : join_paths(sysconfdir, 'pki', 'fwupd') + install_dir : join_paths(get_option('prefix'), 'etc', 'pki', 'fwupd') ) install_data([ 'GPG-KEY-Linux-Vendor-Firmware-Service', ], -- install_dir : join_paths(get_option('sysconfdir'), 'pki', 'fwupd-metadata') +- install_dir : join_paths(sysconfdir, 'pki', 'fwupd-metadata') + install_dir : join_paths(get_option('prefix'), 'etc', 'pki', 'fwupd-metadata') ) endif @@ -46,13 +46,13 @@ install_data([ 'LVFS-CA.pem', ], -- install_dir : join_paths(get_option('sysconfdir'), 'pki', 'fwupd') +- install_dir : join_paths(sysconfdir, 'pki', 'fwupd') + install_dir : join_paths(get_option('prefix'), 'etc', 'pki', 'fwupd') ) install_data([ 'LVFS-CA.pem', ], -- install_dir : join_paths(get_option('sysconfdir'), 'pki', 'fwupd-metadata') +- install_dir : join_paths(sysconfdir, 'pki', 'fwupd-metadata') + install_dir : join_paths(get_option('prefix'), 'etc', 'pki', 'fwupd-metadata') ) endif @@ -63,7 +63,7 @@ 'lvfs.conf', 'lvfs-testing.conf', ], -- install_dir : join_paths(get_option('sysconfdir'), 'fwupd', 'remotes.d') +- install_dir : join_paths(sysconfdir, 'fwupd', 'remotes.d') + install_dir : join_paths(get_option('prefix'), 'etc', 'fwupd', 'remotes.d') ) endif @@ -72,7 +72,7 @@ output : 'fwupd.conf', configuration : con2, install: true, -- install_dir: join_paths(get_option('sysconfdir'), 'fwupd', 'remotes.d'), +- install_dir: join_paths(sysconfdir, 'fwupd', 'remotes.d'), + install_dir: join_paths(get_option('prefix'), 'etc', 'fwupd', 'remotes.d'), ) configure_file( @@ -80,7 +80,7 @@ output : 'vendor.conf', configuration : con2, install: true, -- install_dir: join_paths(get_option('sysconfdir'), 'fwupd', 'remotes.d'), +- install_dir: join_paths(sysconfdir, 'fwupd', 'remotes.d'), + install_dir: join_paths(get_option('prefix'), 'etc', 'fwupd', 'remotes.d'), ) --- a/meson_post_install.sh