blob: 3921c62e22e358ffdebff9f348dac44c8716212f (
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
|
# Maintainer: Erich Eckner <arch at eckner dot net>
# Contributor: Swift Geek <swiftgeek «at» gmail.com>
# Contributor: Nick Østergaard <oe.nick at gmail dot com>
# Contributor: John D Jones III (jnbek) <jnbek1972 at gmail dot com>
pkgname=perl-alien-wxwidgets
_cpan_name=Alien-wxWidgets
pkgver=0.67
pkgrel=2
pkgdesc="building, finding and using wxWidgets binaries"
arch=('any')
url="https://metacpan.org/release/${_cpan_name}"
license=('GPL' 'PerlArtistic')
depends=('perl>=5.10.0' 'wxgtk' 'perl-module-pluggable') # Install perl-module-pluggable from AUR
makedepends=('perl-module-build')
checkdepends=('perl-test-pod' 'perl-test-pod-coverage')
options=(!emptydirs)
source=("http://www.cpan.org/modules/by-module/${_cpan_name%%-*}/${_cpan_name}-${pkgver}.tar.gz"
)
sha512sums=('633547a4417a42e96621a9409a83e736ba94c8692b7791a1887cf8497aaade9bc827a1279db169f737e834c5070c6f0d485c005133708bbf76a279acf1684092')
prepare() {
export _src_dir="${_cpan_name}-${pkgver}"
# Setting these env variables overwrites any command-line-options we don't want...
export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps \
PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
MODULEBUILDRC=/dev/null
warning "If build stage tries to pull and compile WX - interrupt as resulting package wont work"
# warning "If package contains gtk2_3_0_0_uni_gcc_3_4.pm it is an improper package - do not attempt to install it - report in comments instead"
# HAX HAX HAX - hax first in PATH to replace /usr/bin
# Uncomment lines below to compile against wxgtk2.8
# mkdir ${srcdir}/hax
# ln -s /usr/bin/wx-config-2.8 ${srcdir}/hax/wx-config
# export PATH="${srcdir}/hax:${PATH}"
### We are now patching issues, so compilation against 3.x is possible
# https://rt.cpan.org/Public/Bug/Display.html?id=94367
# https://rt.cpan.org/Public/Bug/Display.html?id=87202
# {
# cd "$_src_dir"
# patch < ${srcdir}/wx-config-version-and-env.patch
# patch ./lib/Alien/wxWidgets/Utility.pm < ${srcdir}/Alien-wxWidgets-0.64-returnor.patch
# }
}
build() {
cd "$_src_dir"
/usr/bin/perl Makefile.PL
make
}
check () {
cd "$_src_dir"
make test
}
package () {
cd "$_src_dir"
echo "$_src_dir"
make install
# remove perllocal.pod and .packlist
find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
}
|