From patchwork Tue Oct 6 10:56:15 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Lukichev X-Patchwork-Id: 526694 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 99481140D57 for ; Tue, 6 Oct 2015 21:56:28 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=V/BDu88B; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id B7919A2F63; Tue, 6 Oct 2015 10:56:27 +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 MM_Tz-Zaruph; Tue, 6 Oct 2015 10:56:27 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 24765A2F6E; Tue, 6 Oct 2015 10:56:27 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 120AB1C10DA for ; Tue, 6 Oct 2015 10:56:26 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 00A7F8DD20 for ; Tue, 6 Oct 2015 10:56:26 +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 WjntcE38enyq for ; Tue, 6 Oct 2015 10:56:25 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-lb0-f180.google.com (mail-lb0-f180.google.com [209.85.217.180]) by whitealder.osuosl.org (Postfix) with ESMTPS id 1429B8C572 for ; Tue, 6 Oct 2015 10:56:25 +0000 (UTC) Received: by lbcao8 with SMTP id ao8so73893431lbc.3 for ; Tue, 06 Oct 2015 03:56:23 -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=WrTNDCx3/MgHuEqd6a0F5FXr0IkhgLe2QZkrUHDUQp0=; b=V/BDu88BEBBy1Qj9aOFLqR2eCZR7hz5c8SVxq07Y3OwC5qRP0que3u3GyjZeyzx83P JV5bwUenXBKpmlWx6d2pvo7XsqDrYkyb4qh0t3FwRU3xRxa7X/I6UIEUmTcDi18QN3Rm J2Y4DWqWaMhhxbNUJxZK0iDJKzEB6MCYrLiAXtaziMgpML4LIBGs7I1i3qG9onXXEAzU 3zEx2pXPYM4LbUwvH14kbHzSOLOBJMjdqNCVDpK8L4BHR81CNJGWD3ey3+E48TXHo5n+ Fl0NM1Sdq0jNRElk9RvSszaNxri15YKoqUroqsTRJ+pYTj42CP3aUHzxFu/krouaGq7V CCpw== X-Received: by 10.112.64.72 with SMTP id m8mr13882752lbs.41.1444128983081; Tue, 06 Oct 2015 03:56:23 -0700 (PDT) Received: from localhost.localdomain (37-219-231-55.nat.bb.dnainternet.fi. [37.219.231.55]) by smtp.googlemail.com with ESMTPSA id c193sm5196675lfc.41.2015.10.06.03.56.21 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 06 Oct 2015 03:56:22 -0700 (PDT) From: Alexander Lukichev To: buildroot@buildroot.org Date: Tue, 6 Oct 2015 13:56:15 +0300 Message-Id: <1444128975-17943-1-git-send-email-alexander.lukichev@gmail.com> X-Mailer: git-send-email 2.6.1 Subject: [Buildroot] [PATCH 1/1] qt: fix build for arm with BR2_STATIC_LIBS 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" Some Buildroot-generated static toolchains for ARM do not have dlfcn.h header, which breaks builds of qt-4.8.7 because its QtCore's plugin loader expects this header to be present (and dynamic libraries to be supported). For certain platforms without dynamic libraries, there is a QT_NO_DYNAMIC_LIBRARY constant defined in plugin loader's source. This patch puts that constant into Qt's build environment if Buildroot is configured without shared library support, and prevents plugin loader from defining it if it has already been defined. Fixes: - http://autobuild.buildroot.net/results/11a4c19638ca211bd2a424fd92602166235c9433 - http://autobuild.buildroot.net/results/c056e8781558267f6971a5f017f47e90dcf24e07 - http://autobuild.buildroot.net/results/b8f34afa8686e890a1a3882a52081bb6a3b9c13b and several others. Signed-off-by: Alexander Lukichev --- package/qt/0009-no-dynamic-library-plugins.patch | 27 ++++++++++++++++++++++++ package/qt/qt.mk | 4 ++++ 2 files changed, 31 insertions(+) create mode 100644 package/qt/0009-no-dynamic-library-plugins.patch diff --git a/package/qt/0009-no-dynamic-library-plugins.patch b/package/qt/0009-no-dynamic-library-plugins.patch new file mode 100644 index 0000000..3836677 --- /dev/null +++ b/package/qt/0009-no-dynamic-library-plugins.patch @@ -0,0 +1,27 @@ +Do not define QT_NO_DYNAMIC_LIBRARY if it is already defined + +QtCore plugin loader behaves correctly on platforms that do not support +dynamic libraries. This is implemented by QT_NO_DYNAMIC_LIBRARY constant +defined at compile time in the loader's source for specific platforms. +Since Buildroot does not have a separate platform defined for it in +mkspecs, if shared libraries are not supported by its configuration, the +constant is specified in Qt's build environment. This patch prevents +compilation error in such cases. + +Signed-off-by: Alexander Lukichev + +diff -uNrp qt-4.8.7.orig/src/corelib/plugin/qlibrary_unix.cpp qt-4.8.7/src/corelib/plugin/qlibrary_unix.cpp +--- qt-4.8.7.orig/src/corelib/plugin/qlibrary_unix.cpp 2015-05-07 17:14:48.000000000 +0300 ++++ qt-4.8.7/src/corelib/plugin/qlibrary_unix.cpp 2015-10-06 08:53:27.189232642 +0300 +@@ -56,9 +56,11 @@ + #include + #endif + ++#ifndef QT_NO_DYNAMIC_LIBRARY + #if (defined(Q_OS_VXWORKS) && !defined(VXWORKS_RTP)) || defined (Q_OS_NACL) + #define QT_NO_DYNAMIC_LIBRARY + #endif ++#endif + + QT_BEGIN_NAMESPACE + diff --git a/package/qt/qt.mk b/package/qt/qt.mk index e0e5d22..a64d32f 100644 --- a/package/qt/qt.mk +++ b/package/qt/qt.mk @@ -203,6 +203,10 @@ else QT_CONFIGURE_OPTS += -static endif +ifeq ($(BR2_STATIC_LIBS),y) +QT_CONFIGURE_OPTS += -D QT_NO_DYNAMIC_LIBRARY +endif + ifeq ($(BR2_ENDIAN),"LITTLE") QT_CONFIGURE_OPTS += -little-endian else