From 84f727c463f129254cad9b55962d18d84d545333 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9ana=20=E6=B1=9F?= Date: Mon, 26 May 2025 00:13:14 +0200 Subject: [PATCH] vanadium: disable fcitx5 quickphrase --- nix/configurations/vanadium/nixos/overlay.nix | 1 + .../patches/fcitx5/disable-quickphrase.patch | 46 +++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 nix/configurations/vanadium/nixos/patches/fcitx5/disable-quickphrase.patch diff --git a/nix/configurations/vanadium/nixos/overlay.nix b/nix/configurations/vanadium/nixos/overlay.nix index 85a4fd37..dec7deb7 100644 --- a/nix/configurations/vanadium/nixos/overlay.nix +++ b/nix/configurations/vanadium/nixos/overlay.nix @@ -30,5 +30,6 @@ in ]; fcitx5.__output.patches.__append = [ ./patches/fcitx5/disable-clipboard.patch + ./patches/fcitx5/disable-quickphrase.patch ]; }) diff --git a/nix/configurations/vanadium/nixos/patches/fcitx5/disable-quickphrase.patch b/nix/configurations/vanadium/nixos/patches/fcitx5/disable-quickphrase.patch new file mode 100644 index 00000000..37afa2fd --- /dev/null +++ b/nix/configurations/vanadium/nixos/patches/fcitx5/disable-quickphrase.patch @@ -0,0 +1,46 @@ +diff --git a/src/modules/quickphrase/CMakeLists.txt b/src/modules/quickphrase/CMakeLists.txt +index b5bc37ac..04f4da59 100644 +--- a/src/modules/quickphrase/CMakeLists.txt ++++ b/src/modules/quickphrase/CMakeLists.txt +@@ -1,13 +1,13 @@ +-add_fcitx5_addon(quickphrase quickphrase.cpp quickphraseprovider.cpp) +-target_link_libraries(quickphrase Fcitx5::Core Fcitx5::Module::Spell) +-install(TARGETS quickphrase DESTINATION "${FCITX_INSTALL_ADDONDIR}") ++# add_fcitx5_addon(quickphrase quickphrase.cpp quickphraseprovider.cpp) ++# target_link_libraries(quickphrase Fcitx5::Core Fcitx5::Module::Spell) ++# install(TARGETS quickphrase DESTINATION "${FCITX_INSTALL_ADDONDIR}") + configure_file(quickphrase.conf.in.in quickphrase.conf.in @ONLY) + fcitx5_translate_desktop_file(${CMAKE_CURRENT_BINARY_DIR}/quickphrase.conf.in quickphrase.conf) +-install(FILES "${CMAKE_CURRENT_BINARY_DIR}/quickphrase.conf" DESTINATION "${FCITX_INSTALL_PKGDATADIR}/addon" +- COMPONENT config) ++# install(FILES "${CMAKE_CURRENT_BINARY_DIR}/quickphrase.conf" DESTINATION "${FCITX_INSTALL_PKGDATADIR}/addon" ++# COMPONENT config) + fcitx5_export_module(QuickPhrase TARGET quickphrase BUILD_INCLUDE_DIRECTORIES "${CMAKE_CURRENT_SOURCE_DIR}" HEADERS quickphrase_public.h INSTALL) + +-install(DIRECTORY quickphrase.d DESTINATION "${FCITX_INSTALL_PKGDATADIR}/data" +- COMPONENT config +- FILES_MATCHING PATTERN "*.mb") ++# install(DIRECTORY quickphrase.d DESTINATION "${FCITX_INSTALL_PKGDATADIR}/data" ++# COMPONENT config ++# FILES_MATCHING PATTERN "*.mb") + +diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt +index 97eed1f3..53e09977 100644 +--- a/test/CMakeLists.txt ++++ b/test/CMakeLists.txt +@@ -147,10 +147,10 @@ if (ENABLE_KEYBOARD) + add_test(NAME testspell COMMAND testspell) + endif() + +-add_executable(testquickphrase testquickphrase.cpp) +-target_link_libraries(testquickphrase Fcitx5::Core Fcitx5::Module::QuickPhrase Fcitx5::Module::TestFrontend Fcitx5::Module::TestIM) +-add_dependencies(testquickphrase copy-addon quickphrase testui testfrontend testim) +-add_test(NAME testquickphrase COMMAND testquickphrase) ++# add_executable(testquickphrase testquickphrase.cpp) ++# target_link_libraries(testquickphrase Fcitx5::Core Fcitx5::Module::QuickPhrase Fcitx5::Module::TestFrontend Fcitx5::Module::TestIM) ++# add_dependencies(testquickphrase copy-addon quickphrase testui testfrontend testim) ++# add_test(NAME testquickphrase COMMAND testquickphrase) + + if (ENABLE_X11) + add_executable(testxim testxim.cpp) +