Opened 9 years ago

Closed 8 years ago

Last modified 8 years ago

#49507 closed defect (fixed)

LaTeXML: /usr/texbin/ no longer exists on 10.11

Reported by: mojca (Mojca Miklavec) Owned by: brucemiller (bruce miller)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: drkp (Dan Ports), majoc-at-astro (majoc-at-astro), indraos@…
Port: LaTeXML

Description (last modified by mojca (Mojca Miklavec))

On 10.11 MacTeX no longer creates /usr/texbin, so the post-activate commands no longer work.

Change History (18)

comment:1 Changed 9 years ago by Russell-Jones-OxPhys (Russell Jones)

Hi mojca, could you provide log output?

comment:2 Changed 9 years ago by mojca (Mojca Miklavec)

Cc: dports@… added
Description: modified (diff)

No, sorry. I didn't switch to 10.11 yet. But you should probably ask Dan (dports) about the proper way to handle this.

comment:3 Changed 9 years ago by Russell-Jones-OxPhys (Russell Jones)

OK. We've a 10.11 build server set up, and it's using /Library/TeX/texbin in macports.conf and for the PATH. Things seem mostly to be building OK, but I'll look more closely to see if I can find examples of this problem.

It looks like the port needs to look for /Library/TeX/texbin, then /usr/texbin, then fail.

I wonder if +MacTeX can (or should) be rolled in to the texlive PortGroup. I see there's some MacTeX support stuff in ${prefix}/var/macports/sources/rsync.macports.org/release/tarballs/ports/_resources/port1.0/group/texlive-1.0.tcl

comment:4 Changed 9 years ago by mojca (Mojca Miklavec)

In any case I believe that one should not call texbin from a Portfile. The PortGroup should take care of the dirty details. I didn't have time to look into this, but I wanted to create the ticket before we would forget.

comment:5 Changed 9 years ago by majoc-at-astro (majoc-at-astro)

Cc: majoc@… added

Cc Me!

comment:6 Changed 9 years ago by brucemiller (bruce miller)

You're quite right that one generally should avoid calling programs from texbin explicitly. However, the point is that I'm adding new TeX style files and want whichever TeX to be able to find them. Getting MacPort's texlive TeX to find them is pretty much handled by the texlive stuff. In the +MacTeX variant I want to ensure that MacTeX's tex can find them, so I'm calling MacTeX's kpsewhich and mktexlsr, not MacPort's. Unfortunately, since during the build the $PATH is abbreviated, I ended up having to use an explicit pathname to reach (or try to reach!) MacTeX's utilities. Of course, the danger in hard-wiring the path is exactly what has happened. Is there a more portable way to do this?

comment:7 Changed 9 years ago by brucemiller (bruce miller)

Incidentally, while it would certainly be handy in this case if the texlive PortGroup would automatically do the dirty work and re-index the new style files for MacTeX, I think it would be a bad thing to do in general. You wouldn't want all of MacPort's texlive styles to be visible to MacTeX, since they'd (possibly) override MacTeX's own files!

comment:8 Changed 9 years ago by mojca (Mojca Miklavec)

I'm not suggesting that every port using the PortGroup should do dirty trickery with MacTeX and violate MacPorts' installation locations. I would like to suggest adding some general commands to the PortGroup (in case they are not there already), so that any port installing files to MacTeX could simply call something like

    texlive.mactex.mktexlsr

as opposed to

    system /usr/texbin/mktexlsr

or whatever ten lines of code would come out of the new logic that has to consider different locations of MacTeX's binaries.

comment:9 Changed 9 years ago by brucemiller (bruce miller)

That'd be great!

You'd probably also want to provide variables to get access to the various TEXMF directories, both for texlive's locations as well as MacPort's; this would avoid the need for explicit calls to kpsewhich:

[exec /usr/texbin/kpsewhich --expand-var='\$TEXMFLOCAL']

(maybe they're already there for texlive?)

comment:10 Changed 9 years ago by mojca (Mojca Miklavec)

For the packaged texlive there is a ${texlive_texmfports} variable. I use it in gnuplot for example to install some style files. But we could easily add/hardcode /usr/local/texlive/texmf-local into some variables in the PortGroup as well.

comment:11 Changed 9 years ago by brucemiller (bruce miller)

Hmmm... now that I think about it, since LaTeXML is being "formally" installed (as part of the same installation system as texlive, itself), it may be more appropriate to use the main TEXMF tree, rather than the TEXMFLOCAL one (which you'd probably do when installing as a separate package). So, I probably should use that existing variable for the texlive variant without needing a new one. [In fact, we'd discussed in a separate ticket #47972, that we probably don't need a separate variant: we'd simply put things in the right place to be used IF texlive were installed. I'll have to do some experimenting...]

That reasoning may or may not apply to installing LaTeXML's style files into MacTeX's TEXMF tree, perhaps that should still be TEXMFLOCAL (not 100% clear on the conventions). So, in any case, a variable that pointed to some MacTeX TEXMF would be very useful to simplify the +MacTeX variant, and make it less prone to bitrot.

comment:12 Changed 9 years ago by jtkorb@…

Has this issue been resolved? Is there a workaround? I'm trying to use LaTeXML from MacPorts and it seems to insist on using /usr/texbin (under MacOS 10.11).

comment:13 Changed 8 years ago by saeta@…

As reported by russell.jones, " It looks like the port needs to look for /Library/TeX/texbin, then /usr/texbin, then fail. " Could this be taken care of, please?!

comment:14 Changed 8 years ago by brucemiller (bruce miller)

I've proposed an updated Portfile that should take care of this ticket. The issues were tangled with those of ticket #47972, so both were handed together. Please see the attachment on ticket #47972. Thanks!

comment:15 Changed 8 years ago by mf2k (Frank Schima)

Cc: indraos@… added

Cc reporter of duplicate #52089.

comment:16 Changed 8 years ago by brucemiller (bruce miller)

Please see #51818 for the current Portfile.

comment:17 Changed 8 years ago by mojca (Mojca Miklavec)

Committed in r154083. See also #51818.

Last edited 8 years ago by mojca (Mojca Miklavec) (previous) (diff)

comment:18 Changed 8 years ago by mojca (Mojca Miklavec)

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.