You are here: Foswiki>Tasks Web>Item1234 (23 Apr 2009, MichaelDaum)Edit Attach

Item1234: MathModePlugin's latex2img not executable

Priority: Normal
Current State: Closed
Released In:
Target Release: n/a
Applies To: Extension
Component: MathModePlugin
Reported By: MichaelTempest
Waiting For:
Last Change By: MichaelDaum
MathModePlugin's MANIFEST does not make latex2img executable.

After installation, it is necessary to run something like chmod a+x /var/lib/foswiki/pub/TWiki/MathModePlugin/latex2img before the plugin will work.

As per GuidelinesForSecureExtensions, latex2img should be moved to /tools, rather than living in /pub.

-- MichaelTempest

!noci in BuildContrib might be useful, too, but putting it in tools is way better.

-- WillNorris - 19 Mar 2009

The plugin is still in the (tm)wiki namespace, and it looks like it could be used in a (tm)wiki. I assume that is intentional, so the change I propose should be able to run under (tm)wiki, too.

I plan to move latex2img to /tools and make it executable via MANIFEST.

The plugin must still be able to find the latex2img if $TWiki::cfg{MathModePlugin}{Latex2Img} is not set, which means the plugin must be able to find the /tools directory. There is no offical API for this (yet). I propose that the plugin must try a number of different ways to find /tools, and use the first one that contains a latex2img executable:
  • $TWiki::cfg{LocalesDir}/../tools
    • Assumes that /tools and /locale are in the same directory
  • $FindBin::Bin/../tools
    • Assumes that /tools and /bin are in the same directory
    • Might not work under modperl

The plugin still might not find latex2img. I propose that MathModePlugin::Core::renderImages() should return an error message if the plugin cannot find latex2img.

-- MichaelTempest - 19 Mar 2009

ItemTemplate edit

Summary MathModePlugin's latex2img not executable
ReportedBy MichaelTempest
Codebase 1.0.0
SVN Range Foswiki-1.0.0, Thu, 08 Jan 2009, build 1878
AppliesTo Extension
Component MathModePlugin
Priority Normal
CurrentState Closed
Checkins MathModePlugin:8ef219938cd7 MathModePlugin:d25a77732881
TargetRelease n/a
Topic revision: r7 - 23 Apr 2009, MichaelDaum
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy