Gentoo Archives: gentoo-commits

From: "Justin Lecher (jlec)" <jlec@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-office/scribus: scribus-9999.ebuild scribus-1.5.0-r1.ebuild ChangeLog
Date: Fri, 29 May 2015 09:37:25
Message-Id: 20150529093712.2C910A09@oystercatcher.gentoo.org
1 jlec 15/05/29 09:37:12
2
3 Modified: scribus-9999.ebuild ChangeLog
4 Added: scribus-1.5.0-r1.ebuild
5 Log:
6 Enhance fPIC patch and fix configure options with USE=osg, bug #550130
7
8 (Portage version: 2.2.20/cvs/Linux x86_64, signed Manifest commit with key E9402A79B03529A2!)
9
10 Revision Changes Path
11 1.16 app-office/scribus/scribus-9999.ebuild
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/scribus-9999.ebuild?rev=1.16&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/scribus-9999.ebuild?rev=1.16&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/scribus-9999.ebuild?r1=1.15&r2=1.16
16
17 Index: scribus-9999.ebuild
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/app-office/scribus/scribus-9999.ebuild,v
20 retrieving revision 1.15
21 retrieving revision 1.16
22 diff -u -r1.15 -r1.16
23 --- scribus-9999.ebuild 21 May 2015 12:12:02 -0000 1.15
24 +++ scribus-9999.ebuild 29 May 2015 09:37:12 -0000 1.16
25 @@ -1,6 +1,6 @@
26 # Copyright 1999-2015 Gentoo Foundation
27 # Distributed under the terms of the GNU General Public License v2
28 -# $Header: /var/cvsroot/gentoo-x86/app-office/scribus/scribus-9999.ebuild,v 1.15 2015/05/21 12:12:02 jlec Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/app-office/scribus/scribus-9999.ebuild,v 1.16 2015/05/29 09:37:12 jlec Exp $
30
31 EAPI=5
32
33 @@ -130,7 +130,7 @@
34 $(cmake-utils_use_with pdf PODOFO)
35 $(cmake-utils_use_with boost)
36 $(cmake-utils_use_want graphicsmagick)
37 - $(cmake-utils_use_want osg)
38 + $(cmake-utils_use !osg WANT_NOOSG)
39 $(cmake-utils_use_want debug DEBUG)
40 $(cmake-utils_use_want minimal NOHEADERINSTALL)
41 $(cmake-utils_use_want hunspell HUNSPELL)
42
43
44
45 1.210 app-office/scribus/ChangeLog
46
47 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/ChangeLog?rev=1.210&view=markup
48 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/ChangeLog?rev=1.210&content-type=text/plain
49 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/ChangeLog?r1=1.209&r2=1.210
50
51 Index: ChangeLog
52 ===================================================================
53 RCS file: /var/cvsroot/gentoo-x86/app-office/scribus/ChangeLog,v
54 retrieving revision 1.209
55 retrieving revision 1.210
56 diff -u -r1.209 -r1.210
57 --- ChangeLog 29 May 2015 07:51:48 -0000 1.209
58 +++ ChangeLog 29 May 2015 09:37:12 -0000 1.210
59 @@ -1,6 +1,12 @@
60 # ChangeLog for app-office/scribus
61 # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
62 -# $Header: /var/cvsroot/gentoo-x86/app-office/scribus/ChangeLog,v 1.209 2015/05/29 07:51:48 jlec Exp $
63 +# $Header: /var/cvsroot/gentoo-x86/app-office/scribus/ChangeLog,v 1.210 2015/05/29 09:37:12 jlec Exp $
64 +
65 +*scribus-1.5.0-r1 (29 May 2015)
66 +
67 + 29 May 2015; Justin Lecher <jlec@g.o> +scribus-1.5.0-r1.ebuild,
68 + files/scribus-1.5.0-fpic.patch, scribus-9999.ebuild:
69 + Enhance fPIC patch and fix configure options with USE=osg, bug #550130
70
71 29 May 2015; Justin Lecher <jlec@g.o> scribus-1.4.5-r1.ebuild:
72 Always install en localisation, bug #549876
73
74
75
76 1.1 app-office/scribus/scribus-1.5.0-r1.ebuild
77
78 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/scribus-1.5.0-r1.ebuild?rev=1.1&view=markup
79 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-office/scribus/scribus-1.5.0-r1.ebuild?rev=1.1&content-type=text/plain
80
81 Index: scribus-1.5.0-r1.ebuild
82 ===================================================================
83 # Copyright 1999-2015 Gentoo Foundation
84 # Distributed under the terms of the GNU General Public License v2
85 # $Header: /var/cvsroot/gentoo-x86/app-office/scribus/scribus-1.5.0-r1.ebuild,v 1.1 2015/05/29 09:37:12 jlec Exp $
86
87 EAPI=5
88
89 PYTHON_COMPAT=( python2_7 )
90 PYTHON_REQ_USE="tk?"
91
92 inherit cmake-utils fdo-mime flag-o-matic multilib python-single-r1
93
94 DESCRIPTION="Desktop publishing (DTP) and layout program"
95 HOMEPAGE="http://www.scribus.net/"
96 SRC_URI="mirror://sourceforge/project/${PN}/${PN}-devel/${PV}/${P}.tar.xz"
97
98 LICENSE="GPL-2"
99 SLOT="0"
100 KEYWORDS="~amd64 ~x86"
101 IUSE="+boost debug examples graphicsmagick hunspell +minimal osg +pdf scripts templates tk"
102
103 #a=$((ls resources/translations/scribus.*ts | sed -e 's:\.: :g' | awk '{print $2}'; ls resources/loremipsum/*xml | sed -e 's:\.: :g' -e 's:loremipsum\/: :g'| awk '{print $2}'; ls resources/dicts/hyph*dic | sed -e 's:\.: :g' -e 's:hyph_: :g' | awk '{print $2}'; ls resources/dicts/README_*txt | sed -e 's:_hyph::g' -e 's:\.: :g' -e 's:README_: :g' | awk '{print $2}') | sort | uniq); echo $a
104 IUSE_LINGUAS=" af ar bg br ca ca_ES cs cs_CZ cy cy_GB da da_DK de de_1901 de_CH de_DE el en_AU en_EN en_GB en_US eo es es_ES et eu fi fi_FI fr gl he hr hu hu_HU ia id id_ID is is_IS it ja ko ku la lt lt_LT nb_NO nl nn_NO pl pl_PL pt pt_BR pt_PT ro ro_RO ru ru_RU_0 sa sk sk_SK sl sl_SI sq sr sv sv_SE th_TH tr uk uk_UA zh_CN zh_TW"
105 IUSE+=" ${IUSE_LINGUAS// / linguas_}"
106
107 REQUIRED_USE="
108 ${PYTHON_REQUIRED_USE}
109 tk? ( scripts )"
110
111 # osg
112 # couple of third_party libs bundled
113 COMMON_DEPEND="
114 ${PYTHON_DEPS}
115 app-text/libmspub
116 >=app-text/poppler-0.19.0:=
117 dev-libs/boost
118 dev-libs/hyphen
119 dev-libs/librevenge
120 dev-libs/libxml2
121 dev-qt/linguist:5
122 dev-qt/linguist-tools:5
123 dev-qt/qtcore:5
124 dev-qt/qtgui:5
125 dev-qt/qtnetwork:5
126 dev-qt/qtopengl:5
127 dev-qt/qtprintsupport:5
128 dev-qt/qtquickcontrols:5
129 dev-qt/qtwebkit:5
130 dev-qt/qtwidgets:5
131 dev-qt/qtxml:5
132 media-libs/fontconfig
133 media-libs/freetype:2
134 media-libs/lcms:2
135 media-libs/libcdr
136 media-libs/libpagemaker
137 media-libs/libpng:0
138 media-libs/libvisio
139 media-libs/tiff:0
140 net-print/cups
141 sys-libs/zlib[minizip]
142 virtual/jpeg:0=
143 >=x11-libs/cairo-1.10.0[X,svg]
144 boost? ( dev-libs/boost )
145 hunspell? ( app-text/hunspell )
146 graphicsmagick? ( media-gfx/graphicsmagick )
147 osg? ( dev-games/openscenegraph )
148 pdf? ( app-text/podofo )
149 scripts? ( virtual/python-imaging[tk?,${PYTHON_USEDEP}] )
150 tk? ( virtual/python-imaging[tk?,${PYTHON_USEDEP}] )
151 "
152 RDEPEND="${COMMON_DEPEND}
153 app-text/ghostscript-gpl"
154 DEPEND="${COMMON_DEPEND}
155 virtual/pkgconfig"
156
157 PATCHES=(
158 "${FILESDIR}"/${P}-docdir.patch
159 "${FILESDIR}"/${P}-fpic.patch
160 )
161
162 src_prepare() {
163 rm -r codegen/cheetah || die
164 cat > cmake/modules/FindZLIB.cmake <<- EOF
165 find_package(PkgConfig)
166 pkg_check_modules(ZLIB minizip zlib)
167 SET( ZLIB_LIBRARY \${ZLIB_LIBRARIES} )
168 SET( ZLIB_INCLUDE_DIR \${ZLIB_INCLUDE_DIRS} )
169 MARK_AS_ADVANCED( ZLIB_LIBRARY ZLIB_INCLUDE_DIR )
170 EOF
171
172 sed \
173 -e "/^\s*unzip\.[ch]/d" \
174 -e "/^\s*ioapi\.[ch]/d" \
175 -i scribus/CMakeLists.txt Scribus.pro || die
176 rm scribus/ioapi.[ch] || die
177
178 sed \
179 -e 's:\(${CMAKE_INSTALL_PREFIX}\):./\1:g' \
180 -i resources/templates/CMakeLists.txt || die
181
182 cmake-utils_src_prepare
183 }
184
185 src_configure() {
186 local lang langs
187 for lang in ${IUSE_LINGUAS}; do
188 if use linguas_${lang} || [[ ${lang} == "en" ]]; then
189 # From the CMakeLists.txt
190 # "#Bit of a hack, preprocess all the filenames to generate our language string, needed for -DWANT_GUI_LANG=en_GB;de_DE , etc"
191 langs+=";${lang}"
192 else
193 # Don't install localized documentation
194 sed -e "/${lang}/d" -i doc/CMakeLists.txt || die
195 safe_delete file ./resources/dicts/README_${lang}.txt
196 safe_delete file ./resources/dicts/README_hyph_${lang}.txt
197 safe_delete file ./resources/dicts/hyph_${lang}.dic
198 safe_delete file ./resources/loremipsum/${lang}.xml
199 fi
200 done
201
202 local mycmakeargs=(
203 -DHAVE_PYTHON=ON
204 -DPYTHON_INCLUDE_PATH="$(python_get_includedir)"
205 -DPYTHON_LIBRARY="$(python_get_library_path)"
206 -DWANT_DISTROBUILD=ON
207 -DDOCDIR="/usr/share/doc/${PF}/"
208 -DWANT_GUI_LANG="${langs#;};en"
209 $(cmake-utils_use_with pdf PODOFO)
210 $(cmake-utils_use_with boost)
211 $(cmake-utils_use_want graphicsmagick)
212 $(cmake-utils_use !osg WANT_NOOSG)
213 $(cmake-utils_use_want debug DEBUG)
214 $(cmake-utils_use_want minimal NOHEADERINSTALL)
215 $(cmake-utils_use_want hunspell HUNSPELL)
216 $(cmake-utils_use_want !examples NOEXAMPLES)
217 $(cmake-utils_use_want !templates NOTEMPLATES)
218 )
219 cmake-utils_src_configure
220 }
221
222 src_install() {
223 cmake-utils_src_install
224
225 local lang
226 for lang in ${IUSE_LINGUAS}; do
227 if ! use linguas_${lang}; then
228 safe_delete dir "${ED}"/usr/share/man/${lang}
229 fi
230 done
231
232 if ! use scripts; then
233 rm "${ED}"/usr/share/scribus/scripts/*.py || die
234 elif ! use tk; then
235 rm "${ED}"/usr/share/scribus/scripts/{FontSample,CalendarWizard}.py || die
236 fi
237
238 use scripts && \
239 python_fix_shebang "${ED}"/usr/share/scribus/scripts && \
240 python_optimize "${ED}"/usr/share/scribus/scripts
241
242 mv "${ED}"/usr/share/doc/${PF}/{en,html} || die
243 ln -sf html "${ED}"/usr/share/doc/${PF}/en || die
244 cat >> "${T}"/COPYING <<- EOF
245 ${PN} is licensed under the "${LICENSE}".
246 Please visit http://www.gnu.org/licenses/gpl-2.0.html for the complete license text.
247 EOF
248 dodoc "${T}"/COPYING
249 docompress -x /usr/share/doc/${PF}/en /usr/share/doc/${PF}/{AUTHORS,TRANSLATION,LINKS,COPYING}
250 doicon resources/icons/scribus.png
251 domenu scribus.desktop
252 }
253
254 pkg_postinst() {
255 fdo-mime_desktop_database_update
256 fdo-mime_mime_database_update
257 }
258
259 pkg_postrm() {
260 fdo-mime_desktop_database_update
261 fdo-mime_mime_database_update
262 }
263
264 safe_delete () {
265 case $1 in
266 dir)
267 if [[ -d "${2}" ]]; then
268 ebegin "Deleting ${2} recursively"
269 rm -r "${2}" || die
270 eend $?
271 fi
272 ;;
273 file)
274 if [[ -f "${2}" ]]; then
275 ebegin "Deleting ${2}"
276 rm "${2}" || die
277 eend $?
278 fi
279 ;;
280 *)
281 die "Wrong usage"
282 esac
283 }