From 3ec5a9f36b37774542fd49a75649b32f6bf3c540 Mon Sep 17 00:00:00 2001 From: c0bw3b Date: Sat, 22 Jan 2022 18:50:40 +0100 Subject: [PATCH 1/6] lib.licenses: add Imlib2 --- lib/licenses.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/licenses.nix b/lib/licenses.nix index d305001a5c19..d07a6449b8fa 100644 --- a/lib/licenses.nix +++ b/lib/licenses.nix @@ -460,6 +460,11 @@ in mkLicense lset) ({ spdxId = "imagemagick"; }; + imlib2 = { + spdxId = "Imlib2"; + fullName = "Imlib2 License"; + }; + inria-compcert = { fullName = "INRIA Non-Commercial License Agreement for the CompCert verified compiler"; url = "https://compcert.org/doc/LICENSE.txt"; From f4d82e40e82a58b88b5b40ed9afaa5afb969ea59 Mon Sep 17 00:00:00 2001 From: c0bw3b Date: Sun, 23 Jan 2022 18:05:27 +0100 Subject: [PATCH 2/6] lib.licenses: add MIT-advertising --- lib/licenses.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/licenses.nix b/lib/licenses.nix index d07a6449b8fa..84e2a10bf320 100644 --- a/lib/licenses.nix +++ b/lib/licenses.nix @@ -592,6 +592,11 @@ in mkLicense lset) ({ fullName = "MIT License"; }; + mitAdvertising = { + spdxId = "MIT-advertising"; + fullName = "Enlightenment License (e16)"; + }; + mpl10 = { spdxId = "MPL-1.0"; fullName = "Mozilla Public License 1.0"; From 597f76f0bbfcfbb38c4ff8243c9dc6877d17c3d7 Mon Sep 17 00:00:00 2001 From: c0bw3b Date: Sat, 22 Jan 2022 18:51:55 +0100 Subject: [PATCH 3/6] imlib2: 1.7.3 -> 1.7.5 --- pkgs/development/libraries/imlib2/default.nix | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/pkgs/development/libraries/imlib2/default.nix b/pkgs/development/libraries/imlib2/default.nix index b61f4e442bf2..1447a327e0df 100644 --- a/pkgs/development/libraries/imlib2/default.nix +++ b/pkgs/development/libraries/imlib2/default.nix @@ -12,11 +12,11 @@ let in stdenv.mkDerivation rec { pname = "imlib2"; - version = "1.7.3"; + version = "1.7.5"; src = fetchurl { - url = "mirror://sourceforge/enlightenment/${pname}-${version}.tar.bz2"; - sha256 = "sha256-FY0LjCC8ESIa+ed6ZKEW/KcFGwPN6ixPMdMfRpOC+Zc="; + url = "mirror://sourceforge/enlightenment/${pname}-${version}.tar.xz"; + hash = "sha256-RY2DAKp6bUzjU1GDi7pdn9+wiES9WxU8WTjs/kP/Ngo="; }; buildInputs = [ @@ -28,11 +28,6 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; - preConfigure = '' - substituteInPlace imlib2-config.in \ - --replace "@my_libs@" "" - ''; - # Do not build amd64 assembly code on Darwin, because it fails to compile # with unknow directive errors configureFlags = optional stdenv.isDarwin "--enable-amd64=no" @@ -40,10 +35,6 @@ stdenv.mkDerivation rec { outputs = [ "bin" "out" "dev" ]; - postInstall = '' - moveToOutput bin/imlib2-config "$dev" - ''; - meta = with lib; { description = "Image manipulation library"; @@ -56,7 +47,8 @@ stdenv.mkDerivation rec { ''; homepage = "https://docs.enlightenment.org/api/imlib2/html"; - license = licenses.mit; + changelog = "https://git.enlightenment.org/legacy/imlib2.git/plain/ChangeLog?h=v${version}"; + license = licenses.imlib2; platforms = platforms.unix; maintainers = with maintainers; [ spwhitt ]; }; From ff517c4db75510b978d3d4cbcad2a700ce680af6 Mon Sep 17 00:00:00 2001 From: c0bw3b Date: Sat, 22 Jan 2022 18:54:31 +0100 Subject: [PATCH 4/6] imlibsetroot: adapt to Imlib2 v1.7.5 imlib2-config is gone imlibsetroot.c license header is actually MIT-advertising --- .../graphics/imlibsetroot/default.nix | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/graphics/imlibsetroot/default.nix b/pkgs/applications/graphics/imlibsetroot/default.nix index d3640a656f13..110a7e513e32 100644 --- a/pkgs/applications/graphics/imlibsetroot/default.nix +++ b/pkgs/applications/graphics/imlibsetroot/default.nix @@ -9,20 +9,27 @@ stdenv.mkDerivation { }; buildInputs = [ libX11 imlib2 libXinerama ]; + buildPhase = '' - gcc -g imlibsetroot.c -o imlibsetroot \ - `imlib2-config --cflags` `imlib2-config --libs` \ - -I/include/X11/extensions -lXinerama -lX11 + runHook preBuild + + gcc -g imlibsetroot.c -o imlibsetroot \ + -I${imlib2.dev}/include -L${imlib2}/lib -lImlib2 \ + -I${libX11.dev}/include -lXinerama -lX11 + + runHook postBuild ''; + installPhase = '' - mkdir -p $out/bin - install -m 755 imlibsetroot $out/bin + runHook preInstall + install -D -m 0755 imlibsetroot -t $out/bin + runHook postInstall ''; meta = with lib; { description = "A Xinerama Aware Background Changer"; homepage = "http://robotmonkeys.net/2010/03/30/imlibsetroot/"; - license = licenses.gpl2; + license = licenses.mitAdvertising; platforms = platforms.linux; maintainers = with maintainers; [ dwarfmaster ]; }; From 27314e17beb0bae912ae25918402f213e2b7f4b1 Mon Sep 17 00:00:00 2001 From: c0bw3b Date: Sun, 23 Jan 2022 18:45:14 +0100 Subject: [PATCH 5/6] scrot: 1.5 -> 1.7 Upstream says it's licensed under MIT-advertising --- pkgs/tools/graphics/scrot/default.nix | 34 +++++++++++++++++++++------ 1 file changed, 27 insertions(+), 7 deletions(-) diff --git a/pkgs/tools/graphics/scrot/default.nix b/pkgs/tools/graphics/scrot/default.nix index aa525abacb07..bb721ded43a3 100644 --- a/pkgs/tools/graphics/scrot/default.nix +++ b/pkgs/tools/graphics/scrot/default.nix @@ -1,25 +1,45 @@ -{ lib, stdenv, fetchFromGitHub, giblib, xlibsWrapper, autoreconfHook -, autoconf-archive, libXfixes, libXcursor, libXcomposite }: +{ lib +, stdenv +, fetchFromGitHub +, autoreconfHook +, autoconf-archive +, pkg-config +, imlib2 +, libbsd +, libXcomposite +, libXfixes +, xlibsWrapper +}: stdenv.mkDerivation rec { pname = "scrot"; - version = "1.5"; + version = "1.7"; src = fetchFromGitHub { owner = "resurrecting-open-source-projects"; repo = pname; rev = version; - sha256 = "sha256-4vguodLnCj0sOBLM4oJXTfX1p8hIo3WTwIuViPtZxHQ="; + hash = "sha256-oVmEPkEK1xDcIRUQjCp6CKf+aKnnVe3L7aRTdSsCmmY="; }; - nativeBuildInputs = [ autoreconfHook autoconf-archive ]; - buildInputs = [ giblib xlibsWrapper libXfixes libXcursor libXcomposite ]; + nativeBuildInputs = [ + autoreconfHook + autoconf-archive + pkg-config + ]; + buildInputs = [ + imlib2 + libbsd + libXcomposite + libXfixes + xlibsWrapper + ]; meta = with lib; { homepage = "https://github.com/resurrecting-open-source-projects/scrot"; description = "A command-line screen capture utility"; platforms = platforms.linux; maintainers = with maintainers; [ globin ]; - license = licenses.mit; + license = licenses.mitAdvertising; }; } From c182a39498e3b4c9c9a6442a627446f102836be6 Mon Sep 17 00:00:00 2001 From: c0bw3b Date: Sun, 23 Jan 2022 18:58:53 +0100 Subject: [PATCH 6/6] giblib: remove There is no upstream anymore and scrot now uses imlib2 directly --- pkgs/development/libraries/giblib/default.nix | 37 ------------------- pkgs/top-level/aliases.nix | 1 + pkgs/top-level/all-packages.nix | 2 - 3 files changed, 1 insertion(+), 39 deletions(-) delete mode 100644 pkgs/development/libraries/giblib/default.nix diff --git a/pkgs/development/libraries/giblib/default.nix b/pkgs/development/libraries/giblib/default.nix deleted file mode 100644 index ca4a3c98e0a6..000000000000 --- a/pkgs/development/libraries/giblib/default.nix +++ /dev/null @@ -1,37 +0,0 @@ -{ lib, stdenv, fetchurl, xlibsWrapper, imlib2 }: - -stdenv.mkDerivation rec { - pname = "giblib"; - version = "1.2.4"; - - src = fetchurl { - url = "http://linuxbrit.co.uk/downloads/giblib-${version}.tar.gz"; - sha256 = "1b4bmbmj52glq0s898lppkpzxlprq9aav49r06j2wx4dv3212rhp"; - }; - - outputs = [ "out" "dev" ]; - setOutputFlags = false; - - preConfigure = '' - configureFlagsArray+=( - --includedir=$dev/include - ) - ''; - - buildInputs = [ xlibsWrapper ]; - propagatedBuildInputs = [ imlib2 ]; - - postFixup = '' - moveToOutput bin/giblib-config "$dev" - - # Doesn't contain useful stuff - rm -rf $out/share/doc - ''; - - meta = { - homepage = "http://linuxbrit.co.uk/giblib/"; - description = "wrapper library for imlib2, and other stuff"; - platforms = lib.platforms.unix; - license = lib.licenses.mit; - }; -} diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 7ae975c5cbe7..c51aa2c48074 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -312,6 +312,7 @@ mapAliases ({ gdk_pixbuf = gdk-pixbuf; # added 2019-05-22 gettextWithExpat = gettext; # 2016-02-19 getmail = throw "getmail has been removed from nixpkgs, migrate to getmail6."; # added 2022-01-12 + giblib = throw " giblib has been removed from nixpkgs because upstream is gone."; # added 2022-01-23 giflib_4_1 = throw "giflib_4_1 has been removed; use giflib instead"; # 2020-02-12 git-bz = throw "giz-bz has been removed from nixpkgs as it is stuck on python2."; # added 2022-01-01 gitAndTools = self // { # added 2021-01-14 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 2b926da829ab..b00958d34a45 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -16579,8 +16579,6 @@ with pkgs; ggz_base_libs = callPackage ../development/libraries/ggz_base_libs {}; - giblib = callPackage ../development/libraries/giblib { }; - gifticlib = callPackage ../development/libraries/science/biology/gifticlib { }; gio-sharp = callPackage ../development/libraries/gio-sharp { };