From owner-freebsd-arm@FreeBSD.ORG Sun Jan 4 17:19:35 2015 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9D7A55AD for ; Sun, 4 Jan 2015 17:19:35 +0000 (UTC) Received: from mail-la0-f47.google.com (mail-la0-f47.google.com [209.85.215.47]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2302C29DF for ; Sun, 4 Jan 2015 17:19:34 +0000 (UTC) Received: by mail-la0-f47.google.com with SMTP id hz20so16727617lab.20 for ; Sun, 04 Jan 2015 09:19:26 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=de0UvpEfSdYVZR3DuxxDgnqk06ulHZtleKXlFG0H53Q=; b=CJW4K8Nr3Tl0z2E/KdjGjKD7mS3vJMzisNHYcXXm7Mb2U0DAdwFDNamYXKMdsL/44Q GTjYyZ+o4DYyrBJsaFQz/NdENfeSkwg/ifXHzaokIml1u505fYlo84vuRxiYPESOHDck uCCAa5wdf1Ibj6/RrGxrNlstw0qy5dBVJC98LPyx9MMhW/ZqMMoKYgIr4vqKDScDsGsQ jWILkm6k3L9Cgjt94BtBY1I/IgrqLKnAuikPni7AuKYffL7PLlO92uEqLDue8KVcJszg 50XP/uwIySCv6CctxJy2DNDnnnVj4jbuJbgPzDatux1LrU1Ma/jenLPW1liCU5R7yTn0 Jw/Q== X-Gm-Message-State: ALoCoQkEYtytC1Y/Gssks0eurGFrKjwxK4a3d3RMiZJavEIhwkjoUb1p/P31oNoXp2w+5WRiV17z X-Received: by 10.152.3.100 with SMTP id b4mr84314786lab.68.1420391966868; Sun, 04 Jan 2015 09:19:26 -0800 (PST) MIME-Version: 1.0 Received: by 10.112.142.198 with HTTP; Sun, 4 Jan 2015 09:18:46 -0800 (PST) X-Originating-IP: [74.60.193.70] In-Reply-To: <02C43C8A-E9BB-4E59-8442-FC382689D941@kientzle.com> References: <02C43C8A-E9BB-4E59-8442-FC382689D941@kientzle.com> From: Jeremy Brown Date: Sun, 4 Jan 2015 12:18:46 -0500 Message-ID: Subject: Re: Cross-Compiling RPi Ports From amd64 Using Native Toolchain To: Tim Kientzle Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: freebsd-arm X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 Jan 2015 17:19:35 -0000 Okay, so I've run make toolchain, copied it over to my chroot and tried to run make configure again, but the make still fails at the "checking whether we are cross compiling" stage; I've checked config.log and it seems that the cross-compiler can compile the test file (the return code is 0), but when it tries to execute it the return code is 134 and I get the ELF interpreter error again. I tried symlinking /libexec to /usr/obj/usr/src/tmp/usr/libexec, with no success. Is it possible that the toolchain isn't targeting the correct architecture? Won't env -u TARGET -u TARGET_ARCH keep make from knowing what it's supposed to target and build for x64 instead? -Jeremy On Sat, Jan 3, 2015 at 2:39 PM, Tim Kientzle wrote: > > > On Jan 2, 2015, at 7:42 PM, Jeremy Brown wrote= : > > > > One additional thing: I checked my toolchain and did see that some of m= y > > programs (ar, as, cc, gcc, ld, ranlib) are statically linked, whereas t= he > > rest are dynamically linked, including cpp and nm which also gave me th= e > > ELF interpreter error. So I'll change my question somewhat - if I use t= he > > command given on the qemu page (env -u TARGET -u TARGET_ARCH make -j 4 > > toolchain) instead of the one provided by crochet (make XDEV=3D${XDEV} > > XDEV_ARCH=3D${XDEV_ARCH} WITH_GCC=3D1 WITH_GCC_BOOTSTRAP=3D1 WITHOUT_CL= ANG=3D1 > > WITHOUT_CLANG_BOOTSTRAP=3D1 WITHOUT_CLANG_IS_CC=3D1 WITHOUT_TESTS=3D1 x= dev), > > would I be more likely to succeed in cross-compiling my ports and will = I > be > > able to use this toolchain to build the kernel and world with crochet? > > You should install both and use them for different purposes: > > Crochet uses the =E2=80=98xdev=E2=80=99 tools *only* for compiling the U-= Boot boot > loader. (It does *not* use it for building kernel and world. The > standard FreeBSD build infrastructure automatically builds appropriate > cross-compilers as needed for kernel and world.) > > Tim > >