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

UTF_8 issues for "roman-numeral" package #52

Closed
allenloves opened this issue Mar 17, 2017 · 13 comments
Closed

UTF_8 issues for "roman-numeral" package #52

allenloves opened this issue Mar 17, 2017 · 13 comments

Comments

@allenloves
Copy link

allenloves commented Mar 17, 2017

After installing lilypond with lyp:

When I made /usr/local/bin/lilypond to be the default lilypond version in Frescobaldi, it does not generate any file even after the lilypond log replied compile successful.

When I made ~/.lyp/lilyponds/2.18.2/bin/lilypond as default version, the compiler does not recognize \require command.

Is there a way to make Frescobaldi to compile with lyp version of lilypond?

@noteflakes
Copy link
Collaborator

noteflakes commented Mar 17, 2017

I have no experience with Frescobaldi, but you'll need to set it to wherever lyp's lilypond wrapper script resides, depending on how lyp was installed. To find it, run:

$ which lilypond

And put the result in Frescobaldi settings.

Let me know if this helps.

@allenloves
Copy link
Author

allenloves commented Mar 17, 2017 via email

@noteflakes
Copy link
Collaborator

I just installed Frescobaldi 2.2 and successfully compiled a simple file including a \require command without any problem. Please try compiling this on your machine:

\require "assert"
#(assert #t)

{ c d e f }

@allenloves
Copy link
Author

allenloves commented Mar 17, 2017 via email

@noteflakes
Copy link
Collaborator

It took a while to get to the bottom of this. The problem is that Frescobaldi does not set or pass the LC_CTYPE environment variable to the lilypond wrapper, and so the default US-ASCII encoding is used. So even if you properly set LC_CTYPE in ~/.bash_profile (or ~/.bashrc etc), because Frescobaldi is GUI app it will not receive this setting.

If you're on MacOS, run sudo nano /etc/launchd.conf and add the following line:

setenv LC_CTYPE=en_US.UTF-8

And you should be good to go (I don't know how this is done on Linux.)

@allenloves
Copy link
Author

Still no luck.

@noteflakes
Copy link
Collaborator

Please give me some info on your installation:

  • OS
  • ruby version
  • lyp version

@allenloves
Copy link
Author

allenloves commented Mar 18, 2017 via email

@noteflakes
Copy link
Collaborator

Did you restart Frescobaldi after editing /etc/launchd.conf?

@allenloves
Copy link
Author

allenloves commented Mar 18, 2017 via email

@noteflakes
Copy link
Collaborator

OK, let's try to patch your lilypond gem wrapper script., Add the following line to /usr/local/bin/lilypond (you'll probably need to open it with sudo to edit it):

Encoding.default_external = Encoding::UTF_8

Put this line just after the first ("shebang") line in the script. Let me know if this solves the problem.

@allenloves
Copy link
Author

allenloves commented Mar 18, 2017 via email

@noteflakes
Copy link
Collaborator

OK. I'll try to find a way to detect this automatically without causing problems for users who use encodings other than UTF-8.

@allenloves allenloves changed the title Request: Freschbaldi Support UTF_8 issues for "roman-numeral" package Apr 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants