irssi-perl: cross compile
This commit is contained in:
parent
065932bfdd
commit
b16545a9f6
1 changed files with 32 additions and 10 deletions
|
@ -1,11 +1,13 @@
|
|||
# Template file for 'irssi'
|
||||
pkgname=irssi
|
||||
version=1.2.2
|
||||
revision=4
|
||||
revision=5
|
||||
build_style=gnu-configure
|
||||
configure_args="--disable-static --with-proxy --enable-true-color --with-otr"
|
||||
hostmakedepends="pkg-config"
|
||||
makedepends="libglib-devel libressl-devel ncurses-devel libgcrypt-devel libotr-devel"
|
||||
configure_args="--disable-static --with-proxy --enable-true-color
|
||||
--with-otr --with-perl=module"
|
||||
hostmakedepends="pkg-config perl"
|
||||
makedepends="libglib-devel libressl-devel ncurses-devel libgcrypt-devel
|
||||
libotr-devel perl"
|
||||
depends="ca-certificates"
|
||||
conf_files="/etc/irssi.conf"
|
||||
short_desc="Secure and modular IRC client with text mode user interface"
|
||||
|
@ -16,13 +18,33 @@ distfiles="https://github.com/irssi/irssi/releases/download/${version}/irssi-${v
|
|||
checksum=53182861d4d2be6db35fa7e3f0524a64d2a54a374307574dab5f5362bfea563c
|
||||
|
||||
LDFLAGS="-lncursesw"
|
||||
subpackages="irssi-devel irssi-otr"
|
||||
|
||||
if [ -z "$CROSS_BUILD" ]; then
|
||||
configure_args+=" --with-perl=module"
|
||||
subpackages+=" irssi-perl"
|
||||
makedepends+=" perl"
|
||||
fi
|
||||
pre_configure() {
|
||||
[ -z "$CROSS_BUILD" ] && return 0
|
||||
local perlprefix=${XBPS_STATEDIR}/perlprefix-${XBPS_TARGET_MACHINE}
|
||||
mkdir -p $perlprefix
|
||||
cp "$XBPS_CROSS_BASE/usr/lib/perl5/core_perl/Config"*.p? $perlprefix
|
||||
cp "$XBPS_CROSS_BASE/usr/lib/perl5/core_perl/Errno.pm" $perlprefix
|
||||
vsed -i -e "s;archlibexp => '\(.*\)';archlibexp => '${XBPS_CROSS_BASE}\1';" \
|
||||
${perlprefix}/Config.pm
|
||||
vsed -i -e "s;^archlibexp='\(.*\)';archlibexp='${XBPS_CROSS_BASE}\1';" \
|
||||
${perlprefix}/Config_heavy.pl
|
||||
export PERL5LIB=$perlprefix
|
||||
export OPTIMIZE="$CFLAGS"
|
||||
export LDDLFLAGS="-shared $CFLAGS -L${XBPS_CROSS_BASE}/usr/lib -lperl"
|
||||
export PERL_MM_USE_DEFAULT=1
|
||||
}
|
||||
|
||||
post_configure() {
|
||||
for i in common irc textui ui; do
|
||||
perlmkf="$wrksrc/src/perl/$i/Makefile.PL"
|
||||
if [ ! -f $perlmkf ]; then
|
||||
msg_error "*** ERROR: couldn't find $perlmkf, aborting **\n"
|
||||
fi
|
||||
cd $wrksrc/src/perl/$i
|
||||
perl Makefile.PL INSTALLDIRS=vendor
|
||||
done
|
||||
}
|
||||
|
||||
irssi-perl_package() {
|
||||
depends="irssi"
|
||||
|
|
Loading…
Reference in a new issue