nixos: remove qtPlugins and gtkPlugins

Both Qt and GTK load plugins from the active profiles
automatically, so it is sufficient to install input methods
system-wide. Overriding the plugin paths may interfere with correct
operation of other plugins.
This commit is contained in:
Thomas Tuegel 2016-02-27 06:16:42 -06:00
parent 1af8a3498c
commit a91161aa57
6 changed files with 0 additions and 85 deletions

View File

@ -1,41 +0,0 @@
{ config, pkgs, lib, ... }:
{
imports = [
];
options = {
gtkPlugins = lib.mkOption {
type = lib.types.listOf lib.types.path;
default = [];
description = ''
Plugin packages for GTK+ such as input methods.
'';
};
};
config = {
environment.variables = if builtins.length config.gtkPlugins > 0
then
let
paths = [ pkgs.gtk2 pkgs.gtk3 ] ++ config.gtkPlugins;
env = pkgs.buildEnv {
name = "gtk-exe-env";
inherit paths;
postBuild = lib.concatStringsSep "\n"
(map (d: d.gtkExeEnvPostBuild or "") paths);
ignoreCollisions = true;
};
in {
GTK_EXE_PREFIX = builtins.toString env;
GTK_PATH = [
"${env}/lib/gtk-2.0"
"${env}/lib/gtk-3.0"
];
}
else {};
};
}

View File

@ -1,37 +0,0 @@
{ config, pkgs, lib, ... }:
{
imports = [
];
options = {
qtPlugins = lib.mkOption {
type = lib.types.listOf lib.types.path;
default = [];
description = ''
Plugin packages for Qt such as input methods.
'';
};
};
config = {
environment.variables = if builtins.length config.qtPlugins > 0
then
let
paths = [ pkgs.qt48 ] ++ config.qtPlugins;
env = pkgs.buildEnv {
name = "qt-plugin-env";
inherit paths;
postBuild = lib.concatStringsSep "\n"
(map (d: d.qtPluginEnvPostBuild or "") paths);
ignoreCollisions = true;
};
in {
QT_PLUGIN_PATH = [ (builtins.toString env) ];
}
else {};
};
}

View File

@ -29,8 +29,6 @@ in
config = mkIf (config.i18n.inputMethod.enabled == "fcitx") {
environment.systemPackages = [ fcitxPackage ];
gtkPlugins = [ fcitxPackage ];
qtPlugins = [ fcitxPackage ];
environment.variables = {
GTK_IM_MODULE = "fcitx";

View File

@ -4,7 +4,6 @@ with lib;
{
config = mkIf (config.i18n.inputMethod.enabled == "nabi") {
environment.systemPackages = [ pkgs.nabi ];
qtPlugins = [ pkgs.nabi ];
environment.variables = {
GTK_IM_MODULE = "nabi";

View File

@ -23,8 +23,6 @@ in
config = mkIf (config.i18n.inputMethod.enabled == "uim") {
environment.systemPackages = [ pkgs.uim ];
gtkPlugins = [ pkgs.uim ];
qtPlugins = [ pkgs.uim ];
environment.variables = {
GTK_IM_MODULE = "uim";

View File

@ -7,7 +7,6 @@
./config/fonts/fonts.nix
./config/fonts/ghostscript.nix
./config/gnu.nix
./config/gtk-exe-env.nix
./config/i18n.nix
./config/krb5.nix
./config/ldap.nix
@ -16,7 +15,6 @@
./config/nsswitch.nix
./config/power-management.nix
./config/pulseaudio.nix
./config/qt-plugin-env.nix
./config/shells-environment.nix
./config/swap.nix
./config/sysctl.nix