From: Hazen B. <hba...@ma...> - 2006-09-19 03:08:21
|
On Sep 18, 2006, at 1:23 PM, Alan W. Irwin wrote: > On 2006-09-17 23:48-0400 hba...@ma... wrote: > > We need more details. What version of Java? What cmake options? > What cmake > output results? iMac ~ : java -showversion java version "1.5.0_06" Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-112) Java HotSpot(TM) Client VM (build 1.5.0_06-64, mixed mode, sharing) I've attached the CMakeCache.txt file and the output from running cmake. >> From what you have given so far, it appears you are really close >> to getting > this PLplot feature to work properly. The remaining problem seems > to be your > java command is having difficulty finding the compiled examples. > Is it > possible to try the equivalent test for our ABS? With ABS I get plplot-ABS : ./configure --disable-f77 --disable-wxwidgets [snip] checking jni.h usability... no checking jni.h presence... no checking for jni.h... no configure: WARNING: Java Native Interface include file not found, configure: WARNING: setting enable_java=no checking for javac... javac checking for jar... jar checking for swig... /usr/local/bin//swig checking for SWIG version... 1.3.28 [snip] and java is disabled. >> (2) I cannot compile with Tcl/Tk. >> >> [snip] >> Linking C shared library libplplottcltkd.dylib >> cd /Users/hbabcock/Documents/OpenSource/PLplot/plplot-CBS-1/bindings/ >> tcl && /usr/local/bin/cmake -P CMakeFiles/plplottcltkd.dir/ >> cmake_clean_target.cmake >> cd /Users/hbabcock/Documents/OpenSource/PLplot/plplot-CBS-1/bindings/ >> tcl && /usr/local/bin/cmake -E cmake_link_script CMakeFiles/ >> plplottcltkd.dir/link.txt --verbose=1 >> /usr/bin/gcc -dynamiclib -headerpad_max_install_names - >> single_module -o libplplottcltkd.9.2.0.dylib -install_name /Users/ >> hbabcock/Documents/OpenSource/PLplot/plplot-CBS-1/bindings/tcl/ >> libplplottcltkd.9.dylib "CMakeFiles/plplottcltkd.dir/tclAPI.o" >> "CMakeFiles/plplottcltkd.dir/tclMain.o" "CMakeFiles/plplottcltkd.dir/ >> __/tk/Pltk_Init.o" "CMakeFiles/plplottcltkd.dir/__/tk/plframe.o" >> "CMakeFiles/plplottcltkd.dir/__/tk/plr.o" "CMakeFiles/ >> plplottcltkd.dir/__/tk/tcpip.o" "CMakeFiles/plplottcltkd.dir/__/tk/ >> tkMain.o" -L/Users/hbabcock/Documents/OpenSource/PLplot/plplot-CBS-1/ >> bindings/tcl -L/Users/hbabcock/Documents/OpenSource/PLplot/plplot- >> CBS-1/src -L/Users/hbabcock/Documents/OpenSource/PLplot/plplot-CBS-1/ >> lib/csa -L/Users/hbabcock/Documents/OpenSource/PLplot/plplot-CBS-1/ >> lib/nn -L/usr/local/lib -ltclmatrixd -lplplotd -framework tcl - >> framework tk -lltdl -ldl -lm -lcsirocsa -lcsironn -lqhull >> ld: warning multiple definitions of symbol >> _TclSetStartupScriptFileName >> CMakeFiles/plplottcltkd.dir/tclMain.o definition of >> _TclSetStartupScriptFileName in section (__TEXT,__text) >> /System/Library/Frameworks/tcl.framework/tcl(tclMain.o) definition of >> _TclSetStartupScriptFileName >> ld: warning multiple definitions of symbol >> _TclGetStartupScriptFileName >> CMakeFiles/plplottcltkd.dir/tclMain.o definition of >> _TclGetStartupScriptFileName in section (__TEXT,__text) >> /System/Library/Frameworks/tcl.framework/tcl(tclMain.o) definition of >> _TclGetStartupScriptFileName >> ld: Undefined symbols: >> _XFlush >> _XLookupString >> /usr/bin/libtool: internal link edit command failed >> make[2]: *** [bindings/tcl/libplplottcltkd.9.2.0.dylib] Error 1 >> make[1]: *** [bindings/tcl/CMakeFiles/plplottcltkd.dir/all] Error 2 >> make: *** [all] Error 2 >> >> Perhaps these functions are missing from the OS-X version of Tcl/Tk? >> Note that ABS never even tried to compile with Tcl/Tk on OS-X. > > There are actually three issues here. > > (1) More details please (especially exact cmake invocation and > output results > from that command). cmake ../plplot-cvs (output is attached) > (2) The TclSetStartupScriptFileName warnings. This may be a real > problem. > Our version of tclMain.c in bindings/tcl was largely copied from > the generic > version that is distributed with Tcl so you would expect common > routine > names in the two versions. The real issue here is why is the > framework > pulling in the generic version so there is a clash with our version. > > Is there some way to make sure the generic version of tclMain is > ignored? > Perhaps that happens by default so we can ignore this warning? > (You may need Per's help with these questions.) > > (3) Undefined XFlush and XLookupString. I looked those up on the > Linux man > pages and on that platform they are part of XLIB (known as > /usr/X11R6/lib/libX11.so.6.2 on my Linux system). Look for a > similarly named > library on your Mac OS X system. I think that it is: /usr/X11R6/lib/libX11.6.2.dylib > These functions are used in bindings/tk/plframe.c (required by - > dev tk and > also the plserver application), drivers/xwin.c, and drivers/tkwin (as > well as other code related to the tkwin device.) > What happens if you disable tk (and plserver), and tkwin by > using -DPLD_tk OFF and DPLD_tkwin OFF? That still should leave > ENABLE_tcl > and ENABLE_tk ON (although check your cmake output to make sure), > which should be enough so that, e.g., the tcl examples work > and -dev ntk works. > > Please confirm those do work. (It's satisfying to establish a > beachhead of > things that do work, and then gradually expand it.) What is the > status of > -dev xwin? Does that work as well? If that device works (which > includes > calls to XFlush and XLookupString), then obviously its linking has > been done > better than for -dev tk. That should provide some clues as to what > is wrong > with the linking for bindings/tk/plframe.c that is made part of > libplplottcktk > for the -DPLD_tk ON case. The xwin driver works fine. >> (3) I updated the OS-X instructions on the wiki. > Thanks. I suggest you use an out-of-source build (cmake ../ > plplot_cvs) as > an example rather than your current in-source build (cmake .) > example. Also, I didn't know that you could do that. I've just been making a copy of the source tree. I will update the instructions. > I suggest you explain a bit more about exactly which environment > variable(s) > you set to help cmake find swig and tcl/tk. For example, I don't > think > SWIG_DIR is relevant. Instead, I believe you must set one of the > environment variables (e.g., CMAKE_INCLUDE_PATH) mentioned under > the generic > Unix instructions. Setting SWIG_DIR using ccmake will enable cmake to find swig which will in turn find python. >> Should we add a link >> to the wiki from the PLplot home page? > > Yes, please! Done. -Hazen |