diff --git a/srcpkgs/chroot-file/template b/srcpkgs/chroot-file/template index 83521e85366..713949028a2 100644 --- a/srcpkgs/chroot-file/template +++ b/srcpkgs/chroot-file/template @@ -23,16 +23,17 @@ done pre_configure() { if [ "$CROSS_BUILD" ]; then # Build host file first. - CC= CFLAGS= LDFLAGS= AR= RANLIB= ./configure + [ ! -d host-build ] && mkdir host-build + cd host-build + CC= CFLAGS= LDFLAGS= AR= RANLIB= ../configure make ${makejobs} - install -Dm755 src/file ${wrksrc}/hostbin/file - make distclean + install -m755 src/file ${wrksrc}/host-build/ fi } pre_build() { if [ "$CROSS_BUILD" ]; then - export PATH=${wrksrc}/hostbin:$PATH + export PATH=${wrksrc}/host-build:$PATH fi }