Merge pull request #46910 from dtzWill/update/i7z-0.27.3
i7z: 0.27.2 -> 0.27.3, cleanup, various fixes, maintained fork, qt5
This commit is contained in:
commit
9114d13d00
@ -1,51 +1,55 @@
|
||||
{ stdenv, lib, fetchurl, ncurses
|
||||
, withGui ? false, qt4 ? null }:
|
||||
{ stdenv, lib, fetchFromGitHub, fetchpatch, ncurses
|
||||
, withGui ? false, qtbase }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "i7z-0.27.2";
|
||||
name = "i7z-${version}";
|
||||
version = "0.27.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/i7z/${name}.tar.gz";
|
||||
sha256 = "1wa7ix6m75wl3k2n88sz0x8cckvlzqklja2gvzqfw5rcfdjjvxx7";
|
||||
src = fetchFromGitHub {
|
||||
owner = "DimitryAndric";
|
||||
repo = "i7z";
|
||||
rev = "v${version}";
|
||||
sha256 = "0l8wz0ffb27nkwchc606js652spk8masy3kjmzh7ygipwsary5ds";
|
||||
};
|
||||
|
||||
buildInputs = [ ncurses ] ++ lib.optional withGui qt4;
|
||||
buildInputs = [ ncurses ] ++ lib.optional withGui qtbase;
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
url = "https://salsa.debian.org/debian/i7z/raw/ad1359764ee7a860a02e0c972f40339058fa9369/debian/patches/fix-insecure-tempfile.patch";
|
||||
sha256 = "0ifg06xjw14y4fnzzgkhqm4sv9mcdzgi8m2wffq9z8b1r0znya3s";
|
||||
})
|
||||
(fetchpatch {
|
||||
url = "https://salsa.debian.org/debian/i7z/raw/ad1359764ee7a860a02e0c972f40339058fa9369/debian/patches/nehalem.patch";
|
||||
sha256 = "1ys6sgm01jkqb6d4y7qc3h89dzph8jjjcfya5c5jcm7dkxlzjq8a";
|
||||
})
|
||||
(fetchpatch {
|
||||
url = "https://salsa.debian.org/debian/i7z/raw/ad1359764ee7a860a02e0c972f40339058fa9369/debian/patches/hyphen-used-as-minus-sign.patch";
|
||||
sha256 = "1ji2qvdyq0594cpqz0dlsfggvw3rm63sygh0jxvwjgxpnhykhg1p";
|
||||
})
|
||||
./qt5.patch
|
||||
];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
buildPhase = ''
|
||||
runHook preBuild
|
||||
|
||||
make
|
||||
${lib.optionalString withGui ''
|
||||
postBuild = lib.optionalString withGui ''
|
||||
cd GUI
|
||||
qmake
|
||||
make clean
|
||||
make
|
||||
cd ..
|
||||
''}
|
||||
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
makeFlags = [ "prefix=${placeholder "out"}" ];
|
||||
|
||||
mkdir -p $out/{bin,sbin}
|
||||
make install prefix=$out
|
||||
${lib.optionalString withGui ''
|
||||
install -Dm755 GUI/i7z_GUI $out/bin/i7z-gui
|
||||
''}
|
||||
mv $out/sbin/* $out/bin/
|
||||
rmdir $out/sbin
|
||||
|
||||
runHook postInstall
|
||||
postInstall = lib.optionalString withGui ''
|
||||
install -Dm755 GUI/i7z_GUI $out/bin/i7z-gui
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "A better i7 (and now i3, i5) reporting tool for Linux";
|
||||
homepage = https://github.com/ajaiantilal/i7z;
|
||||
repositories.git = https://github.com/ajaiantilal/i7z.git;
|
||||
homepage = https://github.com/DimitryAndric/i7z;
|
||||
repositories.git = https://github.com/DimitryAndric/i7z.git;
|
||||
license = licenses.gpl2;
|
||||
maintainers = with maintainers; [ bluescreen303 ];
|
||||
# broken on ARM
|
||||
|
13
pkgs/os-specific/linux/i7z/qt5.patch
Normal file
13
pkgs/os-specific/linux/i7z/qt5.patch
Normal file
@ -0,0 +1,13 @@
|
||||
diff -Naur a/GUI/i7z_GUI.pro b/GUI/i7z_GUI.pro
|
||||
--- a/GUI/i7z_GUI.pro 2013-10-12 21:59:19.000000000 +0100
|
||||
+++ b/GUI/i7z_GUI.pro 2016-11-05 13:54:30.118655672 +0000
|
||||
@@ -3,7 +3,8 @@
|
||||
######################################################################
|
||||
|
||||
TEMPLATE = app
|
||||
-TARGET =
|
||||
+TARGET = i7z_GUI
|
||||
+QT += widgets
|
||||
DEPENDPATH += .
|
||||
INCLUDEPATH += .
|
||||
CONFIG += debug
|
@ -13906,7 +13906,7 @@ with pkgs;
|
||||
|
||||
hwdata = callPackage ../os-specific/linux/hwdata { };
|
||||
|
||||
i7z = callPackage ../os-specific/linux/i7z { };
|
||||
i7z = qt5.callPackage ../os-specific/linux/i7z { };
|
||||
|
||||
pcm = callPackage ../os-specific/linux/pcm { };
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user