Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Feb 2014 10:55:22 +0100
From:      "Christopher J. Ruwe" <cjr@cruwe.de>
To:        freebsd-ports@freebsd.org
Cc:        freebsd-arm@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>

index | next in thread | previous in thread | raw e-mail

On Thu, 23 Jan 2014 20:38:51 +0100
"Christopher J. Ruwe" <cjr@cruwe.de> 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)


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20140213105522.2a30195a>