From d5bec1a14576e357e456c1e9d7d3a65be25add4c Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Sat, 30 Jul 2016 13:47:17 -0500 Subject: [PATCH] kde5: rename extra-cmake-modules variants Instead of one package `extra-cmake-modules`, there is now `ecm` and `ecmNoHooks`. The latter is used when one does not want to incur a Qt 5 dependency; it is also available as a top-level package `extra-cmake-modules`. --- .../services/x11/desktop-managers/kde5.nix | 2 +- .../libraries/kde-frameworks/default.nix | 8 ++--- .../kde-frameworks/kservice/default.nix | 7 ++-- .../default.nix => ktexteditor.nix} | 5 ++- .../ktexteditor/no-qcoreapplication.patch | 36 ------------------- .../kde-frameworks/ktexteditor/series | 1 - pkgs/top-level/all-packages.nix | 2 +- 7 files changed, 12 insertions(+), 49 deletions(-) rename pkgs/development/libraries/kde-frameworks/{ktexteditor/default.nix => ktexteditor.nix} (72%) delete mode 100644 pkgs/development/libraries/kde-frameworks/ktexteditor/no-qcoreapplication.patch delete mode 100644 pkgs/development/libraries/kde-frameworks/ktexteditor/series diff --git a/nixos/modules/services/x11/desktop-managers/kde5.nix b/nixos/modules/services/x11/desktop-managers/kde5.nix index bcd36f59e8ca..86b98c2b6601 100644 --- a/nixos/modules/services/x11/desktop-managers/kde5.nix +++ b/nixos/modules/services/x11/desktop-managers/kde5.nix @@ -214,7 +214,7 @@ in services.xserver.displayManager.sddm = { theme = "breeze"; themes = [ - kde5.extra-cmake-modules # for the setup-hook + kde5.ecm # for the setup-hook kde5.plasma-workspace kde5.breeze-icons (kde5.oxygen-icons or kde5.oxygen-icons5) diff --git a/pkgs/development/libraries/kde-frameworks/default.nix b/pkgs/development/libraries/kde-frameworks/default.nix index 49ece732222d..74e9df114f0b 100644 --- a/pkgs/development/libraries/kde-frameworks/default.nix +++ b/pkgs/development/libraries/kde-frameworks/default.nix @@ -55,12 +55,12 @@ let bluez-qt = callPackage ./bluez-qt.nix {}; breeze-icons = callPackage ./breeze-icons.nix {}; ecm = - let drv = { cmake, extra-cmake-modules, pkgconfig, qtbase, qttools }: + let drv = { cmake, ecmNoHooks, pkgconfig, qtbase, qttools }: makeSetupHook - { deps = [ cmake extra-cmake-modules pkgconfig qtbase qttools ]; } + { deps = [ cmake ecmNoHooks pkgconfig qtbase qttools ]; } ./setup-hook.sh; in callPackage drv {}; - extra-cmake-modules = callPackage ./extra-cmake-modules { + ecmNoHooks = callPackage ./extra-cmake-modules { inherit (srcs.extra-cmake-modules) src version; }; frameworkintegration = callPackage ./frameworkintegration.nix {}; @@ -113,7 +113,7 @@ let kross = callPackage ./kross.nix {}; krunner = callPackage ./krunner.nix {}; kservice = callPackage ./kservice {}; - ktexteditor = callPackage ./ktexteditor {}; + ktexteditor = callPackage ./ktexteditor.nix {}; ktextwidgets = callPackage ./ktextwidgets.nix {}; kunitconversion = callPackage ./kunitconversion.nix {}; kwallet = callPackage ./kwallet.nix {}; diff --git a/pkgs/development/libraries/kde-frameworks/kservice/default.nix b/pkgs/development/libraries/kde-frameworks/kservice/default.nix index 484be4087943..12e617a7d9af 100644 --- a/pkgs/development/libraries/kde-frameworks/kservice/default.nix +++ b/pkgs/development/libraries/kde-frameworks/kservice/default.nix @@ -1,11 +1,12 @@ -{ kdeFramework, lib, copyPathsToStore, extra-cmake-modules, kconfig, kcoreaddons -, kcrash, kdbusaddons, kdoctools, ki18n, kwindowsystem +{ + kdeFramework, lib, copyPathsToStore, ecm, + kconfig, kcoreaddons, kcrash, kdbusaddons, kdoctools, ki18n, kwindowsystem }: kdeFramework { name = "kservice"; meta = { maintainers = [ lib.maintainers.ttuegel ]; }; - propagatedNativeBuildInputs = [ extra-cmake-modules ]; + propagatedNativeBuildInputs = [ ecm ]; nativeBuildInputs = [ kdoctools ]; propagatedBuildInputs = [ kconfig kcoreaddons kcrash kdbusaddons ki18n kwindowsystem ]; patches = copyPathsToStore (lib.readPathsFromFile ./. ./series); diff --git a/pkgs/development/libraries/kde-frameworks/ktexteditor/default.nix b/pkgs/development/libraries/kde-frameworks/ktexteditor.nix similarity index 72% rename from pkgs/development/libraries/kde-frameworks/ktexteditor/default.nix rename to pkgs/development/libraries/kde-frameworks/ktexteditor.nix index a35af2e7fbfd..8cd7e95b659a 100644 --- a/pkgs/development/libraries/kde-frameworks/ktexteditor/default.nix +++ b/pkgs/development/libraries/kde-frameworks/ktexteditor.nix @@ -1,5 +1,5 @@ { kdeFramework, lib, copyPathsToStore -, extra-cmake-modules, perl +, ecm, perl , karchive, kconfig, kguiaddons, kiconthemes, kparts , libgit2 , qtscript, qtxmlpatterns @@ -9,10 +9,9 @@ kdeFramework { name = "ktexteditor"; meta = { maintainers = [ lib.maintainers.ttuegel ]; }; - nativeBuildInputs = [ extra-cmake-modules perl ]; + nativeBuildInputs = [ ecm perl ]; propagatedBuildInputs = [ karchive kconfig kguiaddons ki18n kiconthemes kio kparts libgit2 qtscript qtxmlpatterns sonnet ]; - patches = copyPathsToStore (lib.readPathsFromFile ./. ./series); } diff --git a/pkgs/development/libraries/kde-frameworks/ktexteditor/no-qcoreapplication.patch b/pkgs/development/libraries/kde-frameworks/ktexteditor/no-qcoreapplication.patch deleted file mode 100644 index 19ab1e1e5513..000000000000 --- a/pkgs/development/libraries/kde-frameworks/ktexteditor/no-qcoreapplication.patch +++ /dev/null @@ -1,36 +0,0 @@ -Index: ktexteditor-5.18.0/src/syntax/data/katehighlightingindexer.cpp -=================================================================== ---- ktexteditor-5.18.0.orig/src/syntax/data/katehighlightingindexer.cpp -+++ ktexteditor-5.18.0/src/syntax/data/katehighlightingindexer.cpp -@@ -55,19 +55,16 @@ QStringList readListing(const QString &f - - int main(int argc, char *argv[]) - { -- // get app instance -- QCoreApplication app(argc, argv); -- - // ensure enough arguments are passed -- if (app.arguments().size() < 3) -+ if (argc < 3) - return 1; - - // open schema - QXmlSchema schema; -- if (!schema.load(QUrl::fromLocalFile(app.arguments().at(2)))) -+ if (!schema.load(QUrl::fromLocalFile(QString::fromLocal8Bit(argv[2])))) - return 2; - -- const QString hlFilenamesListing = app.arguments().value(3); -+ const QString hlFilenamesListing = QString::fromLocal8Bit(argv[3]); - if (hlFilenamesListing.isEmpty()) { - return 1; - } -@@ -152,7 +149,7 @@ int main(int argc, char *argv[]) - return anyError; - - // create outfile, after all has worked! -- QFile outFile(app.arguments().at(1)); -+ QFile outFile(QString::fromLocal8Bit(argv[1])); - if (!outFile.open(QIODevice::WriteOnly | QIODevice::Truncate)) - return 7; - diff --git a/pkgs/development/libraries/kde-frameworks/ktexteditor/series b/pkgs/development/libraries/kde-frameworks/ktexteditor/series deleted file mode 100644 index 46cd23829a2f..000000000000 --- a/pkgs/development/libraries/kde-frameworks/ktexteditor/series +++ /dev/null @@ -1 +0,0 @@ -no-qcoreapplication.patch diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a611bc40e5c5..96755b35c325 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6267,7 +6267,7 @@ in cmakeWithGui = self.cmakeCurses.override { useQt4 = true; }; # Does not actually depend on Qt 5 - extra-cmake-modules = qt5.extra-cmake-modules; + extra-cmake-modules = qt5.ecmNoHooks; coccinelle = callPackage ../development/tools/misc/coccinelle { };