From patchwork Sat Dec 5 22:42:22 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bernd Kuhls X-Patchwork-Id: 553054 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id 4CE1014031E for ; Sun, 6 Dec 2015 09:42:35 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 8C61C896EA; Sat, 5 Dec 2015 22:42:34 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id F7x3KZEsoghg; Sat, 5 Dec 2015 22:42:33 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 660E5885A5; Sat, 5 Dec 2015 22:42:33 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id C76CC1BFC0F for ; Sat, 5 Dec 2015 22:42:32 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id C33A487E03 for ; Sat, 5 Dec 2015 22:42:32 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7BAHNoDX9sRV for ; Sat, 5 Dec 2015 22:42:31 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mailout10.t-online.de (mailout10.t-online.de [194.25.134.21]) by fraxinus.osuosl.org (Postfix) with ESMTPS id 8493F885A5 for ; Sat, 5 Dec 2015 22:42:31 +0000 (UTC) Received: from fwd28.aul.t-online.de (fwd28.aul.t-online.de [172.20.26.133]) by mailout10.t-online.de (Postfix) with SMTP id D7EE13F8F74 for ; Sat, 5 Dec 2015 23:42:28 +0100 (CET) Received: from fli4l.lan.fli4l (XRK3S2ZfrhLssDUzWag4ah47CLKUJ6ZqYxRfZkfnteB-0lHEqsxfKW+LIGAbDCsQGL@[80.139.245.254]) by fwd28.t-online.de with (TLSv1:ECDHE-RSA-AES256-SHA encrypted) esmtp id 1a5LX8-4G2FYO0; Sat, 5 Dec 2015 23:42:26 +0100 Received: from mahler.lan.fli4l ([192.168.1.1]:51382 helo=kuhls.lan.fli4l) by fli4l.lan.fli4l with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-SHA256:128) (Exim 4.86) (envelope-from ) id 1a5LX7-0004Rr-HH; Sat, 05 Dec 2015 23:42:25 +0100 From: Bernd Kuhls To: buildroot@buildroot.org Date: Sat, 5 Dec 2015 23:42:22 +0100 Message-Id: <1449355343-19014-1-git-send-email-bernd.kuhls@t-online.de> X-Mailer: git-send-email 2.6.2 X-ID: XRK3S2ZfrhLssDUzWag4ah47CLKUJ6ZqYxRfZkfnteB-0lHEqsxfKW+LIGAbDCsQGL X-TOI-MSGID: 7c38f992-f540-45dd-ad78-99bcdddfed14 Cc: Bernd Kuhls Subject: [Buildroot] [PATCH 1/2] package/perl-db-file: Fix berkeleydb detection X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Without this patch libdb.so is not detected and lib/perl5/site_perl/5.22.0/i586-linux/auto/DB_File/DB_File.so is not linked against it: Parsing config.in... Looks Good. Checking if your kit is complete... Looks good Warning (mostly harmless): No library found for -ldb Generating a Unix-style Makefile Writing Makefile for DB_File Writing MYMETA.yml and MYMETA.json >>> perl-db-file 1.835 Building $ output/host/usr/bin/i586-buildroot-linux-uclibc-readelf -a output/target/usr/lib/perl5/site_perl/5.22.0/i586-linux/auto/DB_File/DB_File.so | grep NEEDED 0x00000001 (NEEDED) Shared library: [libc.so.1] After applying this patch configure output will look like this: Parsing config.in... Looks Good. Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for DB_File Writing MYMETA.yml and MYMETA.json >>> perl-db-file 1.835 Building and the resulting library is correctly linked against libdb: $ output/host/usr/bin/i586-buildroot-linux-uclibc-readelf -a output/target/usr/lib/perl5/site_perl/5.22.0/i586-linux/auto/DB_File/DB_File.so | grep NEEDED 0x00000001 (NEEDED) Shared library: [libdb-5.3.so] 0x00000001 (NEEDED) Shared library: [libc.so.1] Signed-off-by: Bernd Kuhls --- package/perl-db-file/perl-db-file.mk | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/package/perl-db-file/perl-db-file.mk b/package/perl-db-file/perl-db-file.mk index 6d611ea..3db8c56 100644 --- a/package/perl-db-file/perl-db-file.mk +++ b/package/perl-db-file/perl-db-file.mk @@ -11,4 +11,12 @@ PERL_DB_FILE_DEPENDENCIES = berkeleydb PERL_DB_FILE_LICENSE = Artistic or GPLv1+ PERL_DB_FILE_LICENSE_FILES = README +define PERL_DB_FILE_FIX_CONFIG_IN + $(SED) 's%^INCLUDE.*%INCLUDE = $(STAGING_DIR)/usr/include%' \ + $(@D)/config.in + $(SED) 's%^LIB.*%LIB = $(STAGING_DIR)/usr/lib%' \ + $(@D)/config.in +endef +PERL_DB_FILE_POST_PATCH_HOOKS += PERL_DB_FILE_FIX_CONFIG_IN + $(eval $(perl-package))