[MacPorts] #44220: latexml fails in ACTIVATION step. "mktexlsr not found"
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" -----------------------------+-------------------------------- Reporter: damon.english@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Keywords: | Port: -----------------------------+-------------------------------- Mac OS X 10.9.3, xcode 5.1.1, MacTex (texlive 2014) All depedencies report proper installation. {{{ :notice:activate :notice:activate LaTeXML works best with some version of TeX installed. Please install MacTeX or 'sudo port install texlive' (or other system) first. :notice:activate :debug:activate Executing proc-post-org.macports.activate-activate-0 :info:activate sh: mktexlsr: command not found :info:activate Command failed: mktexlsr :info:activate Exit code: 127 :error:activate org.macports.activate for port LaTeXML returned: command execution failed :debug:activate Error code: NONE :debug:activate Backtrace: command execution failed while executing "proc-post-org.macports.activate-activate-0 org.macports.activate" ("eval" body line 1) invoked from within "eval $post $targetname" :info:activate Warning: targets not executed for LaTeXML: org.macports.activate :notice:activate Please see the log file for port LaTeXML for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_tex_LaTeXML/LaTeXML/main.log }}} -- Ticket URL: <https://trac.macports.org/ticket/44220> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Changes (by mf2k@…): * owner: macports-tickets@… => bruce.miller@… * port: => LaTeXML Comment: In the future, please fill in the Port field and Cc the port maintainers ({{{port info --maintainers LaTeXML}}}). -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:1> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by bruce.miller@…): It appears that I have (at least) 2 problems in my Portfile, in trying to deal with installing LaTeXML-specific LaTeX style files into whatever TeX installation is present (it wants to find 2 commands: kpsewhich and mktexlsr). Presumably it works fine if MacPort's texlive is installed (? not yet tested separately). However it fails to detect MacTeX's presence: On my system, MacTeX's binaries ended up in {{{/usr/texbin/}}}, which MacTeX has pushed onto {{{$PATH}}}. I just now see the documentation on {{{binpath}}}, that the {{{$PATH}}} being used within port is restricted, but it is recommended not to mess with it. Is there a legitimate way to use the user's {{{$PATH}}}? (it wouldn't be very maintainable to explicitly add {{{/usr/texbin/}}}, since that assumes MacTeX with its default installation). The second problem is the last line of the Portfile: {{{ post-activate { system "mktexlsr" } }}} That needs to run ''after'' the real (not staged) installation, to freshen TeX's database of installed style files so that it sees LaTeXML's new files. However, it really should be "soft" because we don't know whether there really ''is'' a mktexlsr available. Would it be safe to simply recode that as: {{{ post-activate { system "which mktexlsr && mktexlsr" } }}} or is there a better way? Thanks for any help... -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:2> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by bruce.miller@…): Ah, so the various scripts are TCL, so maybe the following is best: {{{ post-activate { catch { exec "mktexlsr" } } }}} After "fixing" that, I discovered that even with a proper Portfile, I still end up with the problem that the executables are installed in {{{/opt/local/libexec/perl5.16/sitebin/}}}, which is not in the typical user's path. Nor does that path get added automatically, as does {{{/opt/local/bin}}}. And frankly, it seems perverse to print a message to the user "Please add /opt/local/libexc/perl6.16/sitebin/ to your $PATH". From previous discussions here and on the mailing list, I gathered that the "recommended" solution is to add symlinks from {{{/opt/local/bin}}} to the actual installation. I've made those changes to the Portfile; Please, portfile experts take a look. If it's acceptable, please, @sean, could you commit the change? Thanks -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:3> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by bruce.miller@…): I replaced the exec command by {{{system "mktexlsr || true" }}}, as suggested by Joshua Root (it seems a bit cleaner). But I couldn't get PortGroup perl5 to link the binaries, so I left in the explicit links in post-activate (and remove them in post- deactivate). -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:4> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by mojca@…): There are a lot of problems with the current approach, but the changes you proposed in the diff (`pre-activate` and `post-deactivate`) should be done during the `post-destroot` phase. Then the symlinks get removed automatically with deactivate. -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:5> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by bruce.miller@…): OK, let's try a completely different approach... Firstly, I did manage to get PortGroup perl5 to work (noting that it does nothing useful unless you call {{{perl5.setup}}}; that could stand to be documented a bit better in the MacPorts Guide). So the intstallation of executables seems well solved. To deal with the various possible TeX installations, I created two variants: * default: no assumption of there being a TeX installation; doesn't install LaTeXML's style files. * +texlive: adds dependency on macport's texlive and installs LaTeXML's style files in texlive's texmf. * +mactex: verifies(?) presence of MacTeX, installs LaTeXML's style files in MacTeX's texmf. I've set {{{destroot.violate_mtree}}} to clarify that this is intentional. This gets pretty close to MacPort's ideal of clean, reproducible installation, since it only mucks around outside macports when you explicitly ask for it. It gives up some "automagic", but I suppose if there are other TeX candidates, they'll need their own variant. Is this reasonable and/or acceptable? -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:7> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by damon.english@…): Could this trouble ticket get some attention please? -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:8> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: fixed | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Changes (by cal@…): * status: new => closed * resolution: => fixed Comment: Replying to [comment:7 bruce.miller@…]:
Firstly, I did manage to get PortGroup perl5 to work (noting that it does nothing useful unless you call {{{perl5.setup}}}; that could stand to be documented a bit better in the MacPorts Guide). So the intstallation of executables seems well solved.
Yes, I agree documentation of the PortGroups currently lacks.
Is this reasonable and/or acceptable?
Sounds reasonable to me, r122050. This could probably be improved by automatically adding the relevant variant to the default variants if a TeX installation is detected, but I'd rather get this out now than delay it more. Btw, users that want to use MacTeX are expected to add `/usr/texbin` to their path in `macports.conf` manually. -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:9> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: fixed | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by damon.english@…): Thanks for the response. I still get the same error. I tried clean, uninstall, clean, install. Do I need to wait? Also, where in macports do I add /usr/textbin to the path? To binpath, (seems the logical choice but I would like confirmation please)? -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:10> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: fixed | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by cal@…): Did you run selfupdate before trying? Also, updates may be delayed by up to 30 minutes, so if it didn't work right away, try again now. Yes, `/usr/texbin` needs to be added to `binpath` in `$prefix/etc/macports/macports.conf`. -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:11> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: fixed | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by damon.english@…): Ah... no, I had not run selfupdate. Now that I have (as well as 'upgrade outdated'), I get ---> Fetching archive for LaTeXML ---> Attempting to fetch LaTeXML-0.8.0_0.darwin_13.x86_64.tbz2 from http://packages.macports.org/LaTeXML ...[many more repositories attempted here] ---> Attempting to fetch LaTeXML-0.8.0.tar.gz from http://svn.macports.org/repository/macports/distfiles/LaTeXML Error: org.macports.fetch for port LaTeXML returned: fetch failed Is this just the 30 minute propagation delay? -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:12> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: fixed | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by cal@…): Sorry, that was my bad. Fixed in r122061. -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:13> MacPorts <http://www.macports.org/> Ports system for OS X
#44220: latexml fails in ACTIVATION step. "mktexlsr not found" ------------------------------+---------------------------- Reporter: damon.english@… | Owner: bruce.miller@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.1 Resolution: fixed | Keywords: Port: LaTeXML | ------------------------------+---------------------------- Comment (by damon.english@…): Ok. Well it seems to install, with warnings. Thanks to one and all. {{{ Warning: violation by /usr Warning: LaTeXML violates the layout of the ports-filesystems! Warning: Please fix or indicate this misbehavior (if it is intended), it will be an error in future releases! ---> Installing LaTeXML @0.8.0_0 ---> Activating LaTeXML @0.8.0_0 LaTeXML works best with some version of TeX installed. Please consider +texlive variant, or PRE-install MacTeX and use +mactex variant. ---> Cleaning LaTeXML ---> Updating database of binaries ---> Scanning binaries for linking errors ---> No broken files found. }}} -- Ticket URL: <https://trac.macports.org/ticket/44220#comment:14> MacPorts <http://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts