dev-util/clair: 2.1.3 bump
[gentoo.git] / app-cdr / isomaster / isomaster-1.3.14.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
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-4.1:4
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}"/${P}-include-path.patch
25 )
26
27 pkg_setup() {
28         myisoconf=(
29                 DEFAULT_EDITOR=leafpad
30                 MYDOCPATH=/usr/share/doc/${PF}/bkisofs
31                 USE_SYSTEM_INIPARSER=1
32                 LIB_INIPARSER=iniparser4
33                 PREFIX=/usr
34                 )
35
36         use nls || myisoconf+=( WITHOUT_NLS=1 )
37 }
38
39 src_prepare() {
40         default
41         rm -f configure || die #274361
42         rm -R iniparser-4.1 || die
43 }
44
45 src_compile() {
46         tc-export CC
47         emake "${myisoconf[@]}"
48 }
49
50 _apply_linguas() {
51         mv "${D}"/usr/share/locale{,_ALL} || die
52         dodir /usr/share/locale
53         for lingua in ${LINGUAS}; do
54                 [[ -d "${D}"/usr/share/locale_ALL/${lingua} ]] || break
55                 mv "${D}"/usr/share/{locale_ALL/${lingua},locale/} || die
56         done
57         rm -R "${D}"/usr/share/locale_ALL || die
58 }
59
60 src_install() {
61         emake "${myisoconf[@]}" DESTDIR="${D}" install
62         dodoc {CHANGELOG,CREDITS,README,TODO}.TXT *.txt
63
64         use nls && _apply_linguas  # bug 402679, bug 512448
65 }
66
67 pkg_postinst() {
68         xdg_desktop_database_update
69 }
70
71 pkg_postrm() {
72         xdg_desktop_database_update
73 }