From patchwork Sun Jan 6 15:22:50 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Petazzoni X-Patchwork-Id: 209770 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 502832C0040 for ; Mon, 7 Jan 2013 02:24:39 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id E53F130ECE; Sun, 6 Jan 2013 15:24:37 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id m7KlezT7AURM; Sun, 6 Jan 2013 15:24:32 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id 3CCDC30EF0; Sun, 6 Jan 2013 15:23:46 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 65B538F753 for ; Sun, 6 Jan 2013 15:23:28 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 0BC5F1016B6 for ; Sun, 6 Jan 2013 15:23:12 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZLDB3YOpPzUG for ; Sun, 6 Jan 2013 15:23:11 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail.free-electrons.com (mail.free-electrons.com [94.23.32.191]) by fraxinus.osuosl.org (Postfix) with ESMTP id D5F23101655 for ; Sun, 6 Jan 2013 15:23:10 +0000 (UTC) Received: by mail.free-electrons.com (Postfix, from userid 106) id 0D3BA161; Sun, 6 Jan 2013 16:23:20 +0100 (CET) Received: from localhost (humanoidz.org [82.247.183.72]) by mail.free-electrons.com (Postfix) with ESMTPSA id 0F68E10F for ; Sun, 6 Jan 2013 16:23:19 +0100 (CET) From: Thomas Petazzoni To: buildroot@busybox.net Date: Sun, 6 Jan 2013 16:22:50 +0100 Message-Id: X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: MIME-Version: 1.0 Subject: [Buildroot] [PATCH 10/15] elfutils: towards uClibc support: solve memcpy problem 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 elfutils uses some strange internal alias of memcpy in glibc, so workaround this when building with uClibc. Heavily based from work done by Stefan Fröberg, but with many further modifications by Thomas Petazzoni. Signed-off-by: Thomas Petazzoni --- package/elfutils/elfutils-03-memcpy-def.patch | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 package/elfutils/elfutils-03-memcpy-def.patch diff --git a/package/elfutils/elfutils-03-memcpy-def.patch b/package/elfutils/elfutils-03-memcpy-def.patch new file mode 100644 index 0000000..eb50cf6 --- /dev/null +++ b/package/elfutils/elfutils-03-memcpy-def.patch @@ -0,0 +1,24 @@ +Provide a compatibility alias __memcpy + +For some reason, libelf uses the internal glibc alias __memcpy, which +doesn't exist in uClibc. Add a manual alias so that the build can +proceed with uClibc. + +Signed-off-by: Thomas Petazzoni + +Index: b/libelf/libelf.h +=================================================================== +--- a/libelf/libelf.h ++++ b/libelf/libelf.h +@@ -34,6 +34,11 @@ + /* Get the ELF types. */ + #include + ++#ifndef _LIBC ++#ifndef __mempcpy ++#define __mempcpy mempcpy ++#endif ++#endif + + /* Known translation types. */ + typedef enum