Skip to content

Commit

Permalink
libgourou: init at 0.8.1
Browse files Browse the repository at this point in the history
  • Loading branch information
sevenautumns committed Mar 22, 2023
1 parent 78cd6d9 commit 61a892c
Show file tree
Hide file tree
Showing 4 changed files with 95 additions and 0 deletions.
9 changes: 9 additions & 0 deletions maintainers/maintainer-list.nix
Expand Up @@ -1469,6 +1469,15 @@
githubId = 12958979;
name = "Mika Naylor";
};
autumnal = {
name = "Sven Friedrich";
email = "sven@autumnal.de";
github = "sevenautumns";
githubId = 20627275;
keys = [{
fingerprint = "6A2E 7FDD 1037 11A8 B996 E28E B051 064E 2FCA B71B";
}];
};
avakhrenev = {
email = "avakhrenev@gmail.com";
github = "avakhrenev";
Expand Down
48 changes: 48 additions & 0 deletions pkgs/development/libraries/libgourou/default.nix
@@ -0,0 +1,48 @@
{ lib, stdenv, fetchurl, pugixml, updfparser, curl, openssl, libzip, unzip }:

stdenv.mkDerivation rec {
name = "libgourou";
version = "0.8.1";

src = fetchurl {
url = "https://indefero.soutade.fr/p/${name}/source/download/v${version}/";
sha256 = "sha256-xBylQfVo6ARII02+YHWeTf3y+0SM2/hGfbg/Q0WiDe0=";
};

unpackCmd = "${unzip}/bin/unzip $curSrc";

postPatch = ''
patchShebangs scripts/setup.sh
'';

configurePhase = ''
mkdir lib
ln -s ${updfparser}/lib lib/updfparser
'';

buildInputs = [ pugixml updfparser curl openssl libzip ];

buildPhase = ''
make BUILD_STATIC=1 BUILD_SHARED=1
'';

installPhase = ''
runHook preInstall
install -Dt $out/include include/libgourou*.h
install -Dt $out/lib libgourou.so
install -Dt $out/lib libgourou.so.${version}
install -Dt $out/lib libgourou.a
install -Dt $out/bin utils/acsmdownloader
install -Dt $out/bin utils/adept_{activate,loan_mgt,remove}
runHook postInstall
'';

meta = with lib; {
description = "Implementation of Adobe's ADEPT protocol for ePub/PDF DRM";
homepage = "https://indefero.soutade.fr/p/libgourou";
license = licenses.lgpl3Plus;
maintainers = with maintainers; [ autumnal ];
platforms = platforms.all;
broken = stdenv.isDarwin;
};
}
34 changes: 34 additions & 0 deletions pkgs/development/libraries/updfparser/default.nix
@@ -0,0 +1,34 @@
{ lib, stdenv, fetchurl, unzip }:

stdenv.mkDerivation rec {
name = "updfparser";
version = "unstable-2023-01-10";
rev = "a421098";

src = fetchurl {
url = "https://indefero.soutade.fr/p/updfparser/source/download/${rev}/";
sha256 = "sha256-RkUQ9EdhXgGWjGS2y/EmjfN2WrgdtHz0GNz93u0LbX4=";
};

unpackCmd = "${unzip}/bin/unzip $curSrc";

buildPhase = ''
make BUILD_STATIC=1 BUILD_SHARED=1
'';

installPhase = ''
runHook preInstall
install -Dt $out/include include/*.h
install -Dt $out/lib libupdfparser.so
install -Dt $out/lib libupdfparser.a
runHook postInstall
'';

meta = with lib; {
description = "A very simple PDF parser";
homepage = "https://indefero.soutade.fr/p/updfparser";
license = licenses.lgpl3Plus;
maintainers = with maintainers; [ autumnal ];
platforms = platforms.all;
};
}
4 changes: 4 additions & 0 deletions pkgs/top-level/all-packages.nix
Expand Up @@ -21347,6 +21347,8 @@ with pkgs;

libgnurl = callPackage ../development/libraries/libgnurl { };

libgourou = callPackage ../development/libraries/libgourou { };

libgringotts = callPackage ../development/libraries/libgringotts { };

libgrss = callPackage ../development/libraries/libgrss {
Expand Down Expand Up @@ -23904,6 +23906,8 @@ with pkgs;

unicon-lang = callPackage ../development/interpreters/unicon-lang { };

updfparser = callPackage ../development/libraries/updfparser { };

tsocks = callPackage ../development/libraries/tsocks { };

unixODBC = callPackage ../development/libraries/unixODBC { };
Expand Down

0 comments on commit 61a892c

Please sign in to comment.