diff options
author | Alyssa Ross <hi@alyssa.is> | 2019-01-07 02:18:36 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2019-01-07 02:18:47 +0000 |
commit | 36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2 (patch) | |
tree | b3faaf573407b32aa645237a4d16b82778a39a92 /nixpkgs/pkgs/development/libraries/libpaper | |
parent | 4e31070265257dc67d120c27e0f75c2344fdfa9a (diff) | |
parent | abf060725d7614bd3b9f96764262dfbc2f9c2199 (diff) | |
download | nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.gz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.bz2 nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.lz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.xz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.zst nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.zip |
Add 'nixpkgs/' from commit 'abf060725d7614bd3b9f96764262dfbc2f9c2199'
git-subtree-dir: nixpkgs git-subtree-mainline: 4e31070265257dc67d120c27e0f75c2344fdfa9a git-subtree-split: abf060725d7614bd3b9f96764262dfbc2f9c2199
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/libpaper')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/libpaper/default.nix | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/libpaper/default.nix b/nixpkgs/pkgs/development/libraries/libpaper/default.nix new file mode 100644 index 000000000000..b4b72e5a36d3 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/libpaper/default.nix @@ -0,0 +1,37 @@ +{ stdenv, fetchurl }: + +stdenv.mkDerivation rec { + version = "1.1.24"; + name = "libpaper-${version}"; + + src = fetchurl { + url = "mirror://debian/pool/main/libp/libpaper/libpaper_${version}.tar.gz"; + sha256 = "0zhcx67afb6b5r936w5jmaydj3ks8zh83n9rm5sv3m3k8q8jib1q"; + }; + + # The configure script of libpaper is buggy: it uses AC_SUBST on a headerfile + # to compile sysconfdir into the library. Autoconf however defines sysconfdir + # as "${prefix}/etc", which is not expanded by AC_SUBST so libpaper will look + # for config files in (literally, without expansion) '${prefix}/etc'. Manually + # setting sysconfdir fixes this issue. + preConfigure = '' + configureFlagsArray+=( + "--sysconfdir=$out/etc" + ) + ''; + + # Set the default paper to letter (this is what libpaper uses as default as well, + # if you call getdefaultpapername()). + # The user can still override this with the PAPERCONF environment variable. + postInstall = '' + mkdir -p $out/etc + echo letter > $out/etc/papersize + ''; + + meta = { + description = "Library for handling paper characteristics"; + homepage = http://packages.debian.org/unstable/source/libpaper; + license = stdenv.lib.licenses.gpl2; + platforms = stdenv.lib.platforms.unix; + }; +} |