dev-util/clair: 2.1.3 bump
[gentoo.git] / app-cdr / isomaster / isomaster-1.3.13.ebuild
1 # Copyright 1999-2018 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 inherit toolchain-funcs xdg-utils
7
8 DESCRIPTION="Graphical CD image editor for reading, modifying and writing ISO images"
9 HOMEPAGE="http://littlesvr.ca/isomaster"
10 SRC_URI="http://littlesvr.ca/${PN}/releases/${P}.tar.bz2"
11
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS="amd64 x86"
15 IUSE="nls"
16
17 RDEPEND=">=dev-libs/iniparser-3.0.0:0
18         x11-libs/gtk+:2"
19 DEPEND="${RDEPEND}
20         virtual/pkgconfig
21         nls? ( >=sys-devel/gettext-0.19.1 )"  # bug 512448
22
23 PATCHES=(
24         "${FILESDIR}"/${PN}-1.3.9-iniparser-3.0.0.patch #399629
25 )
26
27 pkg_setup() {
28         myisoconf=(
29                 DEFAULT_EDITOR=leafpad
30                 MYDOCPATH=/usr/share/doc/${PF}/bkisofs
31                 USE_SYSTEM_INIPARSER=1
32                 PREFIX=/usr
33                 )
34
35         use nls || myisoconf+=( WITHOUT_NLS=1 )
36 }
37
38 src_prepare() {
39         default
40         rm -f configure || die #274361
41         rm -R iniparser-2.17 || die
42 }
43
44 src_compile() {
45         tc-export CC
46         emake "${myisoconf[@]}"
47 }
48
49 _apply_linguas() {
50         mv "${D}"/usr/share/locale{,_ALL} || die
51         dodir /usr/share/locale
52         for lingua in ${LINGUAS}; do
53                 [[ -d "${D}"/usr/share/locale_ALL/${lingua} ]] || break
54                 mv "${D}"/usr/share/{locale_ALL/${lingua},locale/} || die
55         done
56         rm -R "${D}"/usr/share/locale_ALL || die
57 }
58
59 src_install() {
60         emake "${myisoconf[@]}" DESTDIR="${D}" install
61         dodoc {CHANGELOG,CREDITS,README,TODO}.TXT *.txt
62
63         use nls && _apply_linguas  # bug 402679, bug 512448
64 }
65
66 pkg_postinst() {
67         xdg_desktop_database_update
68 }
69
70 pkg_postrm() {
71         xdg_desktop_database_update
72 }