]> git.lyx.org Git - lyx.git/blobdiff - lib/scripts/lyxpreview2bitmap.py
make sure docs are disted
[lyx.git] / lib / scripts / lyxpreview2bitmap.py
index 5219899d40b5912798853311aebed0156045b072..bb7438bf066c31ea32cb345bd3d04bab6333f376 100755 (executable)
@@ -1,4 +1,5 @@
 #! /usr/bin/env python
+# -*- coding: iso-8859-1 -*-
 
 # file lyxpreview2bitmap.py
 # This file is part of LyX, the document processor.
@@ -7,7 +8,7 @@
 # author Angus Leeming
 # with much advice from members of the preview-latex project:
 # David Kastrup, dak@gnu.org and
-# Jan-Åke Larsson, jalar@mai.liu.se.
+# Jan-Åke Larsson, jalar@mai.liu.se.
 
 # Full author contact details are available in file CREDITS
 
@@ -66,7 +67,11 @@ def error(message):
 def find_exe(candidates, path):
     for prog in candidates:
         for directory in path:
-            full_path = os.path.join(directory, prog)
+            if os.name == "nt":
+                full_path = os.path.join(directory, prog + ".exe")
+            else:
+                full_path = os.path.join(directory, prog)
+
             if os.access(full_path, os.X_OK):
                 return full_path