Blob Blame History Raw
diff -up src/sage/interfaces/jmoldata.py.orig src/sage/interfaces/jmoldata.py
--- src/sage/interfaces/jmoldata.py.orig	2014-02-07 12:31:50.599827821 -0200
+++ src/sage/interfaces/jmoldata.py	2014-02-07 12:34:31.334833976 -0200
@@ -64,7 +64,7 @@ class JmolData(SageObject):
             sage_makedirs(jmolscratch)
         scratchout = os.path.join(jmolscratch,"jmolout.txt")
         jout=open(scratchout,'w')
-        testjavapath = os.path.join(SAGE_LOCAL, "share", "jmol", "testjava.sh")
+        testjavapath = os.path.join(SAGE_LOCAL, "bin", "testjava.sh")
         result = subprocess.call([testjavapath],stdout=jout)
         jout.close()
         if (result == 0):
@@ -144,8 +144,6 @@ class JmolData(SageObject):
             True
 
         """
-        # Set up paths, file names and scripts
-        jmolpath = os.path.join(SAGE_LOCAL, "share", "jmol", "JmolData.jar")
         launchscript = ""
         if (datafile_cmd!='script'):
             launchscript = "load "
@@ -157,9 +155,8 @@ class JmolData(SageObject):
         scratchout = tmp_filename(ext=".txt")
         with open(scratchout, 'w') as jout:
             # Now call the java application and write the file.
-            subprocess.call(["java", "-Xmx512m", "-Djava.awt.headless=true",
-                "-jar", jmolpath, "-iox", "-g", sizeStr,
-                "-J", launchscript, "-j", imagescript], stdout=jout, stderr=jout)
+            subprocess.call(["jmol","-n","-g",sizeStr,
+                "-J",launchscript,"-j",imagescript],stdout=jout)
         if not os.path.isfile(targetfile):
             raise RuntimeError("Jmol failed to create file %s, see %s for details"%(repr(targetfile), repr(scratchout)))
         os.unlink(scratchout)