void-packages/templates/perl.pre_build
Juan RP c06defc719 Replace run_stuff with post/pre_<stage> variables.
If there's a file called "$pkgname.{pre,post}_{configure,build,install}
it will be automatically executed. In addition to this, templates may
use {pre,post}_{configure,build,install}_cmd variables to run arbitrary
commands.

--HG--
extra : convert_revision : 62ad549b8299689ecf8c833e73eda436ffdb7aa7
2008-10-27 03:56:42 +01:00

13 lines
364 B
Plaintext

# 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