|
|
@ -2,7 +2,7 @@ |
|
|
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
|
|
# |
|
|
|
# Filename: package/.../perl/perl.conf |
|
|
|
# Copyright (C) 2010 The OpenSDE Project |
|
|
|
# Copyright (C) 2009 - 2010 The OpenSDE Project |
|
|
|
# Copyright (C) 2004 - 2006 The T2 SDE Project |
|
|
|
# Copyright (C) 1998 - 2004 Clifford Wolf |
|
|
|
# |
|
|
@ -22,11 +22,17 @@ perl_cross_bootstrap() |
|
|
|
$MAKE clean |
|
|
|
|
|
|
|
# setup cross compiler |
|
|
|
sed -e '/^d_futimes/d' -e '/^d_sockatmark/d' -i config.sh |
|
|
|
cat >> config.sh <<-EOT |
|
|
|
cc='$CC' |
|
|
|
ccname='$CC' |
|
|
|
ld='$CC' |
|
|
|
libs='-ldl -lm -lcrypt -lutil -lc' |
|
|
|
d_futimes='undef' |
|
|
|
d_sockatmark='undef' |
|
|
|
d_sockatmarkproto='undef' |
|
|
|
EOT |
|
|
|
touch config.sh |
|
|
|
eval $MAKE $makeopt miniperl |
|
|
|
cp -f miniperl.native miniperl |
|
|
|
} |
|
|
@ -56,7 +62,8 @@ perl_postmake() { |
|
|
|
runconfig=0 |
|
|
|
|
|
|
|
[[ $libdir = *lib64 ]] && var_append patchfiles ' ' "$confdir/lib64.diff" |
|
|
|
confopt="-des -Dcc=gcc -Darchname=$arch_target -Dprefix=/$prefix \ |
|
|
|
libpth="/usr/local/${libdir##*/} /${libdir##*/} /usr/${libdir##*/}" |
|
|
|
confopt="-des -Dcc=$cc -Darchname=$arch_target -Dprefix=/$prefix \ |
|
|
|
-Dmyhostname=$SDECFG_PKG_PERL5_HOST_NAME \ |
|
|
|
-Dsiteprefix=/$SDECFG_PKG_PERL5_SITE_PREFIX \ |
|
|
|
-Dvendorprefix=/$SDECFG_PKG_PERL5_VENDOR_PREFIX" |
|
|
@ -65,11 +72,25 @@ confopt="-des -Dcc=gcc -Darchname=$arch_target -Dprefix=/$prefix \ |
|
|
|
[ "$SDECFG_PKG_PERL5_THREADS" = "1" ] && confopt="$confopt -Dusethreads" |
|
|
|
[ "$SDECFG_PKG_PERL5_USE_DB3" = "1" ] && patchfiles="$patchfiles $confdir/use_db3.diff" |
|
|
|
|
|
|
|
hook_add preconf 2 "( rm -f config.sh Policy.sh; sh Configure \$confopt; )" |
|
|
|
hook_add preconf 2 "( rm -f config.sh Policy.sh; eval sh Configure \$confopt; )" |
|
|
|
if ! atstage native; then |
|
|
|
var_append confopt " " "-Ddynamic_ext=none -Dstatic_ext=none" |
|
|
|
var_append confopt " " "-Ddynamic_ext=none" |
|
|
|
var_append confopt " " "-Dstatic_ext=\"Data/Dumper IO Fcntl POSIX\"" |
|
|
|
hook_add premake 3 "perl_cross_bootstrap" |
|
|
|
fi |
|
|
|
|
|
|
|
hook_add postmake 4 "perl_postmake" |
|
|
|
|
|
|
|
PERL_CROSS_MODULES="File/Basename.pm Errno.pm Config.pm IO/File.pm Symbol.pm \ |
|
|
|
SelectSaver.pm IO/Seekable.pm IO/Handle.pm IO.pm XSLoader.pm \ |
|
|
|
DynaLoader.pm AutoLoader.pm Carp/Heavy.pm" |
|
|
|
|
|
|
|
perl_cross_modules() |
|
|
|
{ |
|
|
|
moddir=${root}/${SDECFG_PKG_PERL5_SITE_PREFIX}/lib/perl5/$ver |
|
|
|
for mod in $PERL_CROSS_MODULES; do |
|
|
|
[ -d $moddir/`dirname $mod` ] || mkdir -p $moddir/`dirname $mod`; |
|
|
|
cp -vdpf lib/$mod $moddir/$mod |
|
|
|
done; |
|
|
|
} |
|
|
|
atstage cross && hook_add postmake 3 "perl_cross_modules" |