diff --git a/pkgs/applications/editors/molsketch/default.nix b/pkgs/applications/editors/molsketch/default.nix index d688a50f28d3..55db4096ce15 100644 --- a/pkgs/applications/editors/molsketch/default.nix +++ b/pkgs/applications/editors/molsketch/default.nix @@ -3,11 +3,11 @@ , fetchurl , cmake , pkg-config +, qttools , wrapQtAppsHook , hicolor-icon-theme , openbabel , desktop-file-utils -, qttranslations }: mkDerivation rec { @@ -37,12 +37,11 @@ mkDerivation rec { mv $out/lib/molsketch/* $out/lib ''; - nativeBuildInputs = [ cmake pkg-config wrapQtAppsHook ]; + nativeBuildInputs = [ cmake pkg-config qttools wrapQtAppsHook ]; buildInputs = [ hicolor-icon-theme openbabel desktop-file-utils - qttranslations ]; meta = with lib; { diff --git a/pkgs/applications/emulators/pcsx2/default.nix b/pkgs/applications/emulators/pcsx2/default.nix index fea7bf17ef7b..1b016e0559dd 100644 --- a/pkgs/applications/emulators/pcsx2/default.nix +++ b/pkgs/applications/emulators/pcsx2/default.nix @@ -18,7 +18,6 @@ , qtbase , qtsvg , qttools -, qttranslations , qtwayland , rapidyaml , SDL2 @@ -83,7 +82,6 @@ llvmPackages_16.stdenv.mkDerivation rec { qtbase qtsvg qttools - qttranslations qtwayland rapidyaml SDL2 diff --git a/pkgs/applications/gis/openorienteering-mapper/default.nix b/pkgs/applications/gis/openorienteering-mapper/default.nix index b73fb71f698f..9722c3cb4dee 100644 --- a/pkgs/applications/gis/openorienteering-mapper/default.nix +++ b/pkgs/applications/gis/openorienteering-mapper/default.nix @@ -14,8 +14,6 @@ , qtlocation , qtsensors , qttools -, qttranslations -, substituteAll , zlib }: @@ -31,11 +29,6 @@ mkDerivation rec { }; patches = [ - # https://github.com/NixOS/nixpkgs/issues/86054 - (substituteAll { - src = ./fix-qttranslations-path.diff; - inherit qttranslations; - }) # https://github.com/OpenOrienteering/mapper/pull/1907 (fetchpatch { url = "https://github.com/OpenOrienteering/mapper/commit/bc52aa567e90a58d6963b44d5ae1909f3f841508.patch"; diff --git a/pkgs/applications/gis/openorienteering-mapper/fix-qttranslations-path.diff b/pkgs/applications/gis/openorienteering-mapper/fix-qttranslations-path.diff deleted file mode 100644 index 06c465a8fb33..000000000000 --- a/pkgs/applications/gis/openorienteering-mapper/fix-qttranslations-path.diff +++ /dev/null @@ -1,13 +0,0 @@ -diff --git i/src/util/translation_util.cpp w/src/util/translation_util.cpp -index da03d216..c1f12751 100644 ---- i/src/util/translation_util.cpp -+++ w/src/util/translation_util.cpp -@@ -103,7 +103,7 @@ TranslationUtil::TranslationUtil(const QString& code, QString translation_file) - } - - QString translation_name = QLatin1String("qt_") + language.code; -- if (!qt_translator.load(translation_name, QLibraryInfo::location(QLibraryInfo::TranslationsPath))) -+ if (!qt_translator.load(translation_name, QLatin1String("@qttranslations@/translations"))) - load(qt_translator, translation_name); - - load(app_translator, translation_file); diff --git a/pkgs/applications/gis/qmapshack/default.nix b/pkgs/applications/gis/qmapshack/default.nix index 2665e74ed395..3460f60d2b63 100644 --- a/pkgs/applications/gis/qmapshack/default.nix +++ b/pkgs/applications/gis/qmapshack/default.nix @@ -1,5 +1,5 @@ -{ lib, stdenv, fetchFromGitHub, cmake, substituteAll, wrapQtAppsHook -, qtscript, qttranslations, qtwebengine, gdal, proj, routino, quazip }: +{ lib, stdenv, fetchFromGitHub, cmake, wrapQtAppsHook +, qtscript, qtwebengine, gdal, proj, routino, quazip }: stdenv.mkDerivation rec { pname = "qmapshack"; @@ -12,14 +12,6 @@ stdenv.mkDerivation rec { hash = "sha256-qG/fiR2J5wQZaR+xvBGjdp3L7viqki2ktkzBUf6fZi8="; }; - patches = [ - # See https://github.com/NixOS/nixpkgs/issues/86054 - (substituteAll { - src = ./fix-qttranslations-path.patch; - inherit qttranslations; - }) - ]; - nativeBuildInputs = [ cmake wrapQtAppsHook ]; buildInputs = [ qtscript qtwebengine gdal proj routino quazip ]; diff --git a/pkgs/applications/gis/qmapshack/fix-qttranslations-path.patch b/pkgs/applications/gis/qmapshack/fix-qttranslations-path.patch deleted file mode 100644 index 9f05611f5a28..000000000000 --- a/pkgs/applications/gis/qmapshack/fix-qttranslations-path.patch +++ /dev/null @@ -1,74 +0,0 @@ -diff --git i/src/qmapshack/setup/CAppSetupLinux.cpp w/src/qmapshack/setup/CAppSetupLinux.cpp -index 7581ef32..26eba3c8 100644 ---- i/src/qmapshack/setup/CAppSetupLinux.cpp -+++ w/src/qmapshack/setup/CAppSetupLinux.cpp -@@ -30,7 +30,7 @@ void CAppSetupLinux::initQMapShack() { - prepareGdal("", ""); - - // setup translators -- QString resourceDir = QLibraryInfo::location(QLibraryInfo::TranslationsPath); -+ QLatin1String resourceDir = QLatin1String("@qttranslations@/translations"); - QString translationPath = QCoreApplication::applicationDirPath(); - translationPath.replace(QRegExp("bin$"), "share/qmapshack/translations"); - prepareTranslator(resourceDir, "qt_"); -diff --git i/src/qmapshack/setup/CAppSetupMac.cpp w/src/qmapshack/setup/CAppSetupMac.cpp -index 37602802..ae4a5a23 100644 ---- i/src/qmapshack/setup/CAppSetupMac.cpp -+++ w/src/qmapshack/setup/CAppSetupMac.cpp -@@ -56,7 +56,7 @@ void CAppSetupMac::initQMapShack() { - - // setup translators - QString translationPath = getApplicationDir(relTranslationDir).absolutePath(); -- prepareTranslator(translationPath, "qt_"); -+ prepareTranslator(QLatin1String("@qttranslations@/translations"), "qt_"); - prepareTranslator(translationPath, "qmapshack_"); - - // load and apply style sheet -diff --git i/src/qmaptool/setup/CAppSetupLinux.cpp w/src/qmaptool/setup/CAppSetupLinux.cpp -index b703e7bb..637d653e 100644 ---- i/src/qmaptool/setup/CAppSetupLinux.cpp -+++ w/src/qmaptool/setup/CAppSetupLinux.cpp -@@ -29,7 +29,7 @@ void CAppSetupLinux::initQMapTool() { - prepareGdal("", ""); - - // setup translators -- QString resourceDir = QLibraryInfo::location(QLibraryInfo::TranslationsPath); -+ QLatin1String resourceDir = QLatin1String("@qttranslations@/translations"); - QString translationPath = QCoreApplication::applicationDirPath(); - translationPath.replace(QRegExp("bin$"), "share/qmaptool/translations"); - prepareTranslator(resourceDir, "qt_"); -diff --git i/src/qmaptool/setup/CAppSetupMac.cpp w/src/qmaptool/setup/CAppSetupMac.cpp -index dd68b9c1..84351cf4 100644 ---- i/src/qmaptool/setup/CAppSetupMac.cpp -+++ w/src/qmaptool/setup/CAppSetupMac.cpp -@@ -57,7 +57,7 @@ void CAppSetupMac::initQMapTool() { - - // setup translators - QString translationPath = getApplicationDir(relTranslationDir).absolutePath(); -- prepareTranslator(translationPath, "qt_"); -+ prepareTranslator(QLatin1String("@qttranslations@/translations"), "qt_"); - prepareTranslator(translationPath, "qmaptool_"); - - migrateDirContent(defaultCachePath()); -diff --git i/src/qmt_rgb2pct/main.cpp w/src/qmt_rgb2pct/main.cpp -index 589d3d52..5f7c12f8 100644 ---- i/src/qmt_rgb2pct/main.cpp -+++ w/src/qmt_rgb2pct/main.cpp -@@ -47,7 +47,7 @@ static void prepareTranslator(QString translationPath, QString translationPrefix - static void loadTranslations() { - #if defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD) || defined(__FreeBSD_kernel__) || defined(__GNU__) || \ - defined(Q_OS_CYGWIN) -- QString resourceDir = QLibraryInfo::location(QLibraryInfo::TranslationsPath); -+ QLatin1String resourceDir = QLatin1String("@qttranslations@/translations"); - QString translationPath = QCoreApplication::applicationDirPath(); - translationPath.replace(QRegExp("bin$"), "share/" APP_STR "/translations"); - prepareTranslator(resourceDir, "qt_"); -@@ -58,7 +58,7 @@ static void loadTranslations() { - // os x - static QString relTranslationDir = "Resources/translations"; // app - QString translationPath = getApplicationDir(relTranslationDir).absolutePath(); -- prepareTranslator(translationPath, "qt_"); -+ prepareTranslator(QLatin1String("@qttranslations@/translations"), "qt_"); - prepareTranslator(translationPath, APP_STR "_"); - #endif - diff --git a/pkgs/applications/misc/birdtray/default.nix b/pkgs/applications/misc/birdtray/default.nix index f007fb71377b..5ab42d36b3a0 100644 --- a/pkgs/applications/misc/birdtray/default.nix +++ b/pkgs/applications/misc/birdtray/default.nix @@ -7,7 +7,6 @@ , qtbase , qttools , qtx11extras - , qttranslations }: mkDerivation rec { @@ -21,21 +20,11 @@ mkDerivation rec { sha256 = "1469ng6zk0qx0qfsihrnlz1j9i1wk0hx4vqdaplz9mdpyxvmlryk"; }; - patches = [ - # See https://github.com/NixOS/nixpkgs/issues/86054 - ./fix-qttranslations-path.diff - ]; - nativeBuildInputs = [ cmake pkg-config ]; buildInputs = [ qtbase qttools qtx11extras ]; - postPatch = '' - substituteInPlace src/birdtrayapp.cpp \ - --subst-var-by qttranslations ${qttranslations} - ''; - # Wayland support is broken. # https://github.com/gyunaev/birdtray/issues/113#issuecomment-621742315 qtWrapperArgs = [ "--set QT_QPA_PLATFORM xcb" ]; diff --git a/pkgs/applications/misc/birdtray/fix-qttranslations-path.diff b/pkgs/applications/misc/birdtray/fix-qttranslations-path.diff deleted file mode 100644 index 2a379b5e2744..000000000000 --- a/pkgs/applications/misc/birdtray/fix-qttranslations-path.diff +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/src/birdtrayapp.cpp b/src/birdtrayapp.cpp -index 847b4d3..3a3709a 100644 ---- a/src/birdtrayapp.cpp -+++ b/src/birdtrayapp.cpp -@@ -130,7 +130,7 @@ bool BirdtrayApp::loadTranslations() { - [](QString path) { return path.append("/translations"); }); - QLocale locale = QLocale::system(); - bool success = loadTranslation( -- qtTranslator, locale, "qt", {QLibraryInfo::location(QLibraryInfo::TranslationsPath)}); -+ qtTranslator, locale, "qt", {QLatin1String("@qttranslations@/translations")}); - success &= loadTranslation(dynamicTranslator, locale, "dynamic", locations); - success &= loadTranslation(mainTranslator, locale, "main", locations); - return success; diff --git a/pkgs/applications/misc/crow-translate/default.nix b/pkgs/applications/misc/crow-translate/default.nix index 77611e2da43c..9c207dcd77c7 100644 --- a/pkgs/applications/misc/crow-translate/default.nix +++ b/pkgs/applications/misc/crow-translate/default.nix @@ -1,7 +1,6 @@ { lib , stdenv , fetchzip -, substituteAll , cmake , extra-cmake-modules , qttools @@ -10,7 +9,6 @@ , tesseract4 , qtmultimedia , qtx11extras -, qttranslations , wrapQtAppsHook , gst_all_1 , testers @@ -26,14 +24,6 @@ stdenv.mkDerivation rec { hash = "sha256-PvfruCqmTBFLWLeIL9NV6+H2AifXcY97ImHzD1zEs28="; }; - patches = [ - (substituteAll { - # See https://github.com/NixOS/nixpkgs/issues/86054 - src = ./fix-qttranslations-path.patch; - inherit qttranslations; - }) - ]; - postPatch = '' substituteInPlace data/io.crow_translate.CrowTranslate.desktop \ --replace "Exec=qdbus" "Exec=${lib.getBin qttools}/bin/qdbus" diff --git a/pkgs/applications/misc/crow-translate/fix-qttranslations-path.patch b/pkgs/applications/misc/crow-translate/fix-qttranslations-path.patch deleted file mode 100644 index 65cfbdf1acf2..000000000000 --- a/pkgs/applications/misc/crow-translate/fix-qttranslations-path.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git i/src/settings/appsettings.cpp w/src/settings/appsettings.cpp -index 32cabfb..aab92ea 100644 ---- i/src/settings/appsettings.cpp -+++ w/src/settings/appsettings.cpp -@@ -79,7 +79,7 @@ void AppSettings::applyLocale(const QLocale &locale) - const QLocale newLocale = locale == defaultLocale() ? QLocale::system() : locale; - QLocale::setDefault(newLocale); - s_appTranslator.load(newLocale, QStringLiteral(PROJECT_NAME), QStringLiteral("_"), QStandardPaths::locate(QStandardPaths::AppDataLocation, i18nDir, QStandardPaths::LocateDirectory)); -- s_qtTranslator.load(newLocale, QStringLiteral("qt"), QStringLiteral("_"), QLibraryInfo::location(QLibraryInfo::TranslationsPath)); -+ s_qtTranslator.load(newLocale, QStringLiteral("qt"), QStringLiteral("_"), QLatin1String("@qttranslations@/translations")); - } - - QLocale AppSettings::defaultLocale() diff --git a/pkgs/applications/misc/edgetx/default.nix b/pkgs/applications/misc/edgetx/default.nix index 785ad0ba229a..9e7cf60af1a1 100644 --- a/pkgs/applications/misc/edgetx/default.nix +++ b/pkgs/applications/misc/edgetx/default.nix @@ -1,6 +1,6 @@ { lib, mkDerivation, fetchFromGitHub , cmake, gcc-arm-embedded, python3Packages -, qtbase, qtmultimedia, qttranslations, SDL, gtest +, qtbase, qtmultimedia, qttools, SDL, gtest , dfu-util }: @@ -16,9 +16,9 @@ mkDerivation rec { sha256 = "sha256-bKMAyONy1Udd+2nDVEMrtIsnfqrNuBVMWU7nCqvZ+3E="; }; - nativeBuildInputs = [ cmake gcc-arm-embedded python3Packages.pillow ]; + nativeBuildInputs = [ cmake gcc-arm-embedded python3Packages.pillow qttools ]; - buildInputs = [ qtbase qtmultimedia qttranslations SDL ]; + buildInputs = [ qtbase qtmultimedia SDL ]; postPatch = '' sed -i companion/src/burnconfigdialog.cpp \ @@ -27,7 +27,6 @@ mkDerivation rec { cmakeFlags = [ "-DGTEST_ROOT=${gtest.src}/googletest" - "-DQT_TRANSLATIONS_DIR=${qttranslations}/translations" "-DDFU_UTIL_PATH=${dfu-util}/bin/dfu-util" # file RPATH_CHANGE could not write new RPATH "-DCMAKE_SKIP_BUILD_RPATH=ON" diff --git a/pkgs/applications/misc/gpsbabel/default.nix b/pkgs/applications/misc/gpsbabel/default.nix index 60a1e40a614e..0898c3ccee9a 100644 --- a/pkgs/applications/misc/gpsbabel/default.nix +++ b/pkgs/applications/misc/gpsbabel/default.nix @@ -1,5 +1,5 @@ { lib, stdenv, fetchFromGitHub, fetchurl, pkg-config, which -, qtbase, qmake, qttools, qttranslations, wrapQtAppsHook +, qmake, qttools, wrapQtAppsHook , libusb1, shapelib, zlib , withGUI ? false, qtserialport , withMapPreview ? (!stdenv.isDarwin), qtwebengine @@ -21,11 +21,6 @@ stdenv.mkDerivation rec { postPatch = '' patchShebangs testo - '' + lib.optionalString withGUI '' - # See https://github.com/NixOS/nixpkgs/issues/86054 - substituteInPlace gui/mainwindow.cc \ - --replace 'QLibraryInfo::location(QLibraryInfo::TranslationsPath)' \ - 'QLatin1String("${qttranslations}/translations")' '' + lib.optionalString withDoc '' substituteInPlace gbversion.h.qmake.in \ --replace /usr/share/doc $doc/share/doc diff --git a/pkgs/applications/misc/gpxlab/default.nix b/pkgs/applications/misc/gpxlab/default.nix index 8d2b95ea4f31..9d3d7c27ec8c 100644 --- a/pkgs/applications/misc/gpxlab/default.nix +++ b/pkgs/applications/misc/gpxlab/default.nix @@ -1,5 +1,5 @@ -{ stdenv, mkDerivation, lib, fetchFromGitHub, substituteAll -, qmake, qttools, qttranslations +{ stdenv, mkDerivation, lib, fetchFromGitHub +, qmake, qttools }: mkDerivation rec { @@ -13,12 +13,6 @@ mkDerivation rec { sha256 = "080vnwcciqblfrbfyz9gjhl2lqw1hkdpbgr5qfrlyglkd4ynjd84"; }; - patches = (substituteAll { - # See https://github.com/NixOS/nixpkgs/issues/86054 - src = ./fix-qttranslations-path.patch; - inherit qttranslations; - }); - nativeBuildInputs = [ qmake qttools ]; preConfigure = '' diff --git a/pkgs/applications/misc/gpxlab/fix-qttranslations-path.patch b/pkgs/applications/misc/gpxlab/fix-qttranslations-path.patch deleted file mode 100644 index 8dcba75d764f..000000000000 --- a/pkgs/applications/misc/gpxlab/fix-qttranslations-path.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git i/GPXLab/main.cpp w/GPXLab/main.cpp -index b12d2dd..58d37c5 100644 ---- i/GPXLab/main.cpp -+++ w/GPXLab/main.cpp -@@ -19,10 +19,10 @@ int main(int argc, char *argv[]) - app.installTranslator(&gpxlab); - - QTranslator qt; --#if defined(Q_OS_WIN32) || defined(Q_OS_MAC) -+#if defined(Q_OS_WIN32) - qt.load(QLocale::system(), "qt", "_", TRANSLATIONS_DIR); - #else -- qt.load(QLocale::system(), "qt", "_", QLibraryInfo::location(QLibraryInfo::TranslationsPath)); -+ qt.load(QLocale::system(), "qt", "_", QLatin1String("@qttranslations@/translations")); - #endif - app.installTranslator(&qt); - diff --git a/pkgs/applications/misc/gpxsee/default.nix b/pkgs/applications/misc/gpxsee/default.nix index 694323df82d9..c08deed34db0 100644 --- a/pkgs/applications/misc/gpxsee/default.nix +++ b/pkgs/applications/misc/gpxsee/default.nix @@ -3,10 +3,8 @@ , fetchFromGitHub , qmake , nix-update-script -, substituteAll , qtbase , qttools -, qttranslations , qtlocation ? null # qt5 only , qtpositioning ? null # qt6 only , qtpbfimageplugin @@ -31,12 +29,6 @@ stdenv.mkDerivation rec { hash = "sha256-Zf2eyDx5QK69W6HNz/IGGHkX2qCDnxYsU8KLCgU9teY="; }; - patches = (substituteAll { - # See https://github.com/NixOS/nixpkgs/issues/86054 - src = ./fix-qttranslations-path.diff; - inherit qttranslations; - }); - buildInputs = [ qtpbfimageplugin qtserialport ] ++ (if isQt6 then [ qtbase diff --git a/pkgs/applications/misc/gpxsee/fix-qttranslations-path.diff b/pkgs/applications/misc/gpxsee/fix-qttranslations-path.diff deleted file mode 100644 index 757d9b8c6571..000000000000 --- a/pkgs/applications/misc/gpxsee/fix-qttranslations-path.diff +++ /dev/null @@ -1,18 +0,0 @@ -diff --git i/src/GUI/app.cpp w/src/GUI/app.cpp -index 37e9d3f..d4a065c 100644 ---- i/src/GUI/app.cpp -+++ w/src/GUI/app.cpp -@@ -35,11 +35,10 @@ App::App(int &argc, char **argv) : QApplication(argc, argv) - installTranslator(gpxsee); - - QTranslator *qt = new QTranslator(this); --#if defined(Q_OS_WIN32) || defined(Q_OS_MAC) -+#if defined(Q_OS_WIN32) - if (qt->load(QLocale::system(), "qt", "_", ProgramPaths::translationsDir())) - #else // Q_OS_WIN32 || Q_OS_MAC -- if (qt->load(QLocale::system(), "qt", "_", QLibraryInfo::location( -- QLibraryInfo::TranslationsPath))) -+ if (qt->load(QLocale::system(), "qt", "_", QLatin1String("@qttranslations@/translations"))) - #endif // Q_OS_WIN32 || Q_OS_MAC - installTranslator(qt); - diff --git a/pkgs/applications/misc/merkaartor/default.nix b/pkgs/applications/misc/merkaartor/default.nix index c8ac515571c7..9d474ca91f04 100644 --- a/pkgs/applications/misc/merkaartor/default.nix +++ b/pkgs/applications/misc/merkaartor/default.nix @@ -5,7 +5,6 @@ , qmake , qttools , wrapQtAppsHook -, qttranslations , gdal , proj , qtsvg @@ -48,7 +47,6 @@ stdenv.mkDerivation rec { ''; qmakeFlags = [ - "TRANSDIR_SYSTEM=${qttranslations}/translations" "USEWEBENGINE=1" ] ++ lib.optional withGeoimage "GEOIMAGE=1" ++ lib.optional withGpsdlib "GPSDLIB=1" diff --git a/pkgs/applications/misc/opentx/default.nix b/pkgs/applications/misc/opentx/default.nix index e9a526a1f65f..0634c03e7bd7 100644 --- a/pkgs/applications/misc/opentx/default.nix +++ b/pkgs/applications/misc/opentx/default.nix @@ -1,6 +1,6 @@ { lib, mkDerivation, fetchFromGitHub , cmake, gcc-arm-embedded, python3Packages -, qtbase, qtmultimedia, qttranslations, SDL, gtest +, qtbase, qtmultimedia, qttools, SDL, gtest , dfu-util, avrdude }: @@ -15,9 +15,9 @@ mkDerivation rec { sha256 = "sha256-F3zykJhKuIpLQSTjn7mcdjEmgRAlwCZpkTaKQR9ve3g="; }; - nativeBuildInputs = [ cmake gcc-arm-embedded python3Packages.pillow ]; + nativeBuildInputs = [ cmake gcc-arm-embedded python3Packages.pillow qttools ]; - buildInputs = [ qtbase qtmultimedia qttranslations SDL ]; + buildInputs = [ qtbase qtmultimedia SDL ]; postPatch = '' sed -i companion/src/burnconfigdialog.cpp \ @@ -27,7 +27,6 @@ mkDerivation rec { cmakeFlags = [ "-DGTEST_ROOT=${gtest.src}/googletest" - "-DQT_TRANSLATIONS_DIR=${qttranslations}/translations" # XXX I would prefer to include these here, though we will need to file a bug upstream to get that changed. #"-DDFU_UTIL_PATH=${dfu-util}/bin/dfu-util" #"-DAVRDUDE_PATH=${avrdude}/bin/avrdude" diff --git a/pkgs/applications/misc/ubpm/default.nix b/pkgs/applications/misc/ubpm/default.nix index a9053374c7af..6e0d7f7f25f5 100644 --- a/pkgs/applications/misc/ubpm/default.nix +++ b/pkgs/applications/misc/ubpm/default.nix @@ -1,5 +1,5 @@ { stdenv, lib, fetchFromGitea, qmake, qttools, qtbase, qtserialport -, qtconnectivity, qtcharts, qttranslations, wrapQtAppsHook }: +, qtconnectivity, qtcharts, wrapQtAppsHook }: stdenv.mkDerivation (finalAttrs: { pname = "ubpm"; @@ -15,7 +15,6 @@ stdenv.mkDerivation (finalAttrs: { postPatch = '' substituteInPlace sources/mainapp/mainapp.pro \ - --replace '$$[QT_INSTALL_TRANSLATIONS]' '${qttranslations}/translations' \ --replace 'INSTALLDIR = /tmp/ubpm.AppDir' "INSTALLDIR = $out" \ --replace '/usr/bin' '/bin' \ --replace 'INSTALLS += target translations themes devices help lin' 'INSTALLS += target translations themes devices help' @@ -40,7 +39,7 @@ stdenv.mkDerivation (finalAttrs: { # *.so plugins are being wrapped automatically which breaks them dontWrapQtApps = true; - buildInputs = [ qtbase qtserialport qtconnectivity qtcharts qttranslations ]; + buildInputs = [ qtbase qtserialport qtconnectivity qtcharts ]; meta = with lib; { homepage = "https://codeberg.org/LazyT/ubpm"; diff --git a/pkgs/applications/misc/valentina/default.nix b/pkgs/applications/misc/valentina/default.nix index f5cd55c534c3..c00159c0c64d 100644 --- a/pkgs/applications/misc/valentina/default.nix +++ b/pkgs/applications/misc/valentina/default.nix @@ -1,6 +1,6 @@ -{ lib, stdenv, fetchFromGitLab, substituteAll, installShellFiles +{ lib, stdenv, fetchFromGitLab, installShellFiles , qmake, qttools -, qtsvg, qttranslations, qtxmlpatterns +, qtsvg, qtxmlpatterns , wrapQtAppsHook }: @@ -15,12 +15,6 @@ stdenv.mkDerivation rec { hash = "sha256-N9fC2tCP4TVNncatHaz5W5Mp3jOmAcEWYCl30+0myaE="; }; - patches = (substituteAll { - # See https://github.com/NixOS/nixpkgs/issues/86054 - src = ./fix-qttranslations-path.patch; - inherit qttranslations; - }); - postPatch = '' substituteInPlace src/app/translations.pri \ --replace '$$[QT_INSTALL_BINS]/$$LRELEASE' '${lib.getDev qttools}/bin/lrelease' diff --git a/pkgs/applications/misc/valentina/fix-qttranslations-path.patch b/pkgs/applications/misc/valentina/fix-qttranslations-path.patch deleted file mode 100644 index de3fe05cc8b0..000000000000 --- a/pkgs/applications/misc/valentina/fix-qttranslations-path.patch +++ /dev/null @@ -1,37 +0,0 @@ -diff --git i/src/libs/vmisc/vabstractapplication.cpp w/src/libs/vmisc/vabstractapplication.cpp -index b64817bab..5f9aa3518 100644 ---- i/src/libs/vmisc/vabstractapplication.cpp -+++ w/src/libs/vmisc/vabstractapplication.cpp -@@ -221,26 +221,26 @@ void VAbstractApplication::LoadTranslation(const QString &locale) - ClearTranslation(); - - qtTranslator = new QTranslator(this); --#if defined(Q_OS_WIN) || defined(Q_OS_MAC) -+#if defined(Q_OS_WIN) - qtTranslator->load("qt_" + locale, translationsPath(locale)); - #else -- qtTranslator->load("qt_" + locale, QLibraryInfo::location(QLibraryInfo::TranslationsPath)); -+ qtTranslator->load("qt_" + locale, QLatin1String("@qttranslations@/translations")); - #endif - installTranslator(qtTranslator); - - qtxmlTranslator = new QTranslator(this); --#if defined(Q_OS_WIN) || defined(Q_OS_MAC) -+#if defined(Q_OS_WIN) - qtxmlTranslator->load("qtxmlpatterns_" + locale, translationsPath(locale)); - #else -- qtxmlTranslator->load("qtxmlpatterns_" + locale, QLibraryInfo::location(QLibraryInfo::TranslationsPath)); -+ qtxmlTranslator->load("qtxmlpatterns_" + locale, QLatin1String("@qttranslations@/translations")); - #endif - installTranslator(qtxmlTranslator); - - qtBaseTranslator = new QTranslator(this); --#if defined(Q_OS_WIN) || defined(Q_OS_MAC) -+#if defined(Q_OS_WIN) - qtBaseTranslator->load("qtbase_" + locale, translationsPath(locale)); - #else -- qtBaseTranslator->load("qtbase_" + locale, QLibraryInfo::location(QLibraryInfo::TranslationsPath)); -+ qtBaseTranslator->load("qtbase_" + locale, QLatin1String("@qttranslations@/translations")); - #endif - installTranslator(qtBaseTranslator); - diff --git a/pkgs/applications/networking/instant-messengers/linphone/default.nix b/pkgs/applications/networking/instant-messengers/linphone/default.nix index 0002e1d57de5..ebf3341e309a 100644 --- a/pkgs/applications/networking/instant-messengers/linphone/default.nix +++ b/pkgs/applications/networking/instant-messengers/linphone/default.nix @@ -12,7 +12,7 @@ , mkDerivation , qtgraphicaleffects , qtquickcontrols2 -, qttranslations +, qttools }: # How to update Linphone? (The Qt desktop app) @@ -73,11 +73,11 @@ mkDerivation rec { minizip-ng qtgraphicaleffects qtquickcontrols2 - qttranslations ]; nativeBuildInputs = [ cmake + qttools ]; cmakeFlags = [ diff --git a/pkgs/applications/networking/instant-messengers/qtox/default.nix b/pkgs/applications/networking/instant-messengers/qtox/default.nix index 659b6411b48a..8273a6fdbc6d 100644 --- a/pkgs/applications/networking/instant-messengers/qtox/default.nix +++ b/pkgs/applications/networking/instant-messengers/qtox/default.nix @@ -12,7 +12,6 @@ , qtbase , qtsvg , qttools -, qttranslations , ffmpeg , filter-audio , libexif @@ -44,7 +43,6 @@ mkDerivation rec { libXScrnSaver qtbase qtsvg - qttranslations ffmpeg filter-audio libexif diff --git a/pkgs/applications/networking/mailreaders/trojita/default.nix b/pkgs/applications/networking/mailreaders/trojita/default.nix index cd0a61f6636d..395e9b0f4e3f 100644 --- a/pkgs/applications/networking/mailreaders/trojita/default.nix +++ b/pkgs/applications/networking/mailreaders/trojita/default.nix @@ -16,8 +16,6 @@ , qtkeychain , qttools , qtwebkit -, qttranslations -, substituteAll , withI18n ? false }: @@ -39,12 +37,6 @@ in mkDerivation rec { sha256 = "sha256-15G9YjT3qBKbeOKfb/IgXOO+DaJaTULP9NJn/MFYZS8="; }; - patches = (substituteAll { - # See https://github.com/NixOS/nixpkgs/issues/86054 - src = ./fix-qttranslations-path.patch; - inherit qttranslations; - }); - buildInputs = [ akonadi-contacts gpgme diff --git a/pkgs/applications/networking/mailreaders/trojita/fix-qttranslations-path.patch b/pkgs/applications/networking/mailreaders/trojita/fix-qttranslations-path.patch deleted file mode 100644 index c4eac3956508..000000000000 --- a/pkgs/applications/networking/mailreaders/trojita/fix-qttranslations-path.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git i/src/Gui/main.cpp w/src/Gui/main.cpp -index 851db4f1..e997f46e 100644 ---- i/src/Gui/main.cpp -+++ w/src/Gui/main.cpp -@@ -52,7 +52,7 @@ int main(int argc, char **argv) - - QTranslator qtTranslator; - qtTranslator.load(QLatin1String("qt_") + QLocale::system().name(), -- QLibraryInfo::location(QLibraryInfo::TranslationsPath)); -+ QLatin1String("@qttranslations@/translations")); - app.installTranslator(&qtTranslator); - - QLatin1String localeSuffix("/locale"); diff --git a/pkgs/applications/office/PageEdit/default.nix b/pkgs/applications/office/PageEdit/default.nix index b95eb6cb51e4..858995c05fa7 100644 --- a/pkgs/applications/office/PageEdit/default.nix +++ b/pkgs/applications/office/PageEdit/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, qtsvg, qtwebengine, qttranslations, wrapQtAppsHook }: +{ lib, stdenv, fetchFromGitHub, cmake, qtsvg, qtwebengine, wrapQtAppsHook, qttools }: stdenv.mkDerivation rec { pname = "pageedit"; @@ -11,7 +11,7 @@ stdenv.mkDerivation rec { hash = "sha256-naoflFANeMwabbdrNL3+ndvEXYT4Yqf+Mo77HcCexHE="; }; - nativeBuildInputs = [ cmake qttranslations wrapQtAppsHook ]; + nativeBuildInputs = [ cmake wrapQtAppsHook qttools ]; propagatedBuildInputs = [ qtsvg qtwebengine ]; cmakeFlags = [ "-DINSTALL_BUNDLED_DICTS=0" ]; diff --git a/pkgs/applications/science/astronomy/stellarium/default.nix b/pkgs/applications/science/astronomy/stellarium/default.nix index 00b36de28089..e2e1cda4c259 100644 --- a/pkgs/applications/science/astronomy/stellarium/default.nix +++ b/pkgs/applications/science/astronomy/stellarium/default.nix @@ -11,13 +11,13 @@ , qtpositioning , qtmultimedia , qtserialport -, qttranslations , qtwayland , qtwebengine , calcmysky , qxlsx , indilib , libnova +, qttools }: stdenv.mkDerivation rec { @@ -52,6 +52,7 @@ stdenv.mkDerivation rec { perl wrapGAppsHook wrapQtAppsHook + qttools ]; buildInputs = [ @@ -60,7 +61,6 @@ stdenv.mkDerivation rec { qtpositioning qtmultimedia qtserialport - qttranslations qtwebengine calcmysky qxlsx diff --git a/pkgs/development/libraries/kdb/default.nix b/pkgs/development/libraries/kdb/default.nix index 5ab33fcf46fd..f9aa5dc369c6 100644 --- a/pkgs/development/libraries/kdb/default.nix +++ b/pkgs/development/libraries/kdb/default.nix @@ -4,12 +4,12 @@ , fetchpatch , extra-cmake-modules , qtbase -, qttranslations , kcoreaddons , python3 , sqlite , postgresql , libmysqlclient +, qttools }: mkDerivation rec { @@ -34,9 +34,9 @@ mkDerivation rec { }) ]; - nativeBuildInputs = [ extra-cmake-modules ]; + nativeBuildInputs = [ extra-cmake-modules qttools ]; - buildInputs = [ qttranslations kcoreaddons python3 sqlite postgresql libmysqlclient ]; + buildInputs = [ kcoreaddons python3 sqlite postgresql libmysqlclient ]; propagatedBuildInputs = [ qtbase ]; diff --git a/pkgs/development/libraries/kde-frameworks/kirigami2.nix b/pkgs/development/libraries/kde-frameworks/kirigami2.nix index 281a490bf90a..a47182fda5e5 100644 --- a/pkgs/development/libraries/kde-frameworks/kirigami2.nix +++ b/pkgs/development/libraries/kde-frameworks/kirigami2.nix @@ -1,8 +1,8 @@ -{ mkDerivation, extra-cmake-modules, qtbase, qtquickcontrols2, qttranslations, qtgraphicaleffects }: +{ mkDerivation, extra-cmake-modules, qtbase, qtquickcontrols2, qtgraphicaleffects, qttools }: mkDerivation { pname = "kirigami2"; - nativeBuildInputs = [ extra-cmake-modules ]; - buildInputs = [ qtbase qtquickcontrols2 qttranslations qtgraphicaleffects ]; + nativeBuildInputs = [ extra-cmake-modules qttools ]; + buildInputs = [ qtbase qtquickcontrols2 qtgraphicaleffects ]; outputs = [ "out" "dev" ]; } diff --git a/pkgs/games/qgo/default.nix b/pkgs/games/qgo/default.nix index cc28ebc63f3c..ec7986c6a36b 100644 --- a/pkgs/games/qgo/default.nix +++ b/pkgs/games/qgo/default.nix @@ -4,7 +4,7 @@ , qmake , qtbase , qtmultimedia -, qttranslations +, qttools }: mkDerivation { @@ -41,6 +41,6 @@ mkDerivation { postPatch = '' sed -i 's|@out@|'"''${out}"'|g' src/src.pro src/defines.h ''; - nativeBuildInputs = [ qmake ]; - buildInputs = [ qtbase qtmultimedia qttranslations ]; + nativeBuildInputs = [ qmake qttools ]; + buildInputs = [ qtbase qtmultimedia ]; } diff --git a/pkgs/tools/misc/ksnip/default.nix b/pkgs/tools/misc/ksnip/default.nix index 853db8ab45a5..bae675b49599 100644 --- a/pkgs/tools/misc/ksnip/default.nix +++ b/pkgs/tools/misc/ksnip/default.nix @@ -7,7 +7,7 @@ , kimageannotator , wrapQtAppsHook , qtsvg -, qttranslations +, qttools , qtx11extras }: @@ -26,13 +26,13 @@ stdenv.mkDerivation rec { cmake extra-cmake-modules wrapQtAppsHook + qttools ]; buildInputs = [ kcolorpicker kimageannotator qtsvg - qttranslations qtx11extras ]; diff --git a/pkgs/tools/security/nitrokey-app/default.nix b/pkgs/tools/security/nitrokey-app/default.nix index 8f8991801f7c..d48047a7b1c6 100644 --- a/pkgs/tools/security/nitrokey-app/default.nix +++ b/pkgs/tools/security/nitrokey-app/default.nix @@ -3,10 +3,10 @@ , cmake , fetchFromGitHub , pkg-config -, qttranslations , wrapQtAppsHook , libnitrokey , cppcodec +, qttools }: stdenv.mkDerivation rec { @@ -24,7 +24,7 @@ stdenv.mkDerivation rec { cmake pkg-config wrapQtAppsHook - qttranslations + qttools ]; cmakeFlags = [ diff --git a/pkgs/tools/security/qdigidoc/default.nix b/pkgs/tools/security/qdigidoc/default.nix index 19ce14f915aa..8a8fa4496c38 100644 --- a/pkgs/tools/security/qdigidoc/default.nix +++ b/pkgs/tools/security/qdigidoc/default.nix @@ -10,8 +10,8 @@ , openssl , pcsclite , qtbase -, qttranslations , qtsvg +, qttools }: mkDerivation rec { @@ -29,7 +29,7 @@ mkDerivation rec { sha256 = "1cikz36w9phgczcqnwk4k3mx3kk919wy2327jksmfa4cjfjq4a8d"; }; - nativeBuildInputs = [ cmake gettext pkg-config ]; + nativeBuildInputs = [ cmake gettext pkg-config qttools ]; postPatch = '' substituteInPlace client/CMakeLists.txt \ @@ -44,7 +44,6 @@ mkDerivation rec { pcsclite qtbase qtsvg - qttranslations ]; # qdigidoc4's `QPKCS11::reload()` dlopen()s "opensc-pkcs11.so" in QLibrary, diff --git a/pkgs/tools/security/web-eid-app/default.nix b/pkgs/tools/security/web-eid-app/default.nix index f392fb0147bd..3c89790e2ffc 100644 --- a/pkgs/tools/security/web-eid-app/default.nix +++ b/pkgs/tools/security/web-eid-app/default.nix @@ -5,7 +5,7 @@ , gtest , pcsclite , pkg-config -, qttranslations +, qttools }: mkDerivation rec { @@ -23,12 +23,12 @@ mkDerivation rec { nativeBuildInputs = [ cmake pkg-config + qttools ]; buildInputs = [ gtest # required during build of lib/libelectronic-id/lib/libpcsc-cpp pcsclite - qttranslations ]; meta = with lib; {