Gentoo Archives: gentoo-commits

From: Akinori Hattori <hattya@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/libsixel/files/, media-libs/libsixel/
Date: Fri, 01 Oct 2021 13:52:58
Message-Id: 1633096291.8990f8a32cf506e4d47ae6c365ab121227a925da.hattya@gentoo
1 commit: 8990f8a32cf506e4d47ae6c365ab121227a925da
2 Author: Akinori Hattori <hattya <AT> gentoo <DOT> org>
3 AuthorDate: Fri Oct 1 13:51:31 2021 +0000
4 Commit: Akinori Hattori <hattya <AT> gentoo <DOT> org>
5 CommitDate: Fri Oct 1 13:51:31 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8990f8a3
7
8 media-libs/libsixel: new upstream release
9
10 Bug: https://bugs.gentoo.org/717254
11 Package-Manager: Portage-3.0.20, Repoman-3.0.3
12 Signed-off-by: Akinori Hattori <hattya <AT> gentoo.org>
13
14 media-libs/libsixel/Manifest | 1 +
15 media-libs/libsixel/files/libsixel-meson.patch | 65 ++++++++++++++++++++
16 media-libs/libsixel/libsixel-1.10.3.ebuild | 85 ++++++++++++++++++++++++++
17 media-libs/libsixel/metadata.xml | 1 +
18 4 files changed, 152 insertions(+)
19
20 diff --git a/media-libs/libsixel/Manifest b/media-libs/libsixel/Manifest
21 index 0fae304e52a..de4f62e9023 100644
22 --- a/media-libs/libsixel/Manifest
23 +++ b/media-libs/libsixel/Manifest
24 @@ -1 +1,2 @@
25 +DIST libsixel-1.10.3.tar.gz 4272940 BLAKE2B f65d9a3bdd54917f5746b7b1650dfca7084c64b505ea9cae07863c476d1189114d9fb303ec01d8fa209542e891f1d359ec6dbdc9babc4313b06b709813fab020 SHA512 ef16f9ccecec8289728ec84ce9f24145648f8a38184c1ec3df8ead3499c6cf7d3e0a0c738f8bfcb1093e16ee8ae7ce5e46d3890707c8104752ce4ab7eb3bc7ac
26 DIST libsixel-1.8.6.tar.gz 4791628 BLAKE2B 5fa197d0d759eecd4040c4c1101e6d85fb9af7405ccdff75be571b3ac6b2b0aab6415bc3fdbb37157795f89190fcc1d0fea1bdf705e83a34762e2b05f5588c69 SHA512 460a5d46bada705b4a7ec2e250e2bde7f4b8ba155281fa5a102d1121f79c1c79145f042cd1f4bf93a2fc29e784e89afd539e963470663fc659d4fe72ea49fdaf
27
28 diff --git a/media-libs/libsixel/files/libsixel-meson.patch b/media-libs/libsixel/files/libsixel-meson.patch
29 new file mode 100644
30 index 00000000000..b912288e2e6
31 --- /dev/null
32 +++ b/media-libs/libsixel/files/libsixel-meson.patch
33 @@ -0,0 +1,65 @@
34 +--- a/meson.build
35 ++++ b/meson.build
36 +@@ -27,7 +27,7 @@
37 + #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
38 + __attribute__((deprecated)) void test(void) {}
39 + ''')
40 +- conf_data.set('HAVE_DIAGNOSTIC_DEPRECATED_DECLARATIONS', true)
41 ++ conf_data.set('HAVE_DIAGNOSTIC_DEPRECATED_DECLARATIONS', 1)
42 + endif
43 +
44 + c_args = [
45 +@@ -101,24 +101,24 @@
46 + python2_installation = pymod.find_installation('python2', required: get_option('python2'))
47 +
48 + if get_option('libcurl').enabled() and curl_found.found()
49 +- conf_data.set('HAVE_LIBCURL', true)
50 ++ conf_data.set('HAVE_LIBCURL', 1)
51 + libsixel_deps += [curl_found]
52 + endif
53 +
54 +-if get_option('jpeg').enabled() and jpeg_found
55 +- conf_data.set('HAVE_JPEG', true)
56 ++if get_option('jpeg').enabled() and jpeg_found.found()
57 ++ conf_data.set('HAVE_JPEG', 1)
58 + libsixel_deps += [jpeg_found]
59 + endif
60 +
61 +-if get_option('png').enabled() and png_found
62 +- conf_data.set('HAVE_PNG', true)
63 ++if get_option('png').enabled() and png_found.found()
64 ++ conf_data.set('HAVE_PNG', 1)
65 + libsixel_deps += [png_found]
66 + endif
67 +
68 + loaders = ['stb-image']
69 +
70 + if get_option('gd').enabled() and gd_found.found()
71 +- conf_data.set('HAVE_GD', true)
72 ++ conf_data.set('HAVE_GD', 1)
73 + libsixel_deps += [gd_found]
74 + loaders += ['gd']
75 +
76 +@@ -132,19 +132,19 @@
77 +
78 + foreach f : gd_funcs
79 + if cc.has_function(f, dependencies: gd_found)
80 +- conf_data.set('HAVE_DECL_@0@'.format(f.to_upper()), true)
81 ++ conf_data.set('HAVE_DECL_@0@'.format(f.to_upper()), 1)
82 + endif
83 + endforeach
84 + endif
85 +
86 + if get_option('gdk-pixbuf2').enabled() and gdkpixbuf2_found.found()
87 +- conf_data.set('HAVE_GDK_PIXBUF2', true)
88 ++ conf_data.set('HAVE_GDK_PIXBUF2', 1)
89 + libsixel_deps += [gdkpixbuf2_found]
90 + loaders += ['gdk-pixbuf2']
91 + endif
92 +
93 + if have_getopt_long
94 +- conf_data.set('HAVE_GETOPT_LONG', true)
95 ++ conf_data.set('HAVE_GETOPT_LONG', 1)
96 + endif
97 +
98 + configure_file(output: 'config.h', configuration: conf_data)
99
100 diff --git a/media-libs/libsixel/libsixel-1.10.3.ebuild b/media-libs/libsixel/libsixel-1.10.3.ebuild
101 new file mode 100644
102 index 00000000000..d9e158874cf
103 --- /dev/null
104 +++ b/media-libs/libsixel/libsixel-1.10.3.ebuild
105 @@ -0,0 +1,85 @@
106 +# Copyright 1999-2021 Gentoo Authors
107 +# Distributed under the terms of the GNU General Public License v2
108 +
109 +EAPI="8"
110 +PYTHON_COMPAT=( python3_{7..10} )
111 +DISTUTILS_OPTIONAL="1"
112 +
113 +inherit bash-completion-r1 distutils-r1 meson
114 +
115 +DESCRIPTION="A lightweight, fast implementation of DEC SIXEL graphics codec"
116 +HOMEPAGE="https://github.com/libsixel/libsixel"
117 +SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
118 +
119 +LICENSE="MIT public-domain"
120 +SLOT="0"
121 +KEYWORDS="~amd64 ~ia64 ~x86"
122 +IUSE="curl gd gtk jpeg png python test"
123 +RESTRICT="!test? ( test )"
124 +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
125 +
126 +RDEPEND="curl? ( net-misc/curl )
127 + gd? ( media-libs/gd )
128 + gtk? ( x11-libs/gdk-pixbuf:2 )
129 + jpeg? ( virtual/jpeg:0 )
130 + png? ( media-libs/libpng:0 )
131 + python? ( ${PYTHON_DEPS} )"
132 +DEPEND="${RDEPEND}"
133 +BDEPEND="python? (
134 + ${PYTHON_DEPS}
135 + dev-python/setuptools[${PYTHON_USEDEP}]
136 + )"
137 +
138 +PATCHES=( "${FILESDIR}"/${PN}-meson.patch )
139 +
140 +src_prepare() {
141 + default
142 + if use python; then
143 + cd python || die
144 + distutils-r1_src_prepare
145 + cd - >/dev/null || die
146 + fi
147 +}
148 +
149 +src_configure() {
150 + emesonargs=(
151 + $(meson_feature curl libcurl)
152 + $(meson_feature gd)
153 + $(meson_feature gtk gdk-pixbuf2)
154 + $(meson_feature jpeg)
155 + $(meson_feature png)
156 + $(meson_feature test tests)
157 + -Dbashcompletiondir="$(get_bashcompdir)"
158 + )
159 + meson_src_configure
160 + if use python; then
161 + cd python || die
162 + distutils-r1_src_configure
163 + cd - >/dev/null || die
164 + fi
165 +}
166 +
167 +src_compile() {
168 + meson_src_compile
169 + if use python; then
170 + cd python || die
171 + distutils-r1_src_compile
172 + cd - >/dev/null || die
173 + fi
174 +}
175 +
176 +src_install() {
177 + meson_src_install
178 +
179 + cd images || die
180 + docompress -x /usr/share/doc/${PF}/images
181 + docinto images
182 + dodoc egret.jpg map{8,16}.png snake.jpg vimperator3.png
183 + cd - >/dev/null || die
184 +
185 + if use python; then
186 + cd python || die
187 + distutils-r1_src_install
188 + cd - >/dev/null || die
189 + fi
190 +}
191
192 diff --git a/media-libs/libsixel/metadata.xml b/media-libs/libsixel/metadata.xml
193 index 457207a9bc1..3bd897a7c98 100644
194 --- a/media-libs/libsixel/metadata.xml
195 +++ b/media-libs/libsixel/metadata.xml
196 @@ -7,5 +7,6 @@
197 </maintainer>
198 <upstream>
199 <remote-id type="github">saitoha/libsixel</remote-id>
200 + <remote-id type="github">libsixel/libsixel</remote-id>
201 </upstream>
202 </pkgmetadata>