contextgarden / luametatex

Temporary/draft repository with luametatex
30 stars 6 forks source link

The luametatex in TeXLive 2023 is not out of the box usable #1

Closed bitstreamout closed 1 year ago

bitstreamout commented 1 year ago

As subject says ... first is that surrounding packages are part of TeXLive but the binaries can not be build from texlive-20230311-source.tar.xz as not part of that tar ball ... and even if one builds luametatex from luametatex-230310 via cmake there is no way to use the fmtutil perl script to generate the missing formats.

walkthetalk commented 1 year ago

upvote

hanshagen commented 1 year ago

Normally context will regenerate formats when the binary and/or macros are updated.

mojca commented 1 year ago

Hans is not comfortable with tracking the issues here. I'm aware of the problem of missing sources. If you build luametatex from a separate source that you fetch from here or TL SVN, you don't need to use fmtutil. Where does the process get stuck / how can I try to help at this point?

mojca commented 1 year ago

How do you handle biber right now?

bitstreamout commented 1 year ago

On 2023/03/29 07:41:56 -0700, hanshagen wrote:

Closed #1 as completed.

This is not what I call completed.

As maintainer of TeXLive for openSUSE I have to use two patches to make luametatex usable and to be able to provide ConTeXt as system packages which has its trees, fonts infos, and formats generated at installation time below /var/lib/texmf.

Also a further scripting code is required as fmtutil does not work anymore in the postinstall scriplets of rpm.

It would be nice if not only single user Windows[tm] system but also multi user UNIX workstations would be usable out of the box.

-- Reply to this email directly or view it on GitHub: https://github.com/contextgarden/luametatex/issues/1#event-8877491937 You are receiving this because you authored the thread.

Message ID: @.***>

-- Dr. Werner Fink -- Software Engineer Consultant SUSE Software Solutions Germany GmbH, Frankenstraße 146, 90461 Nürnberg, Germany, GF: Ivo Totev, DE 322 919 152, HRB 36809 (AG Nürnberg), phone: +49-911-740-53-0, fax: +49-911-3206727, www.opensuse.org

hanshagen commented 1 year ago

fwiw, we run luametatex from the day it surfaced on opensuse servers (we've been using openuse since it showed up) , but (i admit) not using texlive, so i don't understand how it relates windows

i have no clue what fmtutil does, and i appreciate efforts to make it work, but one cannot expect me to install all linux variants out there for testing (I only tested a tex live install on windows, wls, a few linuxes and osx)

afaikt when the 5 files (luametatex/context/mtxrun and mtxrun.lua/context.lua) are in the same path and that path is relative to the tex tree in the usual way it should work, at least that is the assumed usage

anyway, i'm confident that Mojca will figure it out

(and I really dislike these semi public ways of communicating so not much input from my end here)

bitstreamout commented 1 year ago

This is what I've now

texlive/2023> rpm -qf /usr/bin/mtxrun.lua
texlive-context-bin-2023.20230311.svn66562-0.x86_64
texlive/2023> rpm -qlf /usr/bin/mtxrun.lua
/usr/bin/context
/usr/bin/context.lua
/usr/bin/luametatex
/usr/bin/mtxrun
/usr/bin/mtxrun.lua
/usr/bin/rlxtools

and two patches (can not attach as I always get an error)

context_cnf.dif

---
 texmf-dist/scripts/context/lua/mtxrun.lua     |    6 ++----
 texmf-dist/tex/context/base/mkiv/data-res.lua |    6 ++----
 2 files changed, 4 insertions(+), 8 deletions(-)

--- texmf-dist/scripts/context/lua/mtxrun.lua
+++ texmf-dist/scripts/context/lua/mtxrun.lua   2023-03-27 07:15:37.741121895 +0000
@@ -22308,10 +22308,8 @@ if environment.default_texmfcnf then
 else
  resolvers.luacnfspec=concat ({
   "home:texmf/web2c",
-  "selfautoparent:/texmf-local/web2c",
-  "selfautoparent:/texmf-context/web2c",
-  "selfautoparent:/texmf-dist/web2c",
-  "selfautoparent:/texmf/web2c",
+  "/etc/texmf/web2c",
+  "selfautodir:/share/texmf/web2c",
  },";")
 end
 local unset_variable="unset"
--- texmf-dist/tex/context/base/mkiv/data-res.lua
+++ texmf-dist/tex/context/base/mkiv/data-res.lua       2023-03-27 07:15:43.465013318 +0000
@@ -140,10 +140,8 @@ if environment.default_texmfcnf then
 else
     resolvers.luacnfspec = concat ( {
         "home:texmf/web2c",
-        "selfautoparent:/texmf-local/web2c",
-        "selfautoparent:/texmf-context/web2c",
-        "selfautoparent:/texmf-dist/web2c",
-        "selfautoparent:/texmf/web2c",
+        "/etc/texmf/web2c",
+        "selfautodir:/share/texmf/web2c",
     }, ";")
 end

the second patch luatex_cnf.dif for texmf-dist/web2c/texmfcnf.lua is to large to be shown here but in short it switches the paths to the system wide configuration. With this the rpm post install scriptlets are able to run something like

/usr/bin/mtxrun --generate 
/usr/bin/mtxrun  --script fonts --reload
[...]
for fmt in cont-cs cont-de cont-en cont-fr cont-gb cont-it cont-nl cont-pe cont-ro
do
       /usr/bin/mtxrun $fmt --make
done
hanshagen commented 1 year ago

On 3/30/2023 4:18 PM, Dr. Werner Fink wrote:

This is what I've now

|texlive/2023> rpm -qf /usr/bin/mtxrun.lua texlive-context-bin-2023.20230311.svn66562-0.x86_64 texlive/2023> rpm -qlf /usr/bin/mtxrun.lua /usr/bin/context /usr/bin/context.lua /usr/bin/luametatex /usr/bin/mtxrun /usr/bin/mtxrun.lua /usr/bin/rlxtools |

and two patches (can not attach as I always get an error)

context_cnf.dif

|--- texmf-dist/scripts/context/lua/mtxrun.lua | 6 ++---- texmf-dist/tex/context/base/mkiv/data-res.lua | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) --- texmf-dist/scripts/context/lua/mtxrun.lua +++ texmf-dist/scripts/context/lua/mtxrun.lua 2023-03-27 07:15:37.741121895 +0000 @@ -22308,10 +22308,8 @@ if environment.default_texmfcnf then else resolvers.luacnfspec=concat ({ "home:texmf/web2c", - "selfautoparent:/texmf-local/web2c", - "selfautoparent:/texmf-context/web2c", - "selfautoparent:/texmf-dist/web2c", - "selfautoparent:/texmf/web2c", + "/etc/texmf/web2c", + "selfautodir:/share/texmf/web2c", },";") end local unset_variable="unset" --- texmf-dist/tex/context/base/mkiv/data-res.lua +++ texmf-dist/tex/context/base/mkiv/data-res.lua 2023-03-27 07:15:43.465013318 +0000 @@ -140,10 +140,8 @@ if environment.default_texmfcnf then else resolvers.luacnfspec = concat ( { "home:texmf/web2c", - "selfautoparent:/texmf-local/web2c", - "selfautoparent:/texmf-context/web2c", - "selfautoparent:/texmf-dist/web2c", - "selfautoparent:/texmf/web2c", + "/etc/texmf/web2c", + "selfautodir:/share/texmf/web2c", }, ";") end |

Maybe something like this could work (but first we need to test it in the reference installation for side effects):

if environment.default_texmfcnf then -- this will go away (but then also no more checking in mtxrun.lua itself) resolvers.luacnfspec = "home:texmf/web2c;" .. environment.default_texmfcnf -- texlive + home: for taco etc else local texroot = environment.texroot resolvers.luacnfspec = "home:texmf/web2c;selfautoparent:/texmf-local/web2c;selfautoparent:/texmf-context/web2c;selfautoparent:/texmf/web2c" if texroot and isdir(texroot .. "/texmf-context") then -- we're okay and run the lean and mean installation elseif texroot and isdir(texroot .. "/texmf-dist") then -- we're in texlive where texmf-dist is leading resolvers.luacnfspec = "home:texmf/web2c;selfautoparent:/texmf-local/web2c;selfautoparent:/texmf-dist/web2c;selfautoparent:/texmf/web2c" elseif ostype ~= "windows" and isdir("/etc/texmf/web2c") then -- we have some linux distribution that does it its own way resolvers.luacnfspec = "home:texmf/web2c;/etc/texmf/web2c;selfautodir:/share/texmf/web2c" else -- we stick to the reference specification end end

the second patch luatex_cnf.dif for texmf-dist/web2c/texmfcnf.lua is to large to be shown here but in short it switches the paths to the system wide configuration. With this the rpm post install scriptlets are able to run something like

|/usr/bin/mtxrun --generate /usr/bin/mtxrun --script fonts --reload [...] for fmt in cont-cs cont-de cont-en cont-fr cont-gb cont-it cont-nl cont-pe cont-ro do /usr/bin/mtxrun $fmt --make done | i guess just

context --make

would do, no need fo tall the other user interfaces by default (saves bytes and installation time)

mtxrun --generate mtxrun --luatex --generate context --make context --luatex --make mtxrun --script font --reload

will make mkiv as well as lmtx formats

Hans


                                       Hans Hagen | PRAGMA ADE
           Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
    tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl