From patchwork Thu Apr 24 16:26:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Francois Perrad X-Patchwork-Id: 342438 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from hemlock.osuosl.org (hemlock.osuosl.org [140.211.166.133]) by ozlabs.org (Postfix) with ESMTP id 7596A140133 for ; Fri, 25 Apr 2014 02:27:04 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 177F289337; Thu, 24 Apr 2014 16:27:03 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SCAU4u5dz8Oy; Thu, 24 Apr 2014 16:27:01 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 4EC8A892EF; Thu, 24 Apr 2014 16:27:01 +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 69D881C2821 for ; Thu, 24 Apr 2014 16:27:00 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 63E6A8AF62 for ; Thu, 24 Apr 2014 16:27:00 +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 SxEPLHxZefVX for ; Thu, 24 Apr 2014 16:26:59 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wg0-f48.google.com (mail-wg0-f48.google.com [74.125.82.48]) by whitealder.osuosl.org (Postfix) with ESMTPS id 5DF848B228 for ; Thu, 24 Apr 2014 16:26:59 +0000 (UTC) Received: by mail-wg0-f48.google.com with SMTP id l18so2503385wgh.19 for ; Thu, 24 Apr 2014 09:26:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=DtskO1S9At0/kq9CFJzqb/qo8YTplni+RBO0MQjxDUc=; b=INWz87B30k7pA7uQvFDiNLRBAQ111O/Aoi9JQv3d1YQzx4o7a2LeOcsbseEfUugu/4 Q7JazxuuUkGaSXh4JmDYhhtroy248+P1eA+a4zr0dA2l/8ZKw2V7cBtWOKGQ87HLMqrB j/yvYYXu79kVdBzfmI6F2wsjjnJSxIqOmmx7N/q7lB4hMsG2Zz3/aOwoDjTduK3yWL+9 Ojv/6SohMyl651HchPzj8gPPEOrq6u9Zw5WrWz6zznX3Dq+UnFzkweuvYF29300UptQs 21uL0iqiqHpGV6g/1QBhv0Tsn04jSTYyTYE5ro8M2M0Qmt7WX++sSh+C9N+rChnEkv3b nd2w== X-Received: by 10.180.211.239 with SMTP id nf15mr7073987wic.9.1398356817581; Thu, 24 Apr 2014 09:26:57 -0700 (PDT) Received: from localhost.localdomain (181.160.84.79.rev.sfr.net. [79.84.160.181]) by mx.google.com with ESMTPSA id ct2sm6852775wjb.33.2014.04.24.09.26.56 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 24 Apr 2014 09:26:56 -0700 (PDT) X-Google-Original-From: Francois Perrad From: Francois Perrad To: buildroot@busybox.net Date: Thu, 24 Apr 2014 18:26:01 +0200 Message-Id: <1398356762-12486-1-git-send-email-francois.perrad@gadz.org> X-Mailer: git-send-email 1.9.1 Subject: [Buildroot] [V2 1/2] pkg-perl: fix for Perl XS packages configured by Makefile.PL 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: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net ExtUtils::MakeMaker adds all the header files used by the perl as dependencies to the generated Makefile. This means that the generated Makefile will depend on the system's header files. Usually this is not a problem, because when building the target package, these header files will indeed be found in $(STAGING_DIR). However, some distro's add an extra header file to the system's perl. This header is also included in the generated Makefile, which makes the build fail because it doesn't exist in $(STAGING_DIR). As a work-around, explicitly create this header file in $(STAGING_DIR). It doesn't hurt to create it even if the system perl doesn't need it. Signed-off-by: Francois Perrad Acked-by: Arnout Vandecappelle (Essensium/Mind) --- package/perl/perl.mk | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/package/perl/perl.mk b/package/perl/perl.mk index 51aeb14..64ad7d3 100644 --- a/package/perl/perl.mk +++ b/package/perl/perl.mk @@ -94,4 +94,25 @@ define PERL_INSTALL_TARGET_CMDS $(MAKE1) -C $(@D) DESTDIR="$(TARGET_DIR)" install.perl endef +# perl infra: fix for Perl XS packages configured by Makefile.PL +# +# ExtUtils::MakeMaker adds all the header files used by the perl as +# dependencies to the generated Makefile. This means that the generated +# Makefile will depend on the system's header files. +# +# Usually this is not a problem, because when building the target package, +# these header files will indeed be found in $(STAGING_DIR). However, some +# distro's add an extra header file to the system's perl. This header is +# also included in the generated Makefile, which makes the build fail +# because it doesn't exist in $(STAGING_DIR). +# +# As a work-around, explicitly create this header file in $(STAGING_DIR). +# It doesn't hurt to create it even if the system perl doesn't need it. +# +define PERL_ADD_PATCHLEVEL_DEBIAN_H + touch $(STAGING_DIR)/usr/lib/perl5/$(PERL_VERSION)/$(PERL_ARCHNAME)/CORE/patchlevel-debian.h +endef + +PERL_POST_INSTALL_STAGING_HOOKS += PERL_ADD_PATCHLEVEL_DEBIAN_H + $(eval $(generic-package))