runit: move conditional to do_build().

This commit is contained in:
Juan RP 2015-02-16 10:41:36 +01:00
parent 7b1f053e57
commit cdc733d3bb
1 changed files with 5 additions and 4 deletions

View File

@ -11,14 +11,15 @@ distfiles="http://smarden.org/runit/runit-$version.tar.gz"
checksum=6fd0160cb0cf1207de4e66754b6d39750cff14bb0aa66ab49490992c0c47ba18 checksum=6fd0160cb0cf1207de4e66754b6d39750cff14bb0aa66ab49490992c0c47ba18
build_options="static" build_options="static"
if [ "$build_option_static" ]; then
CFLAGS+=" -static"
LDFLAGS+=" -static"
fi
do_build() { do_build() {
cd ${pkgname}-${version}/src cd ${pkgname}-${version}/src
if [ "$build_option_static" ]; then
CFLAGS+=" -static"
LDFLAGS+=" -static"
fi
sed -e 's,sbin/runit,usr/bin/runit,g' -i runit.h sed -e 's,sbin/runit,usr/bin/runit,g' -i runit.h
echo "$CC -D_GNU_SOURCE $CFLAGS" >conf-cc echo "$CC -D_GNU_SOURCE $CFLAGS" >conf-cc