From owner-freebsd-embedded@FreeBSD.ORG Mon Sep 29 01:10:40 2008 Return-Path: Delivered-To: freebsd-embedded@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 256AB1065697 for ; Mon, 29 Sep 2008 01:10:40 +0000 (UTC) (envelope-from bms@incunabulum.net) Received: from out2.smtp.messagingengine.com (out2.smtp.messagingengine.com [66.111.4.26]) by mx1.freebsd.org (Postfix) with ESMTP id ED6AC8FC25 for ; Mon, 29 Sep 2008 01:10:39 +0000 (UTC) (envelope-from bms@incunabulum.net) Received: from compute1.internal (compute1.internal [10.202.2.41]) by out1.messagingengine.com (Postfix) with ESMTP id 33773171397; Sun, 28 Sep 2008 21:10:39 -0400 (EDT) Received: from heartbeat1.messagingengine.com ([10.202.2.160]) by compute1.internal (MEProxy); Sun, 28 Sep 2008 21:10:39 -0400 X-Sasl-enc: gI5nx759Jj4NT9VlJ8ioj4OahQNDFDlUmO02xVMpGpz2 1222650638 Received: from empiric.lon.incunabulum.net (82-35-112-254.cable.ubr07.dals.blueyonder.co.uk [82.35.112.254]) by mail.messagingengine.com (Postfix) with ESMTPSA id 82E37D96F; Sun, 28 Sep 2008 21:10:38 -0400 (EDT) Message-ID: <48E02B0D.9030806@incunabulum.net> Date: Mon, 29 Sep 2008 02:10:37 +0100 From: Bruce M Simpson User-Agent: Thunderbird 2.0.0.14 (X11/20080514) MIME-Version: 1.0 To: Andrey Chernov , Bruce M Simpson , freebsd-embedded@FreeBSD.org References: <48E001DC.9010503@incunabulum.net> <20080929002040.GA64397@nagual.pp.ru> In-Reply-To: <20080929002040.GA64397@nagual.pp.ru> X-Enigmail-Version: 0.95.6 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Re: r181397 of src/usr.bin/make/job.c breaks cross-compiles X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Sep 2008 01:10:40 -0000 Andrey Chernov wrote: > Please explain, how it may cause problem? In 'make world' or 'make > buildworld;make installworld' headers and libraries was builded first with > old make, _then_ the new make is builded. 'make' is not a bootstrap tool > builded first (at -current, I don't check -stable branch) > When I use NanoBSD to build a system image for the ARM, nanobsd.sh invokes the "make" targets in the source tree which I imagine most developers are familiar with; the build system attempts to build "make" first thing in the host's staging area under MAKEOBJDIRPREFIX, as one would normally expect. What is strange about this failure, is the fact that the "buildworld" target does not stop due to the error until after the dependency pass is made over the tree. I traced the problem back in logs to the "make" failing to find arc4random_uniform() during link. Given that it's building a "make" executable for the *host*, not the *target*, I would expect to see this error, as this function doesn't exist in FreeBSD 7.1. It looks to me as if the change to "make" assumes that the FreeBSD 8.x versions of the arc4 library functions are always available, even for cross compilation. This assumption doesn't seem to be robust, and it breaks down in this cross-compilation use case. Can you please advise what the best way to fix this in the source is? It looks as though the change should either be backed out, so the cross-compilation use case is unbroken, or wrapped with a __FreeBSD_version guard. thanks again for all your help BMS