From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id AGyHJdsb1mCkHwEAgWs5BA (envelope-from ) for ; Fri, 25 Jun 2021 20:09:31 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id CBcpIdsb1mAYcAAAbx9fmQ (envelope-from ) for ; Fri, 25 Jun 2021 18:09:31 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 009BA2CAF5 for ; Fri, 25 Jun 2021 20:09:31 +0200 (CEST) Received: from localhost ([::1]:43464 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lwqGg-00062S-1f for larch@yhetil.org; Fri, 25 Jun 2021 14:09:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:57276) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lwqGF-0005EZ-R7 for guix-patches@gnu.org; Fri, 25 Jun 2021 14:09:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:35235) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lwqGF-0006fp-Hz for guix-patches@gnu.org; Fri, 25 Jun 2021 14:09:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lwqGF-0003eL-Du for guix-patches@gnu.org; Fri, 25 Jun 2021 14:09:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49227] [PATCH 3/3] gnu: qtbase: Specify configure flags via the #:configure-flags argument. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 25 Jun 2021 18:09:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49227 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 49227@debbugs.gnu.org Cc: Maxim Cournoyer Received: via spool by 49227-submit@debbugs.gnu.org id=B49227.162464453814004 (code B ref 49227); Fri, 25 Jun 2021 18:09:03 +0000 Received: (at 49227) by debbugs.gnu.org; 25 Jun 2021 18:08:58 +0000 Received: from localhost ([127.0.0.1]:46779 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lwqGA-0003dn-0U for submit@debbugs.gnu.org; Fri, 25 Jun 2021 14:08:58 -0400 Received: from mail-qk1-f177.google.com ([209.85.222.177]:41855) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lwqG7-0003dP-Op for 49227@debbugs.gnu.org; Fri, 25 Jun 2021 14:08:56 -0400 Received: by mail-qk1-f177.google.com with SMTP id bl4so20026161qkb.8 for <49227@debbugs.gnu.org>; Fri, 25 Jun 2021 11:08:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=xbc9+1Im2HgmXPnP4TO0QngXNMklPFcv0neaEwRXvp0=; b=XRvdAEl8mIDF1sRTyGYnen7pO1gm9YoV+JW3ytkGncDZx0jkWmPMM1ooelvWFIdn9b a80dU9/Ykf8xIzJl2bosGqTmHamVNMWXJ1lfAxEuXpduQ/H/M5iM9d/Y7BcLQ9/EeRyO 6ylILIwZH/0rY/UzJeHe2ZOtL/6IRnCk1g3ezsxCEHcvBUJNtfyEjBhAkShUUe4zRrtf P/PGUq7yHry7+HkmNM+PL70gV2mfGDuqlYKUOvo97elASdc9v+dU2pXUvWyU4qwxk04i zV/SIH7brCC3QmcbtzflMTseRwmbQuHxjDu/x5oA6m333UFL3NaX9UgNL875SoBnZijs vUdw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=xbc9+1Im2HgmXPnP4TO0QngXNMklPFcv0neaEwRXvp0=; b=KAyAHPCHh8Ug4LcMYPryqzIwSRO/44od2+COu7W2CRstqvWkALFCo7N3y5VZEXhAGj SNkwrk6WpiAPTK317NP1kTAs8SnjMgyCZuKaQTFflPs5SuyH97/2FhI5ydakQ+p2ELeG j5Vnvg1zc0gzZ/CiE1PslbI3lc9oD4XM4X1+KVXKYSXfGYPdZ3bLrHCMZM+4qKb7DSzP 0U+d5XH5WJHu4Jp4JknoyklaTnTupC9zwkh+ojI5M/MVdl6igk0fC++ByW5b+pfpHmBH ZHZfLFQLCpWuxu6hTRg1s6PE8Yor+6HN8JxRvw/2gRRym0Xjx/mNpSm1M1iSlA59Qs+n XykQ== X-Gm-Message-State: AOAM533NxJuUQN4R5DwJKAp8mRdFqT3E9PYP0aDhLX7kj1F5HpCpcX/R A7qttsDmwee621v7YIur5PurJOyNA+Xkgo7T X-Google-Smtp-Source: ABdhPJzsfWIJGNynVjTiVkD/S1Le2lzxRFx5gumGsPtFjvDcPHure/NelZ/08iJJgkd/tfowTHK/rw== X-Received: by 2002:a05:620a:ed3:: with SMTP id x19mr8816092qkm.296.1624644530237; Fri, 25 Jun 2021 11:08:50 -0700 (PDT) Received: from localhost.localdomain (dsl-10-149-111.b2b2c.ca. [72.10.149.111]) by smtp.gmail.com with ESMTPSA id v5sm5428036qkh.39.2021.06.25.11.08.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Jun 2021 11:08:50 -0700 (PDT) From: Maxim Cournoyer Date: Fri, 25 Jun 2021 14:08:23 -0400 Message-Id: <20210625180823.10382-3-maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210625180823.10382-1-maxim.cournoyer@gmail.com> References: <20210625180823.10382-1-maxim.cournoyer@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1624644571; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=xbc9+1Im2HgmXPnP4TO0QngXNMklPFcv0neaEwRXvp0=; b=oabQEddLwdObYutAY6z4Op4VtUpPqACDYOpi1UCs8JNHsehyoZfCI00Ni//zdnrPQFKQfX QXgS4UKCst76YED/RR0d8ResL5kuAKoASD8p+ToODeyPfOPvvOAW+P2D9qt/PM4D/uAhAf Itbi03r/AwUhEoeTkjxh1I3oPP5AS+LIUQsvoUJrcUc4VBOYWC1+T5yS7PwqYfxZLe9lOa B7RAn47OO8UlyjoTiZNUwRr+KP2IZ3VZA2xJrylvFGHYYuWMhFArU0Ezb/H84HraMto7kh yQng1H3gdLCsQ8NaWXuczHde7L6OZH6Try9SGw3AnC4qTDxaolTw/OplUQMYEQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1624644571; a=rsa-sha256; cv=none; b=EQM2L7G3St5+xkXW99MJ4cimGri3BUyJ/730cjFr+14OBhYltC9ibmkm2sCZHcGpycTQ0O goWNnqJdW34sL9fnQYsdm08GKr8/8BlOfsOptlMlkpqu6asn1sc/4PGj6AnYY4fRov23OY OA5vnvs13bRsWd2x8QO6ks4w5jWw/7tM5G1CPSnoeJcQVRYMoplPOn9rg2rP4cwQcPcm5U 6E9zAVX4P74qJA3IAXVmNgMgYGeWDPHn00nxrFqLM3z1ZEFCr+dX5CQ7zm5W4jCSUuAQn4 MqGmSbY5RNoWGLrIAhb+crVKgKRp3w8kdMAmRfFPp9XpT8XjOXc0/+nuO4zCCw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=XRvdAEl8; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: 2.67 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=XRvdAEl8; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 009BA2CAF5 X-Spam-Score: 2.67 X-Migadu-Scanner: scn0.migadu.com X-TUID: x4BXtjNIy3dz * gnu/packages/qt.scm (qtbase): Delete trailing #t. [phases]{configure}: Print build directory and configure flags. Move configure flags to... [#:configure-flags]: ... this new argument. --- gnu/packages/qt.scm | 167 ++++++++++++++++++++++---------------------- 1 file changed, 82 insertions(+), 85 deletions(-) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index dadfbfecb5..0a9fdb965f 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -303,25 +303,24 @@ system, and the core design of Django is reused in Grantlee.") (name "qtbase") (version "5.15.2") (source (origin - (method url-fetch) - (uri (qt5-urls name version)) - (sha256 - (base32 - "1y70libf2x52lpbqvhz10lpk7nyl1ajjwzjxly9pjdpfj4jsv7wh")) - ;; Use TZDIR to avoid depending on package "tzdata". - (patches (search-patches "qtbase-use-TZDIR.patch" - "qtbase-moc-ignore-gcc-macro.patch" - "qtbase-absolute-runpath.patch")) - (modules '((guix build utils))) - (snippet + (method url-fetch) + (uri (qt5-urls name version)) + (sha256 + (base32 + "1y70libf2x52lpbqvhz10lpk7nyl1ajjwzjxly9pjdpfj4jsv7wh")) + ;; Use TZDIR to avoid depending on package "tzdata". + (patches (search-patches "qtbase-use-TZDIR.patch" + "qtbase-moc-ignore-gcc-macro.patch" + "qtbase-absolute-runpath.patch")) + (modules '((guix build utils))) + (snippet ;; corelib uses bundled harfbuzz, md4, md5, sha3 - '(begin - (with-directory-excursion "src/3rdparty" - (for-each delete-file-recursively - (list "double-conversion" "freetype" "harfbuzz-ng" - "libpng" "libjpeg" "pcre2" "sqlite" "xcb" - "zlib")) - #t))))) + '(begin + (with-directory-excursion "src/3rdparty" + (for-each delete-file-recursively + (list "double-conversion" "freetype" "harfbuzz-ng" + "libpng" "libjpeg" "pcre2" "sqlite" "xcb" + "zlib"))))))) (build-system gnu-build-system) (outputs '("out" "debug")) (propagated-inputs @@ -383,7 +382,56 @@ system, and the core design of Django is reused in Grantlee.") ("vulkan-headers" ,vulkan-headers) ("ruby" ,ruby))) (arguments - `(#:phases + `(#:configure-flags + (let ((out (assoc-ref %outputs "out"))) + (list "-verbose" + "-prefix" out + "-docdir" (string-append out "/share/doc/qt5") + "-headerdir" (string-append out "/include/qt5") + "-archdatadir" (string-append out "/lib/qt5") + "-datadir" (string-append out "/share/qt5") + "-examplesdir" (string-append + out "/share/doc/qt5/examples") + "-opensource" + "-confirm-license" + + ;; Later stripped into the :debug output. + "-force-debug-info" + + ;; These features require higher versions of Linux than the + ;; minimum version of the glibc. See + ;; src/corelib/global/minimum-linux_p.h. By disabling these + ;; features Qt5 applications can be used on the oldest + ;; kernels that the glibc supports, including the RHEL6 + ;; (2.6.32) and RHEL7 (3.10) kernels. + "-no-feature-getentropy" ; requires Linux 3.17 + "-no-feature-renameat2" ; requires Linux 3.16 + + ;; Do not build examples; if desired, these could go + ;; into a separate output, but for the time being, we + ;; prefer to save the space and build time. + "-no-compile-examples" + ;; Most "-system-..." are automatic, but some use + ;; the bundled copy by default. + "-system-sqlite" + "-system-harfbuzz" + "-system-pcre" + ;; explicitly link with openssl instead of dlopening it + "-openssl-linked" + ;; explicitly link with dbus instead of dlopening it + "-dbus-linked" + ;; don't use the precompiled headers + "-no-pch" + ;; drop special machine instructions that do not have + ;; runtime detection + ,@(if (string-prefix? "x86_64" + (or (%current-target-system) + (%current-system))) + '() + '("-no-sse2")) + "-no-mips_dsp" + "-no-mips_dspr2")) + #:phases (modify-phases %standard-phases (add-after 'configure 'patch-bin-sh (lambda _ @@ -391,18 +439,18 @@ system, and the core design of Django is reused in Grantlee.") "configure" "mkspecs/features/qt_functions.prf" "qmake/library/qmakebuiltins.cpp") - (("/bin/sh") (which "sh"))) - #t)) + (("/bin/sh") (which "sh"))))) (add-after 'configure 'patch-xdg-open (lambda _ (substitute* '("src/platformsupport/services/genericunix/qgenericunixservices.cpp") - (("^.*const char \\*browsers.*$" all) - (string-append "*browser = QStringLiteral(\"" - (which "xdg-open") - "\"); return true; \n" all))) - #t)) + (("^.*const char \\*browsers.*$" all) + (string-append "*browser = QStringLiteral(\"" + (which "xdg-open") + "\"); return true; \n" all))))) (replace 'configure - (lambda* (#:key outputs #:allow-other-keys) + ;; Overridden to not pass "--enable-fast-install", which makes the + ;; configure process fail. + (lambda* (#:key outputs configure-flags #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (substitute* "configure" (("/bin/pwd") (which "pwd"))) @@ -415,57 +463,9 @@ system, and the core design of Django is reused in Grantlee.") ;; components can be installed in different places. (substitute* (find-files "." ".*\\.cmake") (("NO_DEFAULT_PATH") "")) - ;; do not pass "--enable-fast-install", which makes the - ;; configure process fail - (invoke - "./configure" - "-verbose" - "-prefix" out - "-docdir" (string-append out "/share/doc/qt5") - "-headerdir" (string-append out "/include/qt5") - "-archdatadir" (string-append out "/lib/qt5") - "-datadir" (string-append out "/share/qt5") - "-examplesdir" (string-append - out "/share/doc/qt5/examples") - "-opensource" - "-confirm-license" - - ;; Later stripped into the :debug output. - "-force-debug-info" - - ;; These features require higher versions of Linux than the - ;; minimum version of the glibc. See - ;; src/corelib/global/minimum-linux_p.h. By disabling these - ;; features Qt5 applications can be used on the oldest - ;; kernels that the glibc supports, including the RHEL6 - ;; (2.6.32) and RHEL7 (3.10) kernels. - "-no-feature-getentropy" ; requires Linux 3.17 - "-no-feature-renameat2" ; requires Linux 3.16 - - ;; Do not build examples; if desired, these could go - ;; into a separate output, but for the time being, we - ;; prefer to save the space and build time. - "-no-compile-examples" - ;; Most "-system-..." are automatic, but some use - ;; the bundled copy by default. - "-system-sqlite" - "-system-harfbuzz" - "-system-pcre" - ;; explicitly link with openssl instead of dlopening it - "-openssl-linked" - ;; explicitly link with dbus instead of dlopening it - "-dbus-linked" - ;; don't use the precompiled headers - "-no-pch" - ;; drop special machine instructions that do not have - ;; runtime detection - ,@(if (string-prefix? "x86_64" - (or (%current-target-system) - (%current-system))) - '() - '("-no-sse2")) - "-no-mips_dsp" - "-no-mips_dspr2")))) + (format #t "build directory: ~s~%" (getcwd)) + (format #t "configure flags: ~s~%" configure-flags) + (apply invoke "./configure" configure-flags)))) (add-after 'install 'patch-mkspecs (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) @@ -497,8 +497,7 @@ system, and the core design of Django is reused in Grantlee.") '("device_config.prf" "moc.prf" "qt_build_config.prf" "qt_config.prf" "winrt/package_manifest.prf")) (("\\$\\$\\[QT_HOST_DATA/get\\]") archdata) - (("\\$\\$\\[QT_HOST_DATA/src\\]") archdata)) - #t))) + (("\\$\\$\\[QT_HOST_DATA/src\\]") archdata))))) (add-after 'patch-mkspecs 'patch-prl-files (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) @@ -507,8 +506,7 @@ system, and the core design of Django is reused in Grantlee.") ;; on context. See (substitute* (find-files (string-append out "/lib") "\\.prl$") (("\\$\\$\\[QT_INSTALL_LIBS\\]") - (string-append out "/lib"))) - #t))) + (string-append out "/lib")))))) (add-after 'unpack 'patch-paths ;; Use the absolute paths for dynamically loaded libs, otherwise ;; the lib will be searched in LD_LIBRARY_PATH which typically is @@ -520,7 +518,7 @@ system, and the core design of Django is reused in Grantlee.") (substitute* '("src/network/kernel/qdnslookup_unix.cpp" "src/network/kernel/qhostinfo_unix.cpp") (("^\\s*(lib.setFileName\\(QLatin1String\\(\")(resolv\"\\)\\);)" _ a b) - (string-append a glibc "/lib/lib" b)))) + (string-append a glibc "/lib/lib" b)))) ;; libGL (substitute* "src/plugins/platforms/xcb/gl_integrations/xcb_glx/qglxintegration.cpp" (("^\\s*(QLibrary lib\\(QLatin1String\\(\")(GL\"\\)\\);)" _ a b) @@ -530,8 +528,7 @@ system, and the core design of Django is reused in Grantlee.") (("^\\s*(QLibrary xcursorLib\\(QLatin1String\\(\")(Xcursor\"\\), 1\\);)" _ a b) (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b)) (("^\\s*(xcursorLib.setFileName\\(QLatin1String\\(\")(Xcursor\"\\)\\);)" _ a b) - (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b))) - #t))))) + (string-append a (assoc-ref inputs "libxcursor") "/lib/lib" b)))))))) (native-search-paths (list (search-path-specification (variable "QMAKEPATH") -- 2.32.0