Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fcitx-libpinyin: fix data path #39472

Merged
merged 1 commit into from Apr 27, 2018
Merged

fcitx-libpinyin: fix data path #39472

merged 1 commit into from Apr 27, 2018

Conversation

ChengCat
Copy link
Contributor

Motivation for this change

fcitx-libpinyin is currently unusable, because it can't find the data files. It seems impossible to fix this issue without patching.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

if (type == LPLT_Simplified) {
#endif
- /* portable detect here */
- if (getenv("FCITXDIR")) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the current value of FCITXDIR?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's set to $out of fcitx-with-plugins:

We want FCITXDIR to point into libpinyin, which is currently not symlinked within fcitx-with-plugins (only fcitx-libpinyin is symlinked). Also, FCITXDIR doesn't accept multiple directories.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add this explanation to the code? it is not obvious why we remove this option.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the suggestion. I've done the explanation.

@Mic92
Copy link
Member

Mic92 commented Apr 27, 2018

@GrahamcOfBorg build fcitx-libpinyin

@GrahamcOfBorg
Copy link

No attempt on x86_64-darwin (full log)

The following builds were skipped because they don't evaluate on x86_64-darwin: fcitx-libpinyin

Partial log (click to expand)

Cannot nix-instantiate `fcitx-libpinyin' because:
�[31;1merror:�[0m attribute 'fcitx-libpinyin' in selection path 'fcitx-libpinyin' not found

@GrahamcOfBorg
Copy link

No attempt on aarch64-linux (full log)

The following builds were skipped because they don't evaluate on aarch64-linux: fcitx-libpinyin

Partial log (click to expand)

Cannot nix-instantiate `fcitx-libpinyin' because:
�[31;1merror:�[0m attribute 'fcitx-libpinyin' in selection path 'fcitx-libpinyin' not found

@GrahamcOfBorg
Copy link

No attempt on x86_64-linux (full log)

The following builds were skipped because they don't evaluate on x86_64-linux: fcitx-libpinyin

Partial log (click to expand)

Cannot nix-instantiate `fcitx-libpinyin' because:
error: attribute 'fcitx-libpinyin' in selection path 'fcitx-libpinyin' not found

@Mic92
Copy link
Member

Mic92 commented Apr 27, 2018

@GrahamcOfBorg build libpinyin

@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: libpinyin

Partial log (click to expand)

/nix/store/ir3cq4s9jbj077ghcfnq888fqz8l7czm-libpinyin-2.1.91

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: libpinyin

Partial log (click to expand)

these paths will be fetched (10.87 MiB download, 47.15 MiB unpacked):
  /nix/store/wkiy2fqkivs3grx6zppajibvwip6c3ry-libpinyin-2.1.91
copying path '/nix/store/wkiy2fqkivs3grx6zppajibvwip6c3ry-libpinyin-2.1.91' from 'https://cache.nixos.org'...
/nix/store/wkiy2fqkivs3grx6zppajibvwip6c3ry-libpinyin-2.1.91

@GrahamcOfBorg
Copy link

No attempt on x86_64-darwin (full log)

The following builds were skipped because they don't evaluate on x86_64-darwin: libpinyin

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnsupportedSystem = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnsupportedSystem = true; }
to ~/.config/nixpkgs/config.nix.


@Mic92 Mic92 merged commit 37e7901 into NixOS:master Apr 27, 2018
@Mic92
Copy link
Member

Mic92 commented Apr 27, 2018

18.03 backport:

[detached HEAD 492d812] fcitx-libpinyin: fix data path
Author: Yucheng Zhang yu@cheng.cat
Date: Wed Apr 25 15:39:43 2018 +0800
2 files changed, 26 insertions(+)
create mode 100644 pkgs/tools/inputmethods/fcitx-engines/fcitx-libpinyin/datapath.patch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants