2020-09-25 04:45:31 +00:00
|
|
|
/*
|
|
|
|
|
|
|
|
# Updates
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
Run `./fetch.sh` to update package sources from Git.
|
|
|
|
Check for any minor version changes.
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
*/
|
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
{ makeScopeWithSplicing', generateSplicesForMkScope
|
2021-08-22 07:53:02 +00:00
|
|
|
, lib, stdenv, fetchurl, fetchgit, fetchpatch, fetchFromGitHub, makeSetupHook, makeWrapper
|
2022-11-27 09:42:12 +00:00
|
|
|
, bison, cups ? null, harfbuzz, libGL, perl, python3
|
2021-08-22 07:53:02 +00:00
|
|
|
, gstreamer, gst-plugins-base, gtk3, dconf
|
2023-11-16 04:20:00 +00:00
|
|
|
, llvmPackages_15, overrideSDK, overrideLibcxx
|
2021-12-26 17:43:05 +00:00
|
|
|
, darwin
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
# options
|
2021-08-22 07:53:02 +00:00
|
|
|
, developerBuild ? false
|
|
|
|
, decryptSslTraffic ? false
|
|
|
|
, debug ? false
|
2023-03-27 19:17:25 +00:00
|
|
|
, config
|
2020-09-25 04:45:31 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
srcs = import ./srcs.nix { inherit lib fetchgit fetchFromGitHub; };
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
qtCompatVersion = srcs.qtbase.version;
|
|
|
|
|
|
|
|
patches = {
|
2021-08-22 07:53:02 +00:00
|
|
|
qtbase = lib.optionals stdenv.isDarwin [
|
|
|
|
./qtbase.patch.d/0001-qtbase-mkspecs-mac.patch
|
|
|
|
|
|
|
|
# Patch framework detection to support X.framework/X.tbd,
|
|
|
|
# extending the current support for X.framework/X.
|
|
|
|
./qtbase.patch.d/0012-qtbase-tbd-frameworks.patch
|
2022-08-12 12:06:08 +00:00
|
|
|
|
|
|
|
./qtbase.patch.d/0014-aarch64-darwin.patch
|
2021-08-22 07:53:02 +00:00
|
|
|
] ++ [
|
|
|
|
./qtbase.patch.d/0003-qtbase-mkspecs.patch
|
|
|
|
./qtbase.patch.d/0004-qtbase-replace-libdir.patch
|
|
|
|
./qtbase.patch.d/0005-qtbase-cmake.patch
|
|
|
|
./qtbase.patch.d/0006-qtbase-gtk3.patch
|
|
|
|
./qtbase.patch.d/0007-qtbase-xcursor.patch
|
|
|
|
./qtbase.patch.d/0008-qtbase-tzdir.patch
|
|
|
|
./qtbase.patch.d/0009-qtbase-qtpluginpath.patch
|
|
|
|
./qtbase.patch.d/0010-qtbase-assert.patch
|
|
|
|
./qtbase.patch.d/0011-fix-header_module.patch
|
|
|
|
];
|
2022-11-21 17:40:18 +00:00
|
|
|
qtdeclarative = [
|
|
|
|
./qtdeclarative.patch
|
|
|
|
# prevent headaches from stale qmlcache data
|
|
|
|
./qtdeclarative-default-disable-qmlcache.patch
|
2024-01-25 14:12:00 +00:00
|
|
|
# add version specific QML import path
|
|
|
|
./qtdeclarative-qml-paths.patch
|
2022-11-21 17:40:18 +00:00
|
|
|
];
|
2023-11-16 04:20:00 +00:00
|
|
|
qtlocation = lib.optionals stdenv.cc.isClang [
|
|
|
|
# Fix build with Clang 16
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/boostorg/numeric_conversion/commit/50a1eae942effb0a9b90724323ef8f2a67e7984a.patch";
|
|
|
|
stripLen = 1;
|
|
|
|
extraPrefix = "src/3rdparty/mapbox-gl-native/deps/boost/1.65.1/";
|
|
|
|
hash = "sha256-UEvIXzn387f9BAeBdhheStD/4M7en+rmqX8C6gstl6k=";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
qtmultimedia = lib.optionals stdenv.isDarwin [
|
|
|
|
# build patch for qtmultimedia with xcode 15
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://raw.githubusercontent.com/Homebrew/formula-patches/3f509180/qt5/qt5-qtmultimedia-xcode15.patch";
|
|
|
|
stripLen = 1;
|
|
|
|
hash = "sha256-HrEqfmm8WbapWgLM0L4AKW8168pwT2zYI8HOJruEPSs=";
|
|
|
|
})
|
|
|
|
];
|
2023-07-15 17:15:38 +00:00
|
|
|
qtpim = [
|
|
|
|
## Upstream patches after the Qt6 transition that apply without problems & fix bugs
|
|
|
|
|
|
|
|
# Fixes QList -> QSet conversion
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/f337e281e28904741a3b1ac23d15c3a83ef2bbc9.patch";
|
|
|
|
hash = "sha256-zlxD45JnbhIgdJxMmGxGMUBcQPcgzpu3s4bLX939jL0=";
|
|
|
|
})
|
|
|
|
# Fixes invalid syntax from a previous bad patch in tests
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/2aefdd8bd28a4decf9ef8381f5b255f39f1ee90c.patch";
|
|
|
|
hash = "sha256-mg93QF3hi50igw1/Ok7fEs9iCaN6co1+p2/5fQtxTmc=";
|
|
|
|
})
|
|
|
|
# Unit test account for QList index change
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/79b41af6a4117f5efb0298289e20c30b4d0b0b2e.patch";
|
|
|
|
hash = "sha256-u+cLl4lu6r2+j5GAiasqbB6/OZPz5A6GpSB33vd/VBg=";
|
|
|
|
})
|
|
|
|
# Remove invalid method overload which confuses the QML engine
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/5679a6141c76ae7d64c3acc8a87b1adb048289e0.patch";
|
|
|
|
hash = "sha256-z8f8kLhC9CqBOfGPL8W9KJq7MwALAAicXfRkHiQEVJ4=";
|
|
|
|
})
|
|
|
|
# Specify enum flag type properly in unit test
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/a43cc24e57db8d3c3939fa540d67da3294dcfc5c.patch";
|
|
|
|
hash = "sha256-SsYkxX6prxi8VRZr4az+wqawcRN8tR3UuIFswJL+3T4=";
|
|
|
|
})
|
|
|
|
# Update qHash methods to return size_t instead of uint
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/9c698155d82fc2b68a87c59d0443c33f9085b117.patch";
|
|
|
|
hash = "sha256-rb8D8taaglhQikYSAPrtLvazgIw8Nga/a9+J21k8gIo=";
|
|
|
|
})
|
|
|
|
# Mark virtual methods with override keyword
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/f34cf2ff2b0f428d5b8a70763b29088075ebbd1c.patch";
|
|
|
|
hash = "sha256-tNPOEVpx1eqHx5T23ueW32KxMQ/SB+TBCJ4PZ6SA3LI=";
|
|
|
|
})
|
|
|
|
# Fix calendardemo example
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/a66590d473753bc49105d3132fb9e4150c92a14a.patch";
|
|
|
|
hash = "sha256-RPRtGQ24NQYewnv6+IqYITpwD/XxuK68a1iKgFmKm3c=";
|
|
|
|
})
|
|
|
|
# Make the tests pass on big endian systems
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/7802f038ed1391078e27fa3f37d785a69314537b.patch";
|
|
|
|
hash = "sha256-hogUXyPXjGE0q53PWOjiQbQ2YzOsvrJ7mo9djGIbjVQ=";
|
|
|
|
})
|
|
|
|
# Fix some deprecated QChar constructor issues in unit tests
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/114615812dcf9398c957b0833e860befe15f840f.patch";
|
|
|
|
hash = "sha256-yZ1qs8y5DSq8FDXRPyuSPRIzjEUTWAhpVide/b+xaLQ=";
|
|
|
|
})
|
|
|
|
# Accessors should be const
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/a2bf7cdf05c264b5dd2560f799760b5508f154e4.patch";
|
|
|
|
hash = "sha256-+YfPrKyOKnPkqFokwW/aDsEivg4TzdJwQpDdAtM+rQE=";
|
|
|
|
})
|
|
|
|
# Enforce detail access constraints in contact operations by default
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/8765a35233aa21a932ee92bbbb92a5f8edd4dc68.patch";
|
|
|
|
hash = "sha256-vp/enerVecEXz4zyxQ66DG+fVVWxI4bYnLj92qaaqNk=";
|
|
|
|
})
|
|
|
|
# Fixes broken file generation, which breaks reverse dependencies that try to find one of its modules
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/qt/qtpim/commit/4b2bdce30bd0629c9dc0567af6eeaa1d038f3152.patch";
|
|
|
|
hash = "sha256-2dXhkZyxPvY2KQq2veerAlpXkpU5/FeArWRlm1aOcEY=";
|
|
|
|
})
|
|
|
|
|
|
|
|
## Patches that haven't been upstreamed
|
|
|
|
|
|
|
|
# Fix tst_QContactManager::compareVariant_data test
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://salsa.debian.org/qt-kde-team/qt/qtpim/-/raw/360682f88457b5ae7c92f32f574e51ccc5edbea0/debian/patches/1001_fix-qtdatetime-null-comparison.patch";
|
|
|
|
hash = "sha256-k/rO9QjwSlRChwFTZLkxDjZWqFkua4FNbaNf1bJKLxc=";
|
|
|
|
})
|
|
|
|
# Avoid crash while parsing vCards from different threads
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://salsa.debian.org/qt-kde-team/qt/qtpim/-/raw/360682f88457b5ae7c92f32f574e51ccc5edbea0/debian/patches/1002_Avoid-crash-while-parsing-vcards-from-different-threads.patch";
|
|
|
|
hash = "sha256-zhayAoWgcmKosEGVBy2k6a2e6BxyVwfGX18tBbzqEk8=";
|
|
|
|
})
|
|
|
|
# Adapt to JSON parser behavior change in Qt 5.15
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://salsa.debian.org/qt-kde-team/qt/qtpim/-/raw/360682f88457b5ae7c92f32f574e51ccc5edbea0/debian/patches/1003_adapt_to_json_parser_change.patch";
|
|
|
|
hash = "sha256-qAIa48hmDd8vMH/ywqW+22vISKai76XnjgFuB+tQbIU=";
|
|
|
|
})
|
|
|
|
# Fix version being 0.0.0
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://salsa.debian.org/qt-kde-team/qt/qtpim/-/raw/360682f88457b5ae7c92f32f574e51ccc5edbea0/debian/patches/2000_revert_module_version.patch";
|
|
|
|
hash = "sha256-6wg/eVu9J83yvIO428U1FX3otz58tAy6pCvp7fqOBKU=";
|
|
|
|
})
|
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
qtscript = [ ./qtscript.patch ];
|
|
|
|
qtserialport = [ ./qtserialport.patch ];
|
2023-04-29 16:46:19 +00:00
|
|
|
qtsystems = [
|
2024-07-01 15:47:52 +00:00
|
|
|
# Fix crash if no X11 display available
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://salsa.debian.org/qt-kde-team/qt/qtsystems/-/raw/1a4df40671d6f1bb0657a9dfdae4cd9bd48fcf21/debian/patches/1005_check_XOpenDisplay.patch";
|
|
|
|
hash = "sha256-/onla2nlUSySEgz2IYOYajx/LZkJzAKDyxwAZzy0Ivs=";
|
|
|
|
})
|
|
|
|
|
2023-04-29 16:46:19 +00:00
|
|
|
# Enable building with udisks support
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://salsa.debian.org/qt-kde-team/qt/qtsystems/-/raw/a23fd92222c33479d7f3b59e48116def6b46894c/debian/patches/2001_build_with_udisk.patch";
|
|
|
|
hash = "sha256-B/z/+tai01RU/bAJSCp5a0/dGI8g36nwso8MiJv27YM=";
|
|
|
|
})
|
|
|
|
];
|
2022-11-27 09:42:12 +00:00
|
|
|
qtwebengine = [
|
2023-08-22 20:05:09 +00:00
|
|
|
./qtwebengine-link-pulseaudio.patch
|
2024-06-20 14:57:18 +00:00
|
|
|
# Fixes Chromium build failure with Ninja 1.12.
|
|
|
|
# See: https://bugreports.qt.io/browse/QTBUG-124375
|
|
|
|
# Backport of: https://code.qt.io/cgit/qt/qtwebengine-chromium.git/commit/?id=a766045f65f934df3b5f1aa63bc86fbb3e003a09
|
|
|
|
./qtwebengine-ninja-1.12.patch
|
2022-11-27 09:42:12 +00:00
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
2021-03-20 04:20:00 +00:00
|
|
|
./qtwebengine-darwin-no-platform-check.patch
|
|
|
|
./qtwebengine-mac-dont-set-dsymutil-path.patch
|
2023-01-20 10:41:00 +00:00
|
|
|
./qtwebengine-darwin-checks.patch
|
2021-03-20 04:20:00 +00:00
|
|
|
];
|
2020-12-25 13:55:36 +00:00
|
|
|
qtwebkit = [
|
2024-05-15 15:35:15 +00:00
|
|
|
(fetchpatch {
|
|
|
|
name = "qtwebkit-python39-json.patch";
|
|
|
|
url = "https://github.com/qtwebkit/qtwebkit/commit/78360c01c796b6260bf828bc9c8a0ef73c5132fd.patch";
|
|
|
|
sha256 = "yCX/UL666BPxjnxT6rIsUrJsPcSWHhZwMFJfuHhbkhk=";
|
|
|
|
})
|
2020-11-15 13:44:38 +00:00
|
|
|
(fetchpatch {
|
2020-12-25 13:55:36 +00:00
|
|
|
name = "qtwebkit-bison-3.7-build.patch";
|
|
|
|
url = "https://github.com/qtwebkit/qtwebkit/commit/d92b11fea65364fefa700249bd3340e0cd4c5b31.patch";
|
|
|
|
sha256 = "0h8ymfnwgkjkwaankr3iifiscsvngqpwb91yygndx344qdiw9y0n";
|
2020-11-15 13:44:38 +00:00
|
|
|
})
|
2021-05-20 23:08:51 +00:00
|
|
|
(fetchpatch {
|
|
|
|
name = "qtwebkit-glib-2.68.patch";
|
|
|
|
url = "https://github.com/qtwebkit/qtwebkit/pull/1058/commits/5b698ba3faffd4e198a45be9fe74f53307395e4b.patch";
|
|
|
|
sha256 = "0a3xv0h4lv8wggckgy8cg8xnpkg7n9h45312pdjdnnwy87xvzss0";
|
|
|
|
})
|
2022-01-27 00:19:43 +00:00
|
|
|
(fetchpatch {
|
|
|
|
name = "qtwebkit-darwin-handle.patch";
|
|
|
|
url = "https://github.com/qtwebkit/qtwebkit/commit/5c272a21e621a66862821d3ae680f27edcc64c19.patch";
|
|
|
|
sha256 = "9hjqLyABz372QDgoq7nXXXQ/3OXBGcYN1/92ekcC3WE=";
|
|
|
|
})
|
2024-02-29 20:09:43 +00:00
|
|
|
(fetchpatch {
|
|
|
|
name = "qtwebkit-libxml2-api-change.patch";
|
|
|
|
url = "https://github.com/WebKit/WebKit/commit/1bad176b2496579d760852c80cff3ad9fb7c3a4b.patch";
|
|
|
|
sha256 = "WZEj+UuKhgJBM7auhND3uddk1wWdTY728jtiWVe7CSI=";
|
|
|
|
})
|
2020-12-25 13:55:36 +00:00
|
|
|
./qtwebkit.patch
|
2021-03-09 03:18:52 +00:00
|
|
|
./qtwebkit-icu68.patch
|
2024-02-29 20:09:43 +00:00
|
|
|
./qtwebkit-cstdint.patch
|
2021-08-22 07:53:02 +00:00
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
2020-12-25 13:55:36 +00:00
|
|
|
./qtwebkit-darwin-no-readline.patch
|
|
|
|
./qtwebkit-darwin-no-qos-classes.patch
|
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
qttools = [ ./qttools.patch ];
|
|
|
|
};
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
addPackages = self:
|
2020-09-25 04:45:31 +00:00
|
|
|
let
|
2023-11-16 04:20:00 +00:00
|
|
|
qtModule = callPackage ../qtModule.nix {
|
|
|
|
inherit patches;
|
|
|
|
# Use a variant of mkDerivation that does not include wrapQtApplications
|
|
|
|
# to avoid cyclic dependencies between Qt modules.
|
|
|
|
mkDerivation =
|
|
|
|
(callPackage ../mkDerivation.nix { wrapQtAppsHook = null; }) stdenv.mkDerivation;
|
|
|
|
};
|
2022-01-13 20:06:32 +00:00
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
callPackage = self.newScope { inherit qtCompatVersion qtModule srcs stdenv; };
|
2020-09-25 04:45:31 +00:00
|
|
|
in {
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
inherit callPackage qtCompatVersion qtModule srcs;
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
mkDerivationWith = callPackage ../mkDerivation.nix { };
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
mkDerivation = callPackage ({ mkDerivationWith }: mkDerivationWith stdenv.mkDerivation) { };
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
qtbase = callPackage ../modules/qtbase.nix {
|
|
|
|
inherit (srcs.qtbase) src version;
|
|
|
|
patches = patches.qtbase;
|
|
|
|
inherit bison cups harfbuzz libGL;
|
2022-01-26 04:04:25 +00:00
|
|
|
withGtk3 = !stdenv.isDarwin; inherit dconf gtk3;
|
2020-09-25 04:45:31 +00:00
|
|
|
inherit developerBuild decryptSslTraffic;
|
2023-01-20 10:41:00 +00:00
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) AGL AppKit ApplicationServices AVFoundation Carbon Cocoa CoreAudio CoreBluetooth
|
2021-08-22 07:53:02 +00:00
|
|
|
CoreLocation CoreServices DiskArbitration Foundation OpenGL MetalKit IOKit;
|
2023-01-20 10:41:00 +00:00
|
|
|
libobjc = darwin.apple_sdk_11_0.objc4;
|
|
|
|
xcbuild = darwin.apple_sdk_11_0.xcodebuild;
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
qt3d = callPackage ../modules/qt3d.nix {};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtcharts = callPackage ../modules/qtcharts.nix {};
|
2023-05-24 13:37:59 +00:00
|
|
|
qtconnectivity = callPackage ../modules/qtconnectivity.nix {
|
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) IOBluetooth;
|
|
|
|
};
|
|
|
|
qtdatavis3d = callPackage ../modules/qtdatavis3d.nix {};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtdeclarative = callPackage ../modules/qtdeclarative.nix {};
|
|
|
|
qtdoc = callPackage ../modules/qtdoc.nix {};
|
2021-12-24 04:21:11 +00:00
|
|
|
qtgamepad = callPackage ../modules/qtgamepad.nix {
|
2023-01-20 10:41:00 +00:00
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) GameController;
|
2021-12-24 04:21:11 +00:00
|
|
|
};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtgraphicaleffects = callPackage ../modules/qtgraphicaleffects.nix {};
|
|
|
|
qtimageformats = callPackage ../modules/qtimageformats.nix {};
|
|
|
|
qtlocation = callPackage ../modules/qtlocation.nix {};
|
2022-08-12 12:06:08 +00:00
|
|
|
qtlottie = callPackage ../modules/qtlottie.nix {};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtmacextras = callPackage ../modules/qtmacextras.nix {};
|
|
|
|
qtmultimedia = callPackage ../modules/qtmultimedia.nix {
|
|
|
|
inherit gstreamer gst-plugins-base;
|
|
|
|
};
|
|
|
|
qtnetworkauth = callPackage ../modules/qtnetworkauth.nix {};
|
2023-07-15 17:15:38 +00:00
|
|
|
qtpim = callPackage ../modules/qtpim.nix {};
|
2023-04-29 16:46:19 +00:00
|
|
|
qtpositioning = callPackage ../modules/qtpositioning.nix {};
|
2024-05-15 15:35:15 +00:00
|
|
|
qtpurchasing = callPackage ../modules/qtpurchasing.nix {
|
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) Foundation StoreKit;
|
|
|
|
};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtquick1 = null;
|
2024-05-15 15:35:15 +00:00
|
|
|
qtquick3d = callPackage ../modules/qtquick3d.nix { };
|
2020-09-25 04:45:31 +00:00
|
|
|
qtquickcontrols = callPackage ../modules/qtquickcontrols.nix {};
|
|
|
|
qtquickcontrols2 = callPackage ../modules/qtquickcontrols2.nix {};
|
2023-08-22 20:05:09 +00:00
|
|
|
qtremoteobjects = callPackage ../modules/qtremoteobjects.nix {};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtscript = callPackage ../modules/qtscript.nix {};
|
|
|
|
qtsensors = callPackage ../modules/qtsensors.nix {};
|
2021-08-22 07:53:02 +00:00
|
|
|
qtserialbus = callPackage ../modules/qtserialbus.nix {};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtserialport = callPackage ../modules/qtserialport.nix {};
|
|
|
|
qtspeech = callPackage ../modules/qtspeech.nix {};
|
|
|
|
qtsvg = callPackage ../modules/qtsvg.nix {};
|
2023-04-29 16:46:19 +00:00
|
|
|
qtsystems = callPackage ../modules/qtsystems.nix {};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtscxml = callPackage ../modules/qtscxml.nix {};
|
|
|
|
qttools = callPackage ../modules/qttools.nix {};
|
|
|
|
qttranslations = callPackage ../modules/qttranslations.nix {};
|
|
|
|
qtvirtualkeyboard = callPackage ../modules/qtvirtualkeyboard.nix {};
|
|
|
|
qtwayland = callPackage ../modules/qtwayland.nix {};
|
|
|
|
qtwebchannel = callPackage ../modules/qtwebchannel.nix {};
|
2021-04-05 15:23:46 +00:00
|
|
|
qtwebengine = callPackage ../modules/qtwebengine.nix {
|
2023-11-16 04:20:00 +00:00
|
|
|
# The version of Chromium used by Qt WebEngine 5.15.x does not build with clang 16 due
|
|
|
|
# to the following errors:
|
|
|
|
# * -Wenum-constexpr-conversion: This is a downgradable error in clang 16, but it is planned
|
|
|
|
# to be made into a hard error in a future version of clang. Patches are not available for
|
|
|
|
# the version of v8 used by Chromium in Qt WebEngine, and fixing the code is non-trivial.
|
|
|
|
# * -Wincompatible-function-pointer-types: This is also a downgradable error generated
|
|
|
|
# starting with clang 16. Patches are available upstream that can be backported.
|
|
|
|
# Because the first error is non-trivial to fix and suppressing it risks future breakage,
|
|
|
|
# clang is pinned to clang 15. That also makes fixing the second set of errors unnecessary.
|
|
|
|
stdenv =
|
|
|
|
let stdenv' = if stdenv.cc.isClang then overrideLibcxx llvmPackages_15.stdenv else stdenv;
|
|
|
|
in if stdenv'.isDarwin then overrideSDK stdenv' "11.0" else stdenv';
|
2021-04-05 15:23:46 +00:00
|
|
|
inherit (srcs.qtwebengine) version;
|
2022-11-27 09:42:12 +00:00
|
|
|
python = python3;
|
2023-01-20 10:41:00 +00:00
|
|
|
inherit (darwin) cctools xnu;
|
2023-02-02 18:25:31 +00:00
|
|
|
inherit (darwin.apple_sdk_11_0) libpm libunwind;
|
2023-01-20 10:41:00 +00:00
|
|
|
inherit (darwin.apple_sdk_11_0.libs) sandbox;
|
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) ApplicationServices AVFoundation Foundation ForceFeedback GameController AppKit
|
2023-02-02 18:25:31 +00:00
|
|
|
ImageCaptureCore CoreBluetooth IOBluetooth CoreWLAN Quartz Cocoa LocalAuthentication
|
2023-04-29 16:46:19 +00:00
|
|
|
MediaPlayer MediaAccessibility SecurityInterface Vision CoreML OpenDirectory Accelerate;
|
2023-01-20 10:41:00 +00:00
|
|
|
libobjc = darwin.apple_sdk_11_0.objc4;
|
2021-04-05 15:23:46 +00:00
|
|
|
};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtwebglplugin = callPackage ../modules/qtwebglplugin.nix {};
|
2021-08-22 07:53:02 +00:00
|
|
|
qtwebkit = callPackage ../modules/qtwebkit.nix {
|
|
|
|
inherit (darwin) ICU;
|
2023-01-20 10:41:00 +00:00
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) OpenGL;
|
2021-08-22 07:53:02 +00:00
|
|
|
};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtwebsockets = callPackage ../modules/qtwebsockets.nix {};
|
2021-08-22 07:53:02 +00:00
|
|
|
qtwebview = callPackage ../modules/qtwebview.nix {
|
2023-01-20 10:41:00 +00:00
|
|
|
inherit (darwin.apple_sdk_11_0.frameworks) CoreFoundation WebKit;
|
2021-08-22 07:53:02 +00:00
|
|
|
};
|
2020-09-25 04:45:31 +00:00
|
|
|
qtx11extras = callPackage ../modules/qtx11extras.nix {};
|
|
|
|
qtxmlpatterns = callPackage ../modules/qtxmlpatterns.nix {};
|
|
|
|
|
|
|
|
env = callPackage ../qt-env.nix {};
|
2023-11-16 04:20:00 +00:00
|
|
|
full = callPackage ({ env, qtbase }: env "qt-full-${qtbase.version}") { }
|
|
|
|
# `with self` is ok to use here because having these spliced is unnecessary
|
|
|
|
(with self; [
|
2021-09-18 10:52:07 +00:00
|
|
|
qt3d qtcharts qtconnectivity qtdeclarative qtdoc qtgraphicaleffects
|
2020-09-25 04:45:31 +00:00
|
|
|
qtimageformats qtlocation qtmultimedia qtquickcontrols qtquickcontrols2
|
|
|
|
qtscript qtsensors qtserialport qtsvg qttools qttranslations
|
2023-11-16 04:20:00 +00:00
|
|
|
qtvirtualkeyboard qtwebchannel qtwebengine qtwebsockets
|
2023-05-24 13:37:59 +00:00
|
|
|
qtwebview qtx11extras qtxmlpatterns qtlottie qtdatavis3d
|
2021-08-22 07:53:02 +00:00
|
|
|
] ++ lib.optional (!stdenv.isDarwin) qtwayland
|
|
|
|
++ lib.optional (stdenv.isDarwin) qtmacextras);
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
qmake = callPackage ({ qtbase }: makeSetupHook {
|
2023-02-02 18:25:31 +00:00
|
|
|
name = "qmake-hook";
|
2023-11-16 04:20:00 +00:00
|
|
|
${if stdenv.buildPlatform == stdenv.hostPlatform
|
|
|
|
then "propagatedBuildInputs"
|
|
|
|
else "depsTargetTargetPropagated"} = [ qtbase.dev ];
|
2020-09-25 04:45:31 +00:00
|
|
|
substitutions = {
|
2021-02-19 19:06:45 +00:00
|
|
|
inherit debug;
|
2020-09-25 04:45:31 +00:00
|
|
|
fix_qmake_libtool = ../hooks/fix-qmake-libtool.sh;
|
|
|
|
};
|
2023-11-16 04:20:00 +00:00
|
|
|
} ../hooks/qmake-hook.sh) { };
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
wrapQtAppsHook = callPackage ({ makeBinaryWrapper, qtbase, qtwayland }: makeSetupHook {
|
2023-02-02 18:25:31 +00:00
|
|
|
name = "wrap-qt5-apps-hook";
|
2023-11-16 04:20:00 +00:00
|
|
|
propagatedBuildInputs = [ qtbase.dev makeBinaryWrapper ]
|
|
|
|
++ lib.optional stdenv.isLinux qtwayland.dev;
|
|
|
|
} ../hooks/wrap-qt-apps-hook.sh) { };
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
baseScope = makeScopeWithSplicing' {
|
|
|
|
otherSplices = generateSplicesForMkScope "qt5";
|
|
|
|
f = addPackages;
|
|
|
|
};
|
|
|
|
|
|
|
|
bootstrapScope = baseScope.overrideScope(final: prev: {
|
|
|
|
qtbase = prev.qtbase.override { qttranslations = null; };
|
|
|
|
qtdeclarative = null;
|
|
|
|
});
|
|
|
|
|
|
|
|
finalScope = baseScope.overrideScope(final: prev: {
|
2023-11-16 04:20:00 +00:00
|
|
|
# qttranslations causes eval-time infinite recursion when
|
|
|
|
# cross-compiling; disabled for now.
|
|
|
|
qttranslations =
|
|
|
|
if stdenv.buildPlatform == stdenv.hostPlatform
|
|
|
|
then bootstrapScope.qttranslations
|
|
|
|
else null;
|
2023-10-09 19:29:22 +00:00
|
|
|
});
|
|
|
|
in finalScope
|