perl: remove unneeded pre_build and post_install funcs.

--HG--
extra : convert_revision : f577744be232b4babea8181235e8e4b0c86c0072
This commit is contained in:
Juan RP 2009-10-16 22:44:48 +02:00
parent bf2aeaa1d9
commit fabd92400b

View file

@ -44,37 +44,3 @@ pre_configure()
-Dvendorlib=${p5_base}/vendor_perl/${p5_apiver}"
export configure_args="${args}"
}
pre_build()
{
# This fixes the definitions that the perl binary uses to look at
# prefix and not XBPS_DESTDIR/MASTERDIR.
if [ "$XBPS_DESTDIR" != "/xbps" ]; then
sed -i -e "s|$XBPS_DESTDIR\/$pkgname-$version|/usr|g" \
$wrksrc/config.h
fi
sed -i -e "s|/usr/usr|/usr|g" $wrksrc/config.h
if [ "$XBPS_MASTERDIR" != "/" ]; then
sed -i -e "s|$XBPS_MASTERDIR||g" $wrksrc/config.h
fi
}
post_install()
{
# Remove hardcoded paths of XBPS_DESTDIR.
local FILES="Config.pm Config_heavy.pl .packlist"
local opmult="${xbps_machine}-linux-thread-multi"
local thrdir="${DESTDIR}/usr/lib/perl5/${version}/${opmult}"
for f in ${FILES}; do
sed -i -e "s|$DESTDIR||g" ${thrdir}/${f}
done
for f in $(find $DESTDIR/usr/bin/ -type f -print); do
if $(echo $f|grep -q $DESTDIR); then
sed -i -e "s|$DESTDIR||g" $f
fi
done
}