Return-Path: Received: from mail1.windriver.com (mail1.windriver.com [147.11.146.13]) by mail.openembedded.org (Postfix) with ESMTP id 900FE6FD3E for ; Thu, 19 Jun 2014 04:45:59 +0000 (UTC) Received: from ALA-HCA.corp.ad.wrs.com (ala-hca.corp.ad.wrs.com [147.11.189.40]) by mail1.windriver.com (8.14.5/8.14.5) with ESMTP id s5J4k0hH020524 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=FAIL) for ; Wed, 18 Jun 2014 21:46:00 -0700 (PDT) Received: from lirq-OptiPlex-780.corp.ad.wrs.com (128.224.162.137) by ALA-HCA.corp.ad.wrs.com (147.11.189.40) with Microsoft SMTP Server id 14.3.169.1; Wed, 18 Jun 2014 21:45:59 -0700 From: To: Date: Thu, 19 Jun 2014 12:46:15 +0800 Message-ID: <1403153175-10707-1-git-send-email-rongqing.li@windriver.com> X-Mailer: git-send-email 1.7.10.4 MIME-Version: 1.0 Subject: [PATCH][meta-oe] dialog: use pkg-config to detect ncurses X-BeenThere: openembedded-devel@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: openembedded-devel@lists.openembedded.org List-Id: Using the OpenEmbedded metadata to build Distributions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jun 2014 04:46:07 -0000 Content-Type: text/plain From: Roy Li Signed-off-by: Roy Li --- meta-oe/recipes-extended/dialog/dialog.inc | 6 ++- .../use-pkg-config-for-ncurses-detection.patch | 40 ++++++++++++++++++++ 2 files changed, 44 insertions(+), 2 deletions(-) create mode 100644 meta-oe/recipes-extended/dialog/files/use-pkg-config-for-ncurses-detection.patch diff --git a/meta-oe/recipes-extended/dialog/dialog.inc b/meta-oe/recipes-extended/dialog/dialog.inc index c1c28fd..995d6c0 100644 --- a/meta-oe/recipes-extended/dialog/dialog.inc +++ b/meta-oe/recipes-extended/dialog/dialog.inc @@ -8,12 +8,14 @@ DEPENDS = "ncurses" LICENSE = "LGPL-2.1" LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343" -SRC_URI = "ftp://invisible-island.net/dialog/dialog-${PV}.tgz" +SRC_URI = "ftp://invisible-island.net/dialog/dialog-${PV}.tgz \ + file://use-pkg-config-for-ncurses-detection.patch \ + " # hardcoded here for use in dialog-static recipe S = "${WORKDIR}/dialog-${PV}" -inherit autotools +inherit autotools-brokensep pkgconfig EXTRA_OECONF = "--with-ncurses \ --disable-rpath-hack" diff --git a/meta-oe/recipes-extended/dialog/files/use-pkg-config-for-ncurses-detection.patch b/meta-oe/recipes-extended/dialog/files/use-pkg-config-for-ncurses-detection.patch new file mode 100644 index 0000000..b5b4b3c --- /dev/null +++ b/meta-oe/recipes-extended/dialog/files/use-pkg-config-for-ncurses-detection.patch @@ -0,0 +1,40 @@ +Subject: [PATCH] use pkg-config for ncurses detection. + +Upstream-Status: Inappropriate [configuration] + +This is a workaround to make dialog be able to build after ncurses-config +does not work, since the configure file is called directly in dialog bb +file, and autoconf can not work, make a workaround in configure file. + +Signed-off-by: Roy Li +--- + configure | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/configure b/configure +index 24e28c1..c78735d 100755 +--- a/configure ++++ b/configure +@@ -9976,8 +9976,8 @@ fi + + if test "$NCURSES_CONFIG" != none ; then + +-CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`" +-LIBS="`$NCURSES_CONFIG --libs` $LIBS" ++CPPFLAGS="$CPPFLAGS `pkg-config --short-errors --print-errors --cflags "ncurses" 2>&1`" ++LIBS="`pkg-config --short-errors --print-errors --libs "ncurses" 2>&1` $LIBS" + + # even with config script, some packages use no-override for curses.h + +@@ -10096,7 +10096,7 @@ cat >>confdefs.h <