Date: Wed, 5 Sep 2012 09:40:57 +0300 From: Alexander Yerenkow <yerenkow@gmail.com> To: freebsd-hackers@freebsd.org Subject: Ports cross-compiling Message-ID: <CAPJF9wmWSWgWmpa5wbqHv%2BLhp8WRCg2yBV0x5vP9Lr9OA9cz7A@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hello all. I'm currently trying to make poudriere cross compile some ports for arm arch. I'm using such command (as example): env TARGET=arm TARGET_ARCH=armv6 TARGET_CPUARCH=armv6 PATH=/usr/obj/arm.armv6/usr/src/tmp/usr/bin:${PATH} CONFIGURE_HOST=amd64 STRIP_CMD=true make PKGNAMESUFFIX=-arm WRKDIRPREFIX=/tmp WITHOUT_CHECKS=yes LOCALBASE=/usr/localarm6 -C /usr/ports/A/B package I have problem: 1. When I run this command from chrooted env, all builds fine; configure script make check if we cross-compiling, somehow it gets "no" and all goes well. 2. When this command run by poudriere in jail, all fails as here: checking whether we are cross compiling... configure: error: in `/tmp/usr/ports/devel/pcre/work/pcre-8.31': configure: error: cannot run C compiled programs. If you meant to cross compile, use `--host'. See `config.log' for more details ===> Script "configure" failed unexpectedly. So, I'd like to propose small changes to ports/Mk/bsd.port.mk SET_LATE_CONFIGURE_ARGS= \ ..... if [ ! -z "${CONFIGURE_HOST}" ]; then \ _LATE_CONFIGURE_ARGS="$${_LATE_CONFIGURE_ARGS} --host=${CONFIGURE_HOST}" ; \ fi ; \ ..... And after this, builds going just fine (of course for ports that can be cross-built). Is it possible to accept this? Seems to me non-destructive patch. -- Regards, Alexander Yerenkow
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAPJF9wmWSWgWmpa5wbqHv%2BLhp8WRCg2yBV0x5vP9Lr9OA9cz7A>