[luatex] lyluatex compile problems

Urs Liska lists at openlilylib.org
Mon Jul 30 11:03:11 CEST 2018



Am 29.07.2018 um 18:50 schrieb liebrecht at grossmann-venter.com:
> Urs,
>
> Thanks for thy kind and detailed answer.
> There is currently NO commercial software I could find that can 
> intermingle TeX and Musical Nortation.

Ah, now I get the connection to your other posts on the Frescobaldi list ;-)

> I am really thankful that you guys did this.
> Now if only you have a midi interface that could play the Notation in 
> the document by means of player buttons, but I understand that doesnt 
> exist yet.
> Frescobaldi does that, but unfortunately cannot add text inline to 
> scores creating a document.
>
> I might want to create such a frontend for lyluatex.

A solution to this is probably not that far-fetched, but in order to get 
there you have to either get to a clear understanding of what you want 
to achieve or - if you actually have that - communicate it clearly so we 
all know where we want to get. I think you have a very valid use case 
here that would be good to support.

I *think* what you will want is to have the score examples accompanied 
by *links* (in whatever graphical form, as plain text links or as fancy 
graphic buttons). These links should point to either the MIDI files 
created by LilyPond, *or* to audio files that have been generated from 
these MIDI files in advance. I can think of no other suitable concept of 
having a "document" play back the score examples. If I'm missing 
anything please correct me.

Here's what has to be done to achieve that goal. Please create an issue 
at https://github.com/jperon/lyluatex/issues and copy as much 
information as possible/useful from this thread. I would not want to 
continue discussion here because it really isn't a "luatex" issue but 
relates to lyluatex and LilyPond directly:

  * lyluatex has to make LilyPond also produce the MIDI files beside the
    scores.
    This has not been implemented yet, but should be a minor thing to do
    (and as said, I find this a valuable use case)
  * lyluatex will then (automatically) produce poth a
    <unique-hash-name>.pdf and a <same-unique-hash-name>.midi file in
    the cache directory
  * With the 'raw-pdf' option lyluatex will return that calculated base
    name instead of directly including the score as an image.
  *  From there you can create a macro that will include the image and
    create a link to the midi file.
    This can be done with standard LaTeX means
  * Or you can add a hook in between to call another external program to
    generate the corresponding audio file and link to that.
    This would probably be (much) easier to program in Lua, since Lua is
    present anyway.


>
> I will take your concerns noted below seriously.
> It is just difficult to figure out the differences between
> luatex, lyluatex, lualatex and which interfaces with lillypond for 
> someone new to luatex (I am an old-time LaTeX/TeX user though )
> So I will step on your toes for a while unintentionally.
>
>
> Are you going to remove lyluatex.tex file in future ?
> The reason I ask is that I want to learn lyluatex by studying the code 
> creating the manual, so I will have to add all the other packages in 
> the headers of the TeX file.
> If I am not supposed to have it let me know, but the manual does 
> EXACTLY what I want so it THE example file for me. It has everything 
> by design.
This last assumption is on spot.
And no, we're not going to remove that file.

In the development repository we author the manual in a Markdown file, 
and it is compiled through Pandoc. But the make rule for producing the 
CTAN upload the Markdown file is compiled to the corresponding .tex 
file. So that lyluatex.tex file is an official part of the CTAN package 
(and I would assume that it is also copied *somewhere* into your texlive 
installation).


>
> If I am allowed to use it and you have the time and patience...
> 1) Are only the packages listed n the header needed to compile the 
> manual ?

You should also look into the the lyluatex.sty file since that also 
loads a number of packages. But AFAIK there are no *special* packages 
needed that aren't available in regular TeX Live (I just don't know what 
happens if you haven't installed texlive-full).

> 2) Are there any other unforseen issues compiling it you know of that 
> could save me time before I delve into it myself ?

 From what I can see in your communications I'm not 100% confident you 
have set up LilyPond properly already.
lyluatex does its work by calling LilyPond as an external command, so 
that has to be a) installed and b) found by lyluatex.
If you don't have a working environment I suggest downloading the 
current development version from http://lilypond.org/development.html 
(they are not at all "unstable" in the case of LilyPond) and installing 
it (I don't know what OS you are having).

If you are on a UNIX OS and can run "lilypond --version" after the 
installation everything should be fine, but if you have to specify any 
other command line you have to provide this to lyluatex through the 
[program={path/to/lilypond/executable}] option.

If you still have errors after that please report with more details - we 
have tried to make the error handling as informative as possible - but 
do so on the lyluatex issue tracker, not here.

>
> This is possibly the best music typeset software that I have seen in 
> my life.
> I cannot think of anything that can beat it.
> Enormous !!!
> Hope the Universities at least will use it and stop teaching people to 
> be Joe-mousepusher.

Having literally spent years with this topic I can't give you too much 
hope about this :-(

Best
Urs

>
>
> Thanks
>
> On 2018-07-29 12:28, Urs Liska wrote:
>> Am 29.07.2018 um 17:59 schrieb liebrecht at grossmann-venter.com:
>>> a) Ok good to know that explains the compiling problems fundamentally.
>>> If the manual were a lyluatex file it would have been one of the 
>>> greatest tutorials right there.
>>> What I tried to compile is the manual in the zip download here
>>> "https://ctan.org/pkg/lyluatex?lang=en"
>>> Which seemed to be the  lyluatex code, but I am seemingly mistaken.
>>
>> No, you're not mistaken. I wasn't aware of the fact that the script
>> preparing the CTAN upload actually produced that lyluatex.tex file.
>>
>>>
>>> b) Ok
>>>
>>> c) Ok I saw that, but where that was mentioned there was no direct 
>>> compile instruction. The option --shell-escape was mentioned in the 
>>> body text and there was no direct compile command.
>>> If
>>> "lualatex --shell-escape somefile.tex"
>>> were in the instructions I did not have to ask this question, but it 
>>> is absent.
>>> Would be a good idea to add that.
>>
>> I'll try to keep that in mind. It would be great if you could open an
>> issue on the Github issue tracker at
>> https://github.com/jperon/lyluatex/issues about it.
>>
>>>
>>>
>>> Question:
>>> 1) Since I cannot compile the manual and use that to learn lyluatex, 
>>> (my preferred latex way to learn is just to work through the code 
>>> compiling the manual. (Last 20+ more years taught me that is by far 
>>> the best way.)
>>> Is there an indepth lyluatex manual that is compilable with luatex ?
>>
>> This .tex file *is* compilable with lualatex (not luatex!).
>> Please first try the other things I told you about, and if that
>> doesn't work please post more details about the errors. But this is
>> not a luatex issue, so this list may not be right place to discuss.
>> Please either subscribe to the lilypond-user mailing list or open an
>> issue on the issue tracker.
>>
>>> 2) Is there an archive with lots of lyluatex document examples 
>>> combining both text and musical notaion in the document ?
>>
>> lyluatex is actually brand new, so there is no such archive (yet).
>>
>> HTH
>> Urs

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/luatex/attachments/20180730/c5f005be/attachment.html>


More information about the luatex mailing list