From patchwork Sun Jul 5 11:15:00 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Petazzoni X-Patchwork-Id: 491306 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 E0EB1140D5D for ; Sun, 5 Jul 2015 21:15:10 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id D7B9AA2D1B; Sun, 5 Jul 2015 11:15:09 +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 umN2-Z8VzREe; Sun, 5 Jul 2015 11:15:09 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 30776A2D24; Sun, 5 Jul 2015 11:15:09 +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 A5BF21C25EE for ; Sun, 5 Jul 2015 11:15:07 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 9FFF6A2D24 for ; Sun, 5 Jul 2015 11:15:07 +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 WkQ7-lf-0Qgq for ; Sun, 5 Jul 2015 11:15:06 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail.free-electrons.com (down.free-electrons.com [37.187.137.238]) by fraxinus.osuosl.org (Postfix) with ESMTP id DA9F7A2D1B for ; Sun, 5 Jul 2015 11:15:05 +0000 (UTC) Received: by mail.free-electrons.com (Postfix, from userid 106) id 78CF11F44; Sun, 5 Jul 2015 13:15:08 +0200 (CEST) Received: from localhost (132.230.147.77.rev.sfr.net [77.147.230.132]) by mail.free-electrons.com (Postfix) with ESMTPSA id 283113C3; Sun, 5 Jul 2015 13:15:08 +0200 (CEST) From: Thomas Petazzoni To: buildroot@uclibc.org Date: Sun, 5 Jul 2015 13:15:00 +0200 Message-Id: <1436094900-3217-1-git-send-email-thomas.petazzoni@free-electrons.com> X-Mailer: git-send-email 2.4.5 Cc: Thomas Petazzoni Subject: [Buildroot] [PATCH] wine: fix sane related build failure 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" If sane is installed system-wide on the build machine, then the sane-config binary found is the one of the system, which returns incorrect library paths for cross-compilation. To fix this, this commit adds a patch to wine to make it support a SANE_CONFIG environment variable, and then adjusts wine.mk to explicitly pass the path to $(STAGING_DIR)/usr/bin/sane-config. Fixes: http://autobuild.buildroot.org/results/8bd/8bdc1eed55075313403aa8a6c9af6a427bce198e/ Signed-off-by: Thomas Petazzoni Acked-by: "Yann E. MORIN" --- package/wine/0003-sane-config-fix.patch | 21 +++++++++++++++++++++ package/wine/wine.mk | 1 + 2 files changed, 22 insertions(+) create mode 100644 package/wine/0003-sane-config-fix.patch diff --git a/package/wine/0003-sane-config-fix.patch b/package/wine/0003-sane-config-fix.patch new file mode 100644 index 0000000..d53843a --- /dev/null +++ b/package/wine/0003-sane-config-fix.patch @@ -0,0 +1,21 @@ +Add support for SANE_CONFIG variable + +Instead of using directly the sane-config command, allow to pass a +SANE_CONFIG environment variable to override where to find the +sane-config tool. + +Signed-off-by: Thomas Petazzoni + +Index: b/configure.ac +=================================================================== +--- a/configure.ac ++++ b/configure.ac +@@ -1375,7 +1375,7 @@ + if test "x$with_sane" != "xno" + then + ac_save_CPPFLAGS="$CPPFLAGS" +- WINE_PACKAGE_FLAGS(SANE,[libsane],,[`sane-config --cflags 2>/dev/null`],[`sane-config --ldflags 2>/dev/null`]) ++ WINE_PACKAGE_FLAGS(SANE,[libsane],,[`${SANE_CONFIG:-sane-config} --cflags 2>/dev/null`],[`${SANE_CONFIG:-sane-config} --ldflags 2>/dev/null`]) + AC_CHECK_HEADER(sane/sane.h, + [WINE_CHECK_SONAME(sane,sane_init,,[SANE_CFLAGS=""],[$SANE_LIBS])], + [SANE_CFLAGS=""]) diff --git a/package/wine/wine.mk b/package/wine/wine.mk index 1ae038e..d6fb9c6 100644 --- a/package/wine/wine.mk +++ b/package/wine/wine.mk @@ -174,6 +174,7 @@ endif ifeq ($(BR2_PACKAGE_SANE_BACKENDS),y) WINE_CONF_OPTS += --with-sane WINE_DEPENDENCIES += sane-backends +WINE_CONF_ENV += SANE_CONFIG=$(STAGING_DIR)/usr/bin/sane-config else WINE_CONF_OPTS += --without-sane endif