/[gentoo-x86]/sys-libs/slang/slang-1.4.9-r2.ebuild
Gentoo

Contents of /sys-libs/slang/slang-1.4.9-r2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.21 - (show annotations) (download)
Sun Jun 15 09:52:57 2008 UTC (11 years, 7 months ago) by drac
Branch: MAIN
CVS Tags: HEAD
Changes since 1.20: +1 -1 lines
FILE REMOVED
old
(Portage version: 2.1.5.5)

1 # Copyright 1999-2008 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-libs/slang/slang-1.4.9-r2.ebuild,v 1.20 2008/02/09 06:38:09 drac Exp $
4
5 inherit eutils toolchain-funcs
6
7 # Patches are taken from http://www.suse.de/~nadvornik/slang/
8 # They were originally Red Hat and Debian's patches
9
10 DESCRIPTION="Console display library used by most text viewer"
11 HOMEPAGE="http://www.s-lang.org/"
12 SRC_URI="ftp://space.mit.edu/pub/davis/slang/v1.4/${P}.tar.bz2
13 mirror://gentoo/${P}-patches.tar.gz"
14
15 LICENSE="|| ( GPL-2 Artistic )"
16 SLOT="0"
17 KEYWORDS="alpha amd64 arm hppa ia64 mips ppc ppc64 s390 sh sparc ~sparc-fbsd x86 ~x86-fbsd"
18 IUSE="cjk unicode"
19
20 DEPEND=">=sys-libs/ncurses-5.2-r2"
21
22 src_unpack() {
23 unpack ${A}
24 cd "${S}"
25
26 epatch "${WORKDIR}"/${P}.patch
27 use userland_BSD || epatch "${WORKDIR}"/${P}-fsuid.patch
28 epatch "${WORKDIR}"/${P}-autoconf.patch
29 if use unicode ; then
30 epatch "${WORKDIR}"/slang-debian-utf8.patch
31 epatch "${WORKDIR}"/slang-utf8-acs.patch
32 epatch "${WORKDIR}"/slang-utf8-fix.patch
33 epatch "${WORKDIR}"/slang-utf8-fix2.patch
34 fi
35
36 epatch "${FILESDIR}"/${P}-fbsdlink.patch
37
38 if use cjk ; then
39 sed -i \
40 -e "/SLANG_HAS_KANJI_SUPPORT/s/0/1/" \
41 src/sl-feat.h
42 fi
43 }
44
45 src_compile() {
46 export LANG=C
47 export LC_ALL=C
48 econf || die "econf failed"
49 sed -i -e "/^ELF_LINK/s:gcc:$(tc-getCC):" src/Makefile || die
50 emake CC="$(tc-getCC)" ELF_CC="$(tc-getCC)" -j1 all elf || die "make failed"
51 }
52
53 src_install() {
54 make install install-elf DESTDIR="${D}" || die "make install failed"
55 chmod a+rx "${D}"/usr/$(get_libdir)/libslang*$(get_libname)* || die "chmod failed"
56
57 if use unicode ; then
58 for i in "${D}"/usr/$(get_libdir)/libslang-utf8* ; do
59 local libslang=${i/${D}/}
60 dosym ${libslang} ${libslang/-utf8/}
61 done
62 dosym /usr/$(get_libdir)/libslang{-utf8,}.a
63 fi
64
65 rm -rf "${D}"/usr/doc
66 dodoc NEWS README *.txt
67 dodoc doc/*.txt doc/internal/*.txt doc/text/*.txt
68 dohtml doc/*.html
69 }

  ViewVC Help
Powered by ViewVC 1.1.20