blob: ba6a06e296675d91cec5d6df935e80eb175e12a9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-libs/slang/slang-2.2.4.ebuild,v 1.12 2012/05/14 07:26:40 grobian Exp $
EAPI=4
inherit eutils
DESCRIPTION="A multi-platform programmer's library designed to allow a developer to create robust software"
HOMEPAGE="http://www.jedsoft.org/slang/"
SRC_URI="mirror://slang/v${PV%.*}/${P}.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x86-solaris"
IUSE="cjk pcre png readline static-libs zlib"
# ncurses for ncurses5-config to get terminfo directory
RDEPEND="sys-libs/ncurses
pcre? ( dev-libs/libpcre )
png? ( >=media-libs/libpng-1.2:0 )
cjk? ( dev-libs/oniguruma )
readline? ( sys-libs/readline )
zlib? ( sys-libs/zlib )"
DEPEND="${RDEPEND}"
MAKEOPTS="${MAKEOPTS} -j1"
src_prepare() {
epatch "${FILESDIR}"/${PN}-2.2.3-slsh-libs.patch
# avoid linking to -ltermcap race with some systems
sed -i -e '/^TERMCAP=/s:=.*:=:' configure || die
# we use the GNU linker also on Solaris
sed -i -e 's/-G -fPIC/-shared -fPIC/g' \
-e 's/-Wl,-h,/-Wl,-soname,/g' configure || die
}
src_configure() {
local myconf=slang
use readline && myconf=gnu
econf \
--with-readline=${myconf} \
$(use_with pcre) \
$(use_with cjk onig) \
$(use_with png) \
$(use_with zlib z)
}
src_compile() {
emake elf $(use static-libs && echo static)
pushd slsh >/dev/null
emake slsh
popd
}
src_install() {
emake DESTDIR="${D}" install-elf $(use static-libs && echo install-static)
rm -rf "${ED}"/usr/share/doc/{slang,slsh}
dodoc NEWS README *.txt doc/{,internal,text}/*.txt
dohtml doc/slangdoc.html slsh/doc/html/*.html
}
|