<div dir="ltr">Hi David,<div><br></div><div>I have the latter, but not the first:</div><div>







<p class="">jmht$ ls /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/Tk.framework/PrivateHeaders</p>
<p class="">default.h<span class="">    </span><span class="">    </span>tkInt.h<span class="">     </span><span class="">    </span><span class="">    </span>tkIntPlatDecls.h<span class="">    </span>tkMacOSXInt.h<span class="">       </span><span class="">    </span>tkPort.h<span class="">    </span><span class="">    </span>ttkTheme.h</p>
<p class="">tkFont.h<span class="">     </span><span class="">    </span>tkIntDecls.h<span class="">        </span><span class="">    </span>tkMacOSXDefault.h<span class="">   </span>tkMacOSXPort.h<span class="">      </span><span class="">    </span>ttkDecls.h</p>
<p class="">jmht$ ls /System/Library/Frameworks/Tk.framework/PrivateHeaders</p>
<p class="">ls: /System/Library/Frameworks/Tk.framework/PrivateHeaders: No such file or directory</p><p class="">In fact, there aren't any header files at all in /System/Library/Frameworks/Tk.framework</p><p class="">I'm running Xcode 5.1.1 (5B1008) and also have the command-line tools installed.</p><p class="">Best wishes,</p><p class="">Jens</p></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 17 September 2014 13:38, David Gobbi <span dir="ltr"><<a href="mailto:david.gobbi@gmail.com" target="_blank">david.gobbi@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Jens,<br>
<br>
On my machine (which is also 10.9.4), my cache has the following:<br>
<br>
TK_INTERNAL_PATH:PATH=/System/Library/Frameworks/Tk.framework/PrivateHeaders<br>
<br>
An "ls -l" of the framework directory shows this, where Current -> 8.5<br>
<br>
PrivateHeaders -> Versions/Current/PrivateHeaders<br>
<br>
The above link should have been created by Xcode.<br>
<br>
The TK_INTERNAL_PATH variable is set in Rendering/Tk/CMakeLists.txt,<br>
and it definitely looks in PrivateHeaders before looking anywhere else.  Does<br>
the PrivateHeaders directory exist in your framework directory?  My machine<br>
has this:<br>
<br>
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/Tk.framework/PrivateHeaders<br>
<br>
I have Xcode 5.1.1, and I also have the Xcode command-line tools installed.<br>
<span class="HOEnZb"><font color="#888888"><br>
 - David<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
On Wed, Sep 17, 2014 at 4:06 AM, Jens <<a href="mailto:linucks42@gmail.com">linucks42@gmail.com</a>> wrote:<br>
> Hi David,<br>
><br>
> I'm still struggling to get this build to work. I pointed the CMakeCache.txt<br>
> at the correct header and library directories (for tk 8.5), but it persisted<br>
> in setting:<br>
><br>
> TK_INTERNAL_PATH:PATH=/opt/VTK-6.1.0/ThirdParty/TclTk/internals/tk8.6<br>
><br>
> i.e. for version 8.6. In the end I manually set TK_INTERNAL_PATH so that it<br>
> pointed at tk 8.5.<br>
><br>
> The settings in my CMakeCache.txt are therefore:<br>
><br>
> //Path to a file.<br>
><br>
> TCL_INCLUDE_PATH:PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tcl.framework/Headers<br>
><br>
> //Path to a library.<br>
><br>
> TCL_LIBRARY:FILEPATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tcl.framework<br>
><br>
> //Path to a program.<br>
><br>
> TCL_TCLSH:FILEPATH=/usr/bin/tclsh<br>
><br>
> //Path to a file.<br>
><br>
> TK_INCLUDE_PATH:PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tk.framework/Headers<br>
><br>
> //The path to the Tk internal headers (tkMacOSXDefault.h).<br>
><br>
> TK_INTERNAL_PATH:PATH=/opt/VTK-6.1.0/ThirdParty/TclTk/internals/tk8.5<br>
><br>
> //Path to a library.<br>
><br>
> TK_LIBRARY:FILEPATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tk.framework<br>
><br>
><br>
> and just for reference, a long-listing of the tk.framework/Versions<br>
> directory shows:<br>
><br>
> Current -> 8.5<br>
><br>
><br>
> i.e. I'm pretty certain I should be using 8.5.<br>
><br>
><br>
> If I now run the make, it dies as follows:<br>
><br>
><br>
> [ 59%] Building CXX object<br>
> Rendering/Tk/CMakeFiles/vtkRenderingPythonTkWidgets.dir/vtkCocoaTkUtilities.mm.o<br>
><br>
> cd /opt/VTK-6.1.0/build/Rendering/Tk && /usr/bin/c++   -DVTK_IN_VTK<br>
> -DvtkRenderingPythonTkWidgets_EXPORTS -g -isysroot<br>
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk<br>
> -fPIC -I/opt/VTK-6.1.0/build/Interaction/Image<br>
> -I/opt/VTK-6.1.0/Interaction/Image -I/opt/VTK-6.1.0/build/Imaging/Color<br>
> -I/opt/VTK-6.1.0/Imaging/Color -I/opt/VTK-6.1.0/build/Imaging/Core<br>
> -I/opt/VTK-6.1.0/Imaging/Core -I/opt/VTK-6.1.0/build/Common/ExecutionModel<br>
> -I/opt/VTK-6.1.0/Common/ExecutionModel<br>
> -I/opt/VTK-6.1.0/build/Common/DataModel -I/opt/VTK-6.1.0/Common/DataModel<br>
> -I/opt/VTK-6.1.0/build/Common/Math -I/opt/VTK-6.1.0/Common/Math<br>
> -I/opt/VTK-6.1.0/build/Common/Core -I/opt/VTK-6.1.0/Common/Core<br>
> -I/opt/VTK-6.1.0/build/Utilities/KWSys -I/opt/VTK-6.1.0/Utilities/KWSys<br>
> -I/opt/VTK-6.1.0/build/Common/Misc -I/opt/VTK-6.1.0/Common/Misc<br>
> -I/opt/VTK-6.1.0/build/Common/System -I/opt/VTK-6.1.0/Common/System<br>
> -I/opt/VTK-6.1.0/build/Common/Transforms -I/opt/VTK-6.1.0/Common/Transforms<br>
> -I/opt/VTK-6.1.0/build/Interaction/Style -I/opt/VTK-6.1.0/Interaction/Style<br>
> -I/opt/VTK-6.1.0/build/Filters/Extraction<br>
> -I/opt/VTK-6.1.0/Filters/Extraction -I/opt/VTK-6.1.0/build/Filters/Core<br>
> -I/opt/VTK-6.1.0/Filters/Core -I/opt/VTK-6.1.0/build/Filters/General<br>
> -I/opt/VTK-6.1.0/Filters/General<br>
> -I/opt/VTK-6.1.0/build/Common/ComputationalGeometry<br>
> -I/opt/VTK-6.1.0/Common/ComputationalGeometry<br>
> -I/opt/VTK-6.1.0/build/Filters/Statistics<br>
> -I/opt/VTK-6.1.0/Filters/Statistics -I/opt/VTK-6.1.0/build/Imaging/Fourier<br>
> -I/opt/VTK-6.1.0/Imaging/Fourier -I/opt/VTK-6.1.0/build/ThirdParty/alglib<br>
> -I/opt/VTK-6.1.0/ThirdParty/alglib -I/opt/VTK-6.1.0/build/Filters/Sources<br>
> -I/opt/VTK-6.1.0/Filters/Sources -I/opt/VTK-6.1.0/build/Rendering/Core<br>
> -I/opt/VTK-6.1.0/Rendering/Core -I/opt/VTK-6.1.0/build/Filters/Geometry<br>
> -I/opt/VTK-6.1.0/Filters/Geometry -I/opt/VTK-6.1.0/build/Interaction/Widgets<br>
> -I/opt/VTK-6.1.0/Interaction/Widgets -I/opt/VTK-6.1.0/build/Filters/Hybrid<br>
> -I/opt/VTK-6.1.0/Filters/Hybrid -I/opt/VTK-6.1.0/build/Imaging/Sources<br>
> -I/opt/VTK-6.1.0/Imaging/Sources -I/opt/VTK-6.1.0/build/Filters/Modeling<br>
> -I/opt/VTK-6.1.0/Filters/Modeling -I/opt/VTK-6.1.0/build/Imaging/General<br>
> -I/opt/VTK-6.1.0/Imaging/General -I/opt/VTK-6.1.0/build/Imaging/Hybrid<br>
> -I/opt/VTK-6.1.0/Imaging/Hybrid -I/opt/VTK-6.1.0/build/IO/Image<br>
> -I/opt/VTK-6.1.0/IO/Image -I/opt/VTK-6.1.0/build/Utilities/DICOMParser<br>
> -I/opt/VTK-6.1.0/Utilities/DICOMParser -I/opt/VTK-6.1.0/build/IO/Core<br>
> -I/opt/VTK-6.1.0/IO/Core -I/opt/VTK-6.1.0/build/ThirdParty/zlib<br>
> -I/opt/VTK-6.1.0/ThirdParty/zlib<br>
> -I/opt/VTK-6.1.0/build/Utilities/MetaIO/vtkmetaio<br>
> -I/opt/VTK-6.1.0/build/Utilities/MetaIO -I/opt/VTK-6.1.0/Utilities/MetaIO<br>
> -I/opt/VTK-6.1.0/build/ThirdParty/jpeg -I/opt/VTK-6.1.0/ThirdParty/jpeg<br>
> -I/opt/VTK-6.1.0/build/ThirdParty/png -I/opt/VTK-6.1.0/ThirdParty/png<br>
> -I/opt/VTK-6.1.0/build/ThirdParty/tiff -I/opt/VTK-6.1.0/ThirdParty/tiff<br>
> -I/opt/VTK-6.1.0/build/Rendering/Annotation<br>
> -I/opt/VTK-6.1.0/Rendering/Annotation<br>
> -I/opt/VTK-6.1.0/build/Rendering/FreeType<br>
> -I/opt/VTK-6.1.0/Rendering/FreeType<br>
> -I/opt/VTK-6.1.0/build/ThirdParty/freetype<br>
> -I/opt/VTK-6.1.0/ThirdParty/freetype -I/opt/VTK-6.1.0/ThirdParty/ftgl/src<br>
> -I/opt/VTK-6.1.0/build/ThirdParty/ftgl -I/opt/VTK-6.1.0/ThirdParty/ftgl<br>
> -I/opt/VTK-6.1.0/build/Rendering/Volume -I/opt/VTK-6.1.0/Rendering/Volume<br>
> -F/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks<br>
> -I/opt/VTK-6.1.0/build/Rendering/OpenGL -I/opt/VTK-6.1.0/Rendering/OpenGL<br>
> -I/opt/VTK-6.1.0/build/Utilities/ParseOGLExt<br>
> -I/opt/VTK-6.1.0/Utilities/ParseOGLExt<br>
> -I/opt/VTK-6.1.0/build/Utilities/EncodeString<br>
> -I/opt/VTK-6.1.0/Utilities/EncodeString<br>
> -I/opt/VTK-6.1.0/build/ThirdParty/TclTk -I/opt/VTK-6.1.0/ThirdParty/TclTk<br>
> -I/opt/VTK-6.1.0/build/Rendering/Tk -I/opt/VTK-6.1.0/Rendering/Tk<br>
> -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tk.framework/Headers<br>
> -I/opt/VTK-6.1.0/ThirdParty/TclTk/internals/tk8.5<br>
> -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tcl.framework/Headers<br>
> -I/opt/VTK-6.1.0/Wrapping/Tcl -I/opt/VTK-6.1.0/build/Wrapping/Tcl    -o<br>
> CMakeFiles/vtkRenderingPythonTkWidgets.dir/vtkCocoaTkUtilities.mm.o -c<br>
> /opt/VTK-6.1.0/Rendering/Tk/vtkCocoaTkUtilities.mm<br>
><br>
> /opt/VTK-6.1.0/Rendering/Tk/vtkCocoaTkUtilities.mm:57:28: error: no member<br>
> named 'view' in 'TkWindowPrivate'<br>
><br>
>   NSView *result = macWin->view;<br>
><br>
>                    ~~~~~~  ^<br>
><br>
> 1 error generated.<br>
><br>
> make[2]: ***<br>
> [Rendering/Tk/CMakeFiles/vtkRenderingPythonTkWidgets.dir/vtkCocoaTkUtilities.mm.o]<br>
> Error 1<br>
><br>
> make[1]: *** [Rendering/Tk/CMakeFiles/vtkRenderingPythonTkWidgets.dir/all]<br>
> Error 2<br>
><br>
> make: *** [all] Error 2<br>
><br>
> If I get clang to print out the tk.h and tcl.h header files, it shows the<br>
> following:<br>
><br>
><br>
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tcl.framework/Headers/tcl.h<br>
><br>
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tk.framework/Headers/tk.h<br>
><br>
><br>
> Do you have any suggestions as to what might be going wrong here?<br>
><br>
><br>
> Best wishes,<br>
><br>
><br>
> Jens<br>
><br>
><br>
> On 15 September 2014 13:27, David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>> wrote:<br>
>><br>
>> Hi Jens,<br>
>><br>
>> I looked through FindTCL.cmake, and it looks like it tries to match<br>
>> the header to the library.  Since it tries but fails, this could be<br>
>> considered a bug.<br>
>><br>
>>  - David<br>
>><br>
>><br>
>> On Mon, Sep 15, 2014 at 3:21 AM, Jens <<a href="mailto:linucks42@gmail.com">linucks42@gmail.com</a>> wrote:<br>
>> > Hi David,<br>
>> ><br>
>> > Many thanks for the quick and very helpful reply. As you suspected there<br>
>> > was<br>
>> > a mismatch between the tcl/tk headers. The headers were coming from:<br>
>> ><br>
>> > /usr/local/include<br>
>> ><br>
>> > and the libraries from:<br>
>> ><br>
>> ><br>
>> > /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/tcl.framework<br>
>> ><br>
>> > I've pointed both at the /Applications/... directories and the build has<br>
>> > now<br>
>> > got beyond that point, so thanks again for your help.<br>
>> ><br>
>> > Would that be considered a bug in cmake, or just bad luck on my part?<br>
>> ><br>
>> > I hadn't knowingly installed anything tk/tcl related on my machine (it's<br>
>> > a<br>
>> > new macbook air and I've not loaded much software at all onto it), so<br>
>> > I've<br>
>> > no idea where the stuff in /usr/local came from.<br>
>> ><br>
>> > However, if cmake had found the include files in /usr/local, shouldn't<br>
>> > it<br>
>> > also have used the related libraries in /usr/local?<br>
>> ><br>
>> > Best wishes,<br>
>> ><br>
>> > Jens<br>
>> ><br>
>> ><br>
>> ><br>
>> > On 14 September 2014 22:34, David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>> wrote:<br>
>> >><br>
>> >> Hi Jens,<br>
>> >><br>
>> >> If the VTK build is looking for a function called Tcl_GetErrorLine(),<br>
>> >> that means that it is using a "tcl.h" for Tcl 8.6.  This function<br>
>> >> doesn't<br>
>> >> exist in Tcl 8.5 or earlier versions of Tcl.<br>
>> >><br>
>> >> My guess is that you have installed Tcl 8.6 on your system, and<br>
>> >> CMake has found the Tcl 8.6 headers, but is linking to the Tcl 8.5<br>
>> >> libraries in the System folder.<br>
>> >><br>
>> >> Make sure that your CMakeCache.txt use the same framework for<br>
>> >> all the Tcl variables:<br>
>> >><br>
>> >> TCL_INCLUDE_PATH:PATH=/System/Library/Frameworks/Tcl.framework/Headers<br>
>> >> TCL_LIBRARY:FILEPATH=/System/Library/Frameworks/Tcl.framework<br>
>> >> TCL_TCLSH:FILEPATH=/usr/bin/tclsh<br>
>> >> TK_INCLUDE_PATH:PATH=/System/Library/Frameworks/Tk.framework/Headers<br>
>> >><br>
>> >><br>
>> >> TK_INTERNAL_PATH:PATH=/System/Library/Frameworks/Tk.framework/PrivateHeaders<br>
>> >> TK_LIBRARY:FILEPATH=/System/Library/Frameworks/Tk.framework<br>
>> >><br>
>> >> If you still have problems after setting your cache as shown above,<br>
>> >> then<br>
>> >> you might have to find and remove the tcl.h file that is causing the<br>
>> >> error.<br>
>> >><br>
>> >>  - David<br>
>> >><br>
>> >><br>
>> >> On Sun, Sep 14, 2014 at 2:57 PM, Jens <<a href="mailto:linucks42@gmail.com">linucks42@gmail.com</a>> wrote:<br>
>> >> > Hi,<br>
>> >> ><br>
>> >> > I'm trying to build VTK 6.1.1 with the Tk and Python bindings on OSX<br>
>> >> > 10.9.4,<br>
>> >> > with cmake 3.0.2 and At 5.3.1.<br>
>> >> ><br>
>> >> > The build is failing with:<br>
>> >> ><br>
>> >> > /usr/bin/c++    -g -isysroot<br>
>> >> ><br>
>> >> ><br>
>> >> > /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk<br>
>> >> > -dynamiclib -Wl,-headerpad_max_install_names<br>
>> >> > -compatibility_version<br>
>> >> > 1.0.0<br>
>> >> > -current_version 1.0.0 -o ../../lib/libvtkCommonCoreTCL-6.1.1.dylib<br>
>> >> > -install_name<br>
>> >> > /opt/VTK-6.1.0/build/lib/libvtkCommonCoreTCL-6.1.1.dylib<br>
>> >> ><br>
>> >> > ...snip...<br>
>> >> ><br>
>> >> > CMakeFiles/vtkCommonCoreTCL.dir/vtkTypeFloat64ArrayTcl.cxx.o<br>
>> >> > CMakeFiles/vtkCommonCoreTCL.dir/vtkCommonCoreTCLInit.cxx.o<br>
>> >> > CMakeFiles/vtkCommonCoreTCL.dir/__/__/Wrapping/Tcl/vtkTclUtil.cxx.o<br>
>> >> > ../../lib/libvtkCommonCore-6.1.1.dylib<br>
>> >> > ../../lib/libvtksys-6.1.1.dylib<br>
>> >> > -framework tcl -lm<br>
>> >> ><br>
>> >> > Undefined symbols for architecture x86_64:<br>
>> >> ><br>
>> >> >   "_Tcl_GetErrorLine", referenced from:<br>
>> >> ><br>
>> >> >       vtkTclVoidFunc(void*) in vtkTclUtil.cxx.o<br>
>> >> ><br>
>> >> >       vtkTclCommand::Execute(vtkObject*, unsigned long, void*) in<br>
>> >> > vtkTclUtil.cxx.o<br>
>> >> ><br>
>> >> > ld: symbol(s) not found for architecture x86_64<br>
>> >> ><br>
>> >> > clang: error: linker command failed with exit code 1 (use -v to see<br>
>> >> > invocation)<br>
>> >> ><br>
>> >> > make[2]: *** [lib/libvtkCommonCoreTCL-6.1.1.dylib] Error 1<br>
>> >> ><br>
>> >> > make[1]: *** [Common/Core/CMakeFiles/vtkCommonCoreTCL.dir/all] Error<br>
>> >> > 2<br>
>> >> ><br>
>> >> ><br>
>> >> > Can anyone suggest a workaround?<br>
>> >> ><br>
>> >> ><br>
>> >> > Best wishes,<br>
>> >> ><br>
>> >> ><br>
>> >> > Jens<br>
>> ><br>
>> ><br>
><br>
><br>
</div></div></blockquote></div><br></div>