From patchwork Wed Apr 22 19:36:22 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?J=C3=B6rg_Krause?= X-Patchwork-Id: 463787 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id A36FA1402DC for ; Thu, 23 Apr 2015 05:36:39 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 090D262189; Wed, 22 Apr 2015 21:36:37 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id eZ5gfywcFjYX; Wed, 22 Apr 2015 21:36:36 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 6BFC06217A; Wed, 22 Apr 2015 21:36:36 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 830A06217A for ; Wed, 22 Apr 2015 21:36:32 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id etupt_Pq0eJY for ; Wed, 22 Apr 2015 21:36:32 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mx02.posteo.de (mx02.posteo.de [89.146.194.165]) by theia.denx.de (Postfix) with ESMTPS id 50F026216E for ; Wed, 22 Apr 2015 21:36:29 +0200 (CEST) Received: from dovecot03.posteo.de (unknown [185.67.36.28]) by mx02.posteo.de (Postfix) with ESMTPS id E588125A3DF1; Wed, 22 Apr 2015 21:36:27 +0200 (CEST) Received: from mail.posteo.de (localhost [127.0.0.1]) by dovecot03.posteo.de (Postfix) with ESMTPSA id 3lXBpM5Fpbz5vNB; Wed, 22 Apr 2015 21:36:27 +0200 (CEST) Received: from nzxt.fritz.box (nzxt.localdomain [192.168.178.46]) (Authenticated sender: joerg.krause@embedded.rocks) by embedded.rocks (Postfix) with ESMTPSA id B165E980384; Wed, 22 Apr 2015 21:36:25 +0200 (CEST) From: =?UTF-8?q?J=C3=B6rg=20Krause?= To: u-boot@lists.denx.de Date: Wed, 22 Apr 2015 21:36:22 +0200 Message-Id: <1429731382-14316-1-git-send-email-joerg.krause@embedded.rocks> X-Mailer: git-send-email 2.3.5 MIME-Version: 1.0 Cc: Tom Rini Subject: [U-Boot] [PATCH v2 1/1] Fix musl build X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This patch fixes cross-compiling U-Boot tools with the musl C library: * including is needed for ulong * defining _GNU_SOURCE is needed for loff_t Tested for target at91sam9261ek_dataflash_cs3. Signed-off-by: Jörg Krause Cc: Tom Rini --- Changes v1 -> v2: - Fix header include in image.h (reported by Tom Rini) --- include/image.h | 1 + tools/env/fw_env.c | 2 ++ tools/imagetool.h | 1 + tools/proftool.c | 1 + 4 files changed, 5 insertions(+) diff --git a/include/image.h b/include/image.h index 3844be6..60b924a 100644 --- a/include/image.h +++ b/include/image.h @@ -23,6 +23,7 @@ struct lmb; #ifdef USE_HOSTCC +#include /* new uImage format support enabled on host */ #define CONFIG_FIT 1 diff --git a/tools/env/fw_env.c b/tools/env/fw_env.c index 1173eea..daa02a7 100644 --- a/tools/env/fw_env.c +++ b/tools/env/fw_env.c @@ -8,6 +8,8 @@ * SPDX-License-Identifier: GPL-2.0+ */ +#define _GNU_SOURCE + #include #include #include diff --git a/tools/imagetool.h b/tools/imagetool.h index 3e15b4e..b7874f4 100644 --- a/tools/imagetool.h +++ b/tools/imagetool.h @@ -16,6 +16,7 @@ #include #include #include +#include #include #include #include diff --git a/tools/proftool.c b/tools/proftool.c index 3482951..9ce7a77 100644 --- a/tools/proftool.c +++ b/tools/proftool.c @@ -16,6 +16,7 @@ #include #include #include +#include #include #include