[patch] provide jail with correct ARCH

Dominic Fandrey kamikaze at bsdforen.de
Tue Jan 1 10:33:43 EST 2013


It's a long standing problem when compiling for i386 under amd64
that ARCH is set to the host system architecture.

This is a proposal to fix this.

-- 
A: Because it fouls the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail? 
-------------- next part --------------
Index: lib/tinderbox.env
===================================================================
RCS file: /space/cvs/marcuscom-cvs/portstools/tinderbox/lib/tinderbox.env,v
retrieving revision 1.33
diff -u -r1.33 tinderbox.env
--- lib/tinderbox.env	15 Dec 2012 15:04:24 -0000	1.33
+++ lib/tinderbox.env	1 Jan 2013 15:36:07 -0000
@@ -30,7 +30,7 @@
 OSVERSION=`awk '/^#define __FreeBSD_version/ {print $3}' < ^^SRCBASE^^/sys/sys/param.h`
 OSREL=`awk 'BEGIN {FS="\""}; /^REVISION/ {print $2}' < ^^SRCBASE^^/sys/conf/newvers.sh`
 BRANCH=`awk 'BEGIN {FS="\""}; /^BRANCH/ {print $2}' < ^^SRCBASE^^/sys/conf/newvers.sh`
-ARCH=`uname -p`
+ARCH=^^ARCH^^
 UNAME_n=tinderbox.host
 UNAME_r=^^OSREL^^-^^BRANCH^^
 UNAME_s=FreeBSD
Index: lib/tinderlib.sh
===================================================================
RCS file: /space/cvs/marcuscom-cvs/portstools/tinderbox/lib/tinderlib.sh,v
retrieving revision 1.79
diff -u -r1.79 tinderlib.sh
--- lib/tinderlib.sh	15 Dec 2012 15:04:24 -0000	1.79
+++ lib/tinderlib.sh	1 Jan 2013 15:36:07 -0000
@@ -501,6 +501,8 @@
     # Allow SRCBASE to be overridden
     eval "export SRCBASE=${SRCBASE:-`realpath $(tinderLoc jail ${jail})/src`}" \
 	>/dev/null 2>&1
+    # Set ARCH
+    export ARCH=$(${tc} getJailArch -j ${jail})
 
     for _tb_var in $(buildenvlist "${jail}" "${portstree}" "${build}" "${major_version}")
     do


More information about the tinderbox-list mailing list