2.4. tmp perl-5.34.0
#!/bin/sh # Copyright © 1999-2022 Gerard Beekmans # Copyright © 2017-2022 Random Crew # Distributed under the terms of MIT License.
Configuration
perl version for usage in paths is extracted from variable PV, containing full package version.
src_config() { perl_version=${PV%.*} sh Configure \ -des \ -Dprefix=${PREFIX} \ -Dvendorprefix=${PREFIX} \ -Dprivlib=${PREFIX}/lib/perl5/${perl_version}/core_perl \ -Darchlib=${PREFIX}/lib/perl5/${perl_version}/core_perl \ -Dsitelib=${PREFIX}/lib/perl5/${perl_version}/site_perl \ -Dsitearch=${PREFIX}/lib/perl5/${perl_version}/site_perl \ -Dvendorlib=${PREFIX}/lib/perl5/${perl_version}/vendor_perl \ -Dvendorarch=${PREFIX}/lib/perl5/${perl_version}/vendor_perl \ -Dman1dir=${PREFIX}/share/man/man1 \ -Dman3dir=${PREFIX}/share/man/man3 }
Compilation
src_compile() { make ${MAKEOPTS} }
Installation
We are not doing unset of variables:
unset BUILD_ZLIB BUILD_BZIP2
As they are unset automatically after the build of current package ends.
src_install() { make install ${MAKEOPTS} DESTDIR=${D} }
Unit testing
src_check() { make -k test }
Links
- url.lfs: https://linuxfromscratch.org/lfs/view/11.1/chapter08/perl.html
- url.lfs.stage1: https://linuxfromscratch.org/lfs/view/11.1/chapter07/perl.html