From patchwork Fri May 9 19:06:55 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Bergmann X-Patchwork-Id: 347512 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from silver.osuosl.org (silver.osuosl.org [140.211.166.136]) by ozlabs.org (Postfix) with ESMTP id BD2A31400A3 for ; Sat, 10 May 2014 05:07:09 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 8C6F832B72; Fri, 9 May 2014 19:07:08 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ICLjQZB4VRjy; Fri, 9 May 2014 19:07:06 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id 79CD630063; Fri, 9 May 2014 19:07:06 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 003941C21E1 for ; Fri, 9 May 2014 19:07:05 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id F1CAB8C6BE for ; Fri, 9 May 2014 19:07:04 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZmnCdy06FC-d for ; Fri, 9 May 2014 19:07:03 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from server14.web4a.de (server14.web4a.de [62.27.5.114]) by whitealder.osuosl.org (Postfix) with ESMTPS id 379F78C679 for ; Fri, 9 May 2014 19:07:03 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by server14.web4a.de (server14.web4a.de) with ESMTP id F2BE4E0A825B for ; Fri, 9 May 2014 21:06:58 +0200 (CEST) X-Virus-Scanned: amavisd-new at server14.web4a.de Received: from server14.web4a.de ([62.27.5.114]) by localhost (server14.web4a.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id KxirOTFBgU57 for ; Fri, 9 May 2014 21:06:49 +0200 (CEST) Received: from [192.168.1.104] (i59F6C14.versanet.de [89.246.193.4]) by server14.web4a.de (server14.web4a.de) with ESMTP id AB839E0A8168 for ; Fri, 9 May 2014 21:06:49 +0200 (CEST) Message-ID: <536D274F.3030100@frajasalo.de> Date: Fri, 09 May 2014 21:06:55 +0200 From: Frank Bergmann User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 To: buildroot@busybox.net References: <20140507063009.23A95100E55@stock.ovh.net> <20140507093155.18034c1d@free-electrons.com> <20140509133412.GE764@arch.cereza> In-Reply-To: <20140509133412.GE764@arch.cereza> Subject: Re: [Buildroot] Analysis of build failures X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net On 09.05.2014 15:34, Ezequiel Garcia wrote: > On 07 May 09:31 AM, Thomas Petazzoni wrote: >>> nios2 | fio-fio-2.1.4 | NOK | http://autobuild.buildroot.net/results/9cd30031a40f768f6090cfba44c880fb2406672b/ >> >> Ezequiel? >> > > fio does a configure-time test to see if fallocate() is there, which passes > successfully. Then BR builds fio passing LARGE_FILE flags which makes the > toolchain try fallocate64(), which is not implemented. > > However, I'm not sure how to either make the configure-time fallocate test > fail (so fio knows there's no fallocate), or prevent BR from passing the > LARGE_FILE flags. > > Disable fio for nios2? Or patch away the fallocate function in the configure script for nios2 like the patch in attachment do ? With regards, Frank Bergmann. From cc514be257471b271c9d1c032279deb39bba68ce Mon Sep 17 00:00:00 2001 From: Frank Bergmann Date: Fri, 9 May 2014 20:32:20 +0200 Subject: [PATCH 1/1] fio: fix missing fallocate64() Current nios2 toolchain is missing the falloacte64() function call. The configure script does not detect this correctly and the C library is swapping fallocate with fallocate64 while compiling with the LARGEFILE* flags. The patch disables fallocate in the configure script. Signed-off-by: Frank Bergmann --- ...io-0001-nios2-configure-disable-fallocate.patch | 18 ++++++++++++++++++ package/fio/fio.mk | 4 ++++ 2 files changed, 22 insertions(+) create mode 100644 board/common-nios2/fio/fio-0001-nios2-configure-disable-fallocate.patch diff --git a/board/common-nios2/fio/fio-0001-nios2-configure-disable-fallocate.patch b/board/common-nios2/fio/fio-0001-nios2-configure-disable-fallocate.patch new file mode 100644 index 0000000..97b8b63 --- /dev/null +++ b/board/common-nios2/fio/fio-0001-nios2-configure-disable-fallocate.patch @@ -0,0 +1,18 @@ +configure: Disable fallocate + +Signed-off-by: Frank Bergmann + +--- fio-fio-2.1.4.orig/configure 2013-11-16 19:15:12.000000000 +0100 ++++ fio-fio-2.1.4/configure 2014-05-09 20:06:35.000000000 +0200 +@@ -578,7 +578,10 @@ int main(int argc, char **argv) + } + EOF + if compile_prog "" "" "linux_fallocate"; then +- linux_fallocate="yes" ++ # For nios2 disable fallocate because with LARGE_FILE flags it ++ # becomes fallocate64 which isn't available ++ #linux_fallocate="yes" ++ linux_fallocate="no" + fi + echo "Linux fallocate $linux_fallocate" + diff --git a/package/fio/fio.mk b/package/fio/fio.mk index f9a690e..311779b 100644 --- a/package/fio/fio.mk +++ b/package/fio/fio.mk @@ -9,6 +9,10 @@ FIO_SITE = git://git.kernel.dk/fio.git FIO_LICENSE = GPLv2 + special obligations FIO_LICENSE_FILES = LICENSE +ifeq ($(BR2_nios2),y) +BR2_GLOBAL_PATCH_DIR += "board/common-nios2" +endif + define FIO_CONFIGURE_CMDS (cd $(@D); ./configure --cc="$(TARGET_CC)" --extra-cflags="$(TARGET_CFLAGS)") endef -- 1.7.9.5