From owner-freebsd-arm@FreeBSD.ORG Thu Feb 13 09:55:27 2014 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id EDE04972; Thu, 13 Feb 2014 09:55:26 +0000 (UTC) Received: from wp376.webpack.hosteurope.de (wp376.webpack.hosteurope.de [IPv6:2a01:488:42::50ed:8591]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id A54A91093; Thu, 13 Feb 2014 09:55:26 +0000 (UTC) Received: from xdsl-78-34-148-75.netcologne.de ([78.34.148.75] helo=dijkstra-old.hb22.cruwe.de); authenticated by wp376.webpack.hosteurope.de running ExIM with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) id 1WDt0t-0007xe-CI; Thu, 13 Feb 2014 10:55:23 +0100 Date: Thu, 13 Feb 2014 10:55:22 +0100 From: "Christopher J. Ruwe" To: freebsd-ports@freebsd.org Subject: [solved] Re: ports-mgmt/pkg failing to link when cross-compiling with qemu Message-ID: <20140213105522.2a30195a@dijkstra-old.hb22.cruwe.de> In-Reply-To: <20140123203851.0eed5088@dijkstra.cruwe.de> References: <20140123203851.0eed5088@dijkstra.cruwe.de> X-Mailer: Claws Mail 3.9.3 (GTK+ 2.24.22; amd64-portbld-freebsd9.2) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-bounce-key: webpack.hosteurope.de;cjr@cruwe.de;1392285326;60a905b3; Cc: freebsd-arm@freebsd.org X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Feb 2014 09:55:27 -0000 On Thu, 23 Jan 2014 20:38:51 +0100 "Christopher J. Ruwe" wrote: > When trying the instructions on > https://wiki.freebsd.org/QemuUserModeHowTo, I encountered a fairly > basic port (ports-mgmt/pkg) failing to link properly: > > [... - everything fine until here] > > cc -static -O -pipe -DPORTSDIR=\"/usr/ports\" -I../libpkg > -I/usr/ports/ports-mg/work/pkg-1.2.5/pkg/../external/expat/lib > -std=gnu99 -Qunused-arguments -Wsystemprototypes -Wmissing-prototypes > -Wpointer-arith -Wreturn-type -Wcast-qual -Wwritepts -Winline > -Wnested-externs -Wredundant-decls -Wold-style-definition > -Wmissing-int -static -o pkg-static add.o annotate.o audit.o > autoremove.o backup.o check.ock.o main.o plugins.o progressmeter.o > query.o register.o repo.o rquery.o update.otch.o shell.o stats.o ssh.o > -L/usr/ports/ports-mgmt/pkg/work/pkg-1.2.5/pkg/../lib -lcrypto -lmd > -lz -lbz2 -llzma -ljail -lelf -larchive -lsbuf -lfetch -lpt > > add.o: In function `exec_add': > add.c:(.text+0x11c): undefined reference to `pkgdb_access' > add.c:(.text+0x13c): undefined reference to `pkgdb_open' > add.c:(.text+0x164): undefined reference to `pkg_manifest_keys_new' > add.c:(.text+0x344): undefined reference to `pkg_fetch_file' > add.c:(.text+0x364): undefined reference to `pkg_add' > add.c:(.text+0x42c): undefined reference to `pkg_manifest_keys_free' > add.c:(.text+0x434): undefined reference to `pkgdb_close' > > > [ ... - they are all alike] > > > version.o: In function `print_version': > version.c:(.text+0x14fc): undefined reference to `pkg_get2' > version.c:(.text+0x1514): undefined reference to `pkg_version_cmp' > version.c:(.text+0x1590): undefined reference to `pkg_asprintf' > version.c:(.text+0x15a4): undefined reference to `pkg_asprintf' > version.c:(.text+0x1650): undefined reference to `pkg_printf' > which.o: In function `exec_which': [...] > > > Has anybody encountered something similar and would know how to fix > that? > > Thanks and cheers, The problem is trying to build ARMv6 32b-binaries on 64b amd64. Building on i386 works. Would it be possible to include that in the wiki (https://wiki.freebsd.org/QemuUserModeHowTo) Cheers, -- Christopher TZ: GMT + 1h GnuPG/GPG: 0xE8DE2C14 FreeBSD 9.2-STABLE #1 r256184: Thu Oct 10 19:12:54 CEST 2013 cjr@dijkstra.cruwe.de:/usr/obj/usr/home/cjr/media/src/freebsd/base/stable/9/sys/GEN_WDTRACE Punctuation matters: "Lets eat Grandma." or "Lets eat, Grandma." - Punctuation saves lives. "A panda eats shoots and leaves." or "A panda eats, shoots, and leaves." - Punctuation teaches proper biology. "With sufficient thrust, pigs fly just fine. However, this is not necessarily a good idea. It is hard to be sure where they are going to land, and it could be dangerous sitting under them as they fly overhead." (RFC 1925)