commit:     7b74219e5e8fefbb3d2391732633efb3cfe25cc4
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Oct 27 04:51:47 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Oct 27 05:07:23 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7b74219e

app-text/libpaper: add 2.0.1

Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-text/libpaper/Manifest              |  1 +
 app-text/libpaper/libpaper-2.0.1.ebuild | 34 +++++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)

diff --git a/app-text/libpaper/Manifest b/app-text/libpaper/Manifest
index c674e98ddf2d..b96196522fb3 100644
--- a/app-text/libpaper/Manifest
+++ b/app-text/libpaper/Manifest
@@ -1,2 +1,3 @@
 DIST libpaper-2.0.0.tar.gz 1221217 BLAKE2B 
ef2c08ff7dc537734d080a29560a711b196b05a3b0c4b375c8dc73d4dd9588156d325d233e27940fac96a18dfa6bf523128b53eb4c7098e561aa6054efb88408
 SHA512 
ca5c79969a8c5d56322a6993917d5aa47089bb396a144edd0d9040b0bdde78c8fb59468a3d4063ae1fb323a1b23fb28169616d153de65f9085351b9c9d47f8c0
+DIST libpaper-2.0.1.tar.gz 1229250 BLAKE2B 
67730d6783d8ab9c2f837f8f477ab8ea04be7df2b2f419e81d57834c86bfcdd373ecc29cbea51fee06ca102ea12c18646f96caafe7b7cc53580153d01873a329
 SHA512 
ccc77e2f7805e7e5f6b3e96acffa9aeb2854a21acbdbb40947251a6a8dca6f9d97db0c8e2859d2056d3b60b06200ef50d9cccae58f961ff77f234ad1ab3c32dc
 DIST libpaper_1.1.28.tar.gz 42356 BLAKE2B 
48c4a28c6ff01bd91e257b6b306e787e5c6112052cff09bdb501d1cc4ddd10964c3588942098a6092d5a44391dfb22e10d5147d4c5012497f473473129ff7422
 SHA512 
3bf6ebb0af89931d2f72ea4a09a7fa958b2facda5f238983ec7bac39652e08614b33f0de3af74a03457b2a4203eee4950bf18a4b726e79aa64093ace6a1fb0bc

diff --git a/app-text/libpaper/libpaper-2.0.1.ebuild 
b/app-text/libpaper/libpaper-2.0.1.ebuild
new file mode 100644
index 000000000000..783a81dd4d19
--- /dev/null
+++ b/app-text/libpaper/libpaper-2.0.1.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DESCRIPTION="Library for handling paper characteristics"
+HOMEPAGE="https://github.com/rrthomas/libpaper";
+SRC_URI="https://github.com/rrthomas/libpaper/releases/download/v${PV}/${P}.tar.gz";
+
+# See README.
+# paperspecs is public-domain
+LICENSE="LGPL-2.1+ GPL-2 public-domain"
+SLOT="0/$(ver_cut 1)"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 
~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos 
~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+
+src_configure() {
+       econf --enable-relocatable
+}
+
+src_install() {
+       default
+
+       find "${ED}" -type f -name '*.la' -delete || die
+
+       dodir /etc
+       (paperconf 2>/dev/null || echo a4) > "${ED}"/etc/papersize \
+               || die "papersize config failed"
+}
+
+pkg_postinst() {
+       if [[ -z ${REPLACING_VERSIONS} ]] ; then
+               elog "Run e.g. \"paperconfig -p letter\" as root to use 
letter-pagesizes"
+       fi
+}

Reply via email to