]> Pileus Git - ~andy/sunrise/blob - media-gfx/fim/fim-0.1_alpha.ebuild
media-gfx/fim: virtual/ghostscript->app-text/ghostscript-gpl: ghostscript-gpl is...
[~andy/sunrise] / media-gfx / fim / fim-0.1_alpha.ebuild
1 # Copyright 1999-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: $
4
5 inherit autotools
6
7 DESCRIPTION="Fbi IMproved is a framebuffer image viewer based on Fbi and inspired from Vim"
8 HOMEPAGE="http://savannah.nongnu.org/projects/fbi-improved"
9 SRC_URI="http://download.savannah.nongnu.org/releases/fbi-improved/${PN}-${PV/_/-}.tar.gz"
10
11 LICENSE="GPL-2"
12 SLOT="0"
13 KEYWORDS="~x86"
14
15 IUSE="debug gif jpeg png tiff postscript screen"
16
17 RDEPEND="gif? ( media-libs/giflib )
18         jpeg? ( >=media-libs/jpeg-6b )
19         png? ( media-libs/libpng )
20         tiff? ( media-libs/tiff )
21         postscript? ( app-text/ghostscript-gpl media-libs/tiff )
22         screen? ( app-misc/screen )
23         sys-libs/readline"
24
25 DEPEND="${RDEPEND}
26         sys-devel/flex
27         sys-devel/bison"
28
29 S=${WORKDIR}/${PN}-${PV/_/-}
30
31 src_unpack() {
32         unpack ${A}
33         cd "${S}"
34         eautoreconf
35 }
36
37 src_compile() {
38         econf \
39                 $(use_enable debug) \
40                 $(use_enable gif) \
41                 $(use_enable jpeg) \
42                 $(use_enable png) \
43                 $(use_enable tiff) \
44                 $(use_enable screen) \
45                 --enable-fimrc \
46                 --with-docdir="/usr/share/doc/${PF}"
47
48         # parallel make fails
49         emake -j1 || die "emake failed for ${P}"
50 }
51
52 src_install() {
53         emake DESTDIR="${D}" prefix=/usr install || die "make install failed"
54
55         if ! use postscript ; then
56                 rm -f "${D}"/usr/bin/fimgs.sh
57         else
58                 dosym /usr/bin/fimgs.sh /usr/bin/fimgs
59         fi
60 }