wok-undigest annotate perl/receipt @ rev 932
usbmanager: thanks Pascal, add some depends, what else do it need?
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Thu Feb 28 11:23:11 2013 +0000 (2013-02-28) |
parents | |
children |
rev | line source |
---|---|
pascal@533 | 1 # SliTaz package receipt. |
pascal@533 | 2 |
pascal@533 | 3 PACKAGE="perl" |
pascal@533 | 4 VERSION="5.12.3" |
pascal@533 | 5 CATEGORY="development" |
pascal@533 | 6 SHORT_DESC="Full Perl interpreter and modules." |
pascal@533 | 7 MAINTAINER="pankso@slitaz.org" |
pascal@533 | 8 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
pascal@533 | 9 DEPENDS="libdb gdbm zlib" |
pascal@533 | 10 BUILD_DEPENDS="db gdbm zlib" |
pascal@533 | 11 WEB_SITE="http://www.perl.org/" |
pascal@533 | 12 WGET_URL="http://ftp.funet.fi/pub/CPAN/src/$TARBALL" |
pascal@533 | 13 PROVIDE="microperl" |
pascal@533 | 14 |
pascal@533 | 15 # Rules to compile & install the temporary toolchain. |
pascal@533 | 16 cook_tmp_toolchain() |
pascal@533 | 17 { |
pascal@533 | 18 cd $src |
pascal@533 | 19 { sh Configure -des -Dprefix=/tools \ |
pascal@533 | 20 -Dstatic_ext='Data/Dumper Fcntl IO' && |
pascal@533 | 21 |
pascal@533 | 22 # Only few tools are needed in the tmp toolchain. |
pascal@533 | 23 make perl utilities ext/Errno/pm_to_blib |
pascal@533 | 24 } || return 1 |
pascal@533 | 25 cp perl pod/pod2man /tools/bin |
pascal@533 | 26 mkdir -p /tools/lib/perl5/5.12.3 |
pascal@533 | 27 cp -R lib/* /tools/lib/perl5/5.12.3 |
pascal@533 | 28 } |
pascal@533 | 29 |
pascal@533 | 30 |
pascal@533 | 31 # Rules to configure and make the package. |
pascal@533 | 32 # |
pascal@533 | 33 compile_rules() |
pascal@533 | 34 { |
pascal@533 | 35 cd $src |
pascal@533 | 36 yes '' | sh Configure -Dusethreads -Dprefix=/usr |
pascal@533 | 37 ./configure.gnu --prefix=/usr && |
pascal@533 | 38 make && |
pascal@533 | 39 make install |
pascal@533 | 40 |
pascal@533 | 41 # make microperl here |
pascal@533 | 42 # patch to fix compiling microperl |
pascal@533 | 43 patch -p0 -i $stuff/miniperlmain.patch |
pascal@533 | 44 # Install in /usr (default is /usr/local). |
pascal@533 | 45 sed -i s/'usr\/local'/'usr'/ uconfig.sh |
pascal@533 | 46 # Sed to search mods in /usr/lib/perl5. |
pascal@533 | 47 sed -i s/'perl5\/5.12'/'perl5'/ uconfig.sh |
pascal@533 | 48 # Optimisation. |
pascal@533 | 49 sed -i s/'unknown'/'$HOST_SYSTEM'/ uconfig.sh |
pascal@533 | 50 # Make it! |
pascal@533 | 51 make -f Makefile.micro regen_uconfig && |
pascal@533 | 52 make -f Makefile.micro && |
pascal@533 | 53 strip microperl |
pascal@533 | 54 } |
pascal@533 | 55 |
pascal@533 | 56 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@533 | 57 genpkg_rules() |
pascal@533 | 58 { |
pascal@533 | 59 mkdir -p $fs/usr |
pascal@533 | 60 cp -a $_pkg/usr/bin $fs/usr |
pascal@533 | 61 cp -a $_pkg/usr/lib $fs/usr |
pascal@533 | 62 } |
pascal@533 | 63 |
pascal@533 | 64 # Pre install commands for Tazpkg. |
pascal@533 | 65 # Remove perl link to microperl if any. |
pascal@533 | 66 # |
pascal@533 | 67 pre_install() |
pascal@533 | 68 { |
pascal@533 | 69 echo "Processing pre-install commands..." |
pascal@533 | 70 rm -f $1/usr/bin/perl |
pascal@533 | 71 } |