|
Line 0
Link Here
|
|
|
1 |
# Copyright 1999-2008 Gentoo Foundation |
| 2 |
# Distributed under the terms of the GNU General Public License v2 |
| 3 |
# $Header: /var/cvsroot/gentoo-x86/net-misc/suite3270/suite3270-3.3.8.ebuild,v 1.1 2008/10/20 04:25:04 robbat2 Exp $ |
| 4 |
|
| 5 |
inherit eutils |
| 6 |
|
| 7 |
IUSE="cjk doc ncurses ssl tcl X" |
| 8 |
|
| 9 |
S="${WORKDIR}" |
| 10 |
DESCRIPTION="Complete 3270 access package" |
| 11 |
SRC_URI="mirror://sourceforge/x3270/${PN}-${PV/_/}.tgz" |
| 12 |
HOMEPAGE="http://www.geocities.com/SiliconValley/Peaks/7814/" |
| 13 |
|
| 14 |
SLOT="0" |
| 15 |
LICENSE="GPL-2" |
| 16 |
KEYWORDS="~amd64 ~ppc ~s390 ~sparc ~x86" |
| 17 |
|
| 18 |
RDEPEND="X? ( x11-libs/libX11 |
| 19 |
x11-libs/libXaw |
| 20 |
x11-libs/libXmu |
| 21 |
x11-libs/libXt ) |
| 22 |
ncurses? ( sys-libs/ncurses |
| 23 |
sys-libs/readline ) |
| 24 |
ssl? ( dev-libs/openssl ) |
| 25 |
tcl? ( dev-lang/tcl )" |
| 26 |
|
| 27 |
DEPEND="${RDEPEND} |
| 28 |
X? ( x11-misc/imake |
| 29 |
x11-misc/xbitmaps |
| 30 |
x11-proto/xproto |
| 31 |
app-text/rman |
| 32 |
x11-apps/mkfontdir |
| 33 |
x11-apps/bdftopcf )" |
| 34 |
|
| 35 |
SUB_PV="3.3" |
| 36 |
MY_FONTDIR="/usr/share/fonts/x3270" |
| 37 |
|
| 38 |
suite3270_makelist() { |
| 39 |
MY_PLIST="pr3287 s3270" |
| 40 |
use ncurses && MY_PLIST="${MY_PLIST} c3270" |
| 41 |
use tcl && MY_PLIST="${MY_PLIST} tcl3270" |
| 42 |
use X && MY_PLIST="${MY_PLIST} x3270" |
| 43 |
} |
| 44 |
|
| 45 |
src_compile() { |
| 46 |
local myconf |
| 47 |
|
| 48 |
myconf="--without-pr3287" |
| 49 |
myconf="${myconf} --cache-file=${S}/config.cache" |
| 50 |
myconf="${myconf} $(use_enable cjk dbcs)" |
| 51 |
myconf="${myconf} $(use_enable ssl)" |
| 52 |
myconf="${myconf} $(use_with X x)" |
| 53 |
myconf="${myconf} $(use_with X fontdir ${MY_FONTDIR})" |
| 54 |
|
| 55 |
suite3270_makelist |
| 56 |
for p in ${MY_PLIST} ; do |
| 57 |
cd "${S}/${p}-${SUB_PV}" |
| 58 |
econf ${myconf} || die "econf failed on ${p}" |
| 59 |
emake || die "emake faild on ${p}" |
| 60 |
done |
| 61 |
} |
| 62 |
|
| 63 |
src_install () { |
| 64 |
suite3270_makelist |
| 65 |
use X && dodir ${MY_FONTDIR} |
| 66 |
for p in ${MY_PLIST} ; do |
| 67 |
cd "${S}/${p}-${SUB_PV}" |
| 68 |
emake DESTDIR="${D}" install install.man \ |
| 69 |
|| die "emake failed on ${p}" |
| 70 |
use doc && docinto ${p} && dohtml html/* |
| 71 |
done |
| 72 |
|
| 73 |
use X && rm -f "${D}/${MY_FONTDIR}/fonts.dir" |
| 74 |
return 0 |
| 75 |
} |
| 76 |
|
| 77 |
pkg_postinst() { |
| 78 |
if use X ; then |
| 79 |
einfo "Running mkfontdir on ${MY_FONTDIR}" |
| 80 |
mkfontdir ${MY_FONTDIR} |
| 81 |
fi |
| 82 |
} |