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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

blobmoji: Init at 2019-06-14-Emoji-12 #65507

Closed
wants to merge 1 commit into from
Closed

blobmoji: Init at 2019-06-14-Emoji-12 #65507

wants to merge 1 commit into from

Conversation

dasJ
Copy link
Member

@dasJ dasJ commented Jul 28, 2019

Motivation for this change

Real emoji have curves! 馃槫

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option 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 nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.


installPhase = ''
mkdir -p $out/share/fonts/noto
cp NotoColorEmoji.ttf fonts/Blobmoji.ttf $out/share/fonts/noto
Copy link
Member

Choose a reason for hiding this comment

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

Should it be copying NotoColorEmoji.ttf to the output? Both files have the font name "Blobmoji"

[nix-shell:~/tmp/nixpkgs/nixpkgs]$ ls -lh result/share/fonts/noto/
total 16M
-r--r--r-- 1 root root 8.0M Dec 31  1969 Blobmoji.ttf
-r--r--r-- 1 root root 7.4M Dec 31  1969 NotoColorEmoji.ttf

I am concerned in two things

  • NotoColorEmoji.ttf clashing with noto color emoji.
  • Both font files fighting for the Blobmoji font name.

It seems that releases only include Blobmoji.ttf. That file being bigger also makes me think the NotoColorEmoji is a transient build artifact. Though, I wasn't able to figure it quickly.

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm aware of the potential conflict. But as blobmoji is just noto color with additional blobby emoji so it's unlikely somebody would use both at the same time.

Copy link
Member

Choose a reason for hiding this comment

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

The thing is the filename is NotoColorEmoji, but the font name is Blobmoji Regular. I think (though I'm not sure) that this is an issue since both font files will respond to the Blobmoji Regular font name.

That is more confusing with the conflict with the presence of NotoColorEmoji.ttf file. The conflict breaks the assumption that the noto color emoji font (by name) is made available.

I'm not sure if either of @jtojnar or @worldofpeace would know more about issues this could cause (they recently worked on color emoji stuff).

Copy link
Contributor

@jtojnar jtojnar Sep 17, 2019

Choose a reason for hiding this comment

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

Fontconfig chooses a font based on distance from a vector of properties. File name is one of the matched properties but I doubt either of them would win based on that, unless the application explicitly asked for that file name. Not sure what happens when both have the same distance, would need to see the files. On the other hand, if NotoColorEmoji.ttf fits better, it could definitely win.

enableParallelBuilding = true;

postPatch = ''
sed -i 's,^PNGQUANT :=.*,PNGQUANT := ${pngquant}/bin/pngquant,' Makefile
Copy link
Contributor

Choose a reason for hiding this comment

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

You should be able to use makeFlags = [ "PNGQUANT=pngquant" ]; instead of patching the file. Hopefully, they will default to this in the future like upstream Noto did.

@dasJ dasJ closed this Feb 5, 2020
@dasJ dasJ deleted the init-blobmoji branch February 5, 2020 00:11
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