|
Notes |
|
|
(0012122)
|
|
Brad King
|
|
2008-05-27 13:27
|
|
I just came across the same bug (for the same reason...64-bit python on windows). Your analysis of the registry node was my thought also.
I think the correct fix is for CMake to search the 32-bit registry node or the 64-bit registry node depending on the *target* platform for which the project will be built. Whether CMake itself was built 32-bit or 64-bit does not matter. |
|
|
|
(0012123)
|
|
Brad King
|
|
2008-05-27 13:39
|
|
|
|
|
(0012124)
|
|
Brad King
|
|
2008-05-27 13:45
|
|
|
|
|
(0012125)
|
|
Brad King
|
|
2008-05-27 14:47
|
|
I've updated the internal API we use to access the registry to support selection of 32-bit and 64-bit views:
/cvsroot/CMake/CMake/Source/cmSystemTools.cxx,v <-- Source/cmSystemTools.cxx
new revision: 1.379; previous revision: 1.378
/cvsroot/CMake/CMake/Source/cmSystemTools.h,v <-- Source/cmSystemTools.h
new revision: 1.154; previous revision: 1.153
/cvsroot/CMake/CMake/Source/kwsys/SystemTools.cxx,v <-- Source/kwsys/SystemTools.cxx
new revision: 1.226; previous revision: 1.225
/cvsroot/CMake/CMake/Source/kwsys/SystemTools.hxx.in,v <-- Source/kwsys/SystemTools.hxx.in
new revision: 1.74; previous revision: 1.73 |
|
|
|
(0012126)
|
|
Brad King
|
|
2008-05-27 14:48
|
|
I've updated the FIND* commands to use the view of the target platform when reading registry values:
/cvsroot/CMake/CMake/Source/cmFindBase.cxx,v <-- Source/cmFindBase.cxx
new revision: 1.39; previous revision: 1.38 |
|
|
|
(0012127)
|
|
Brad King
|
|
2008-05-27 14:49
|
|
|
I just tried this, and it works. A 32-bit or 64-bit CMake binary can now find 64-bit python when building a 64-bit project. We'll include this in the next 2.6 release. |
|
|
|
(0012129)
|
|
Peter Johnson
|
|
2008-05-27 16:26
|
|
|
Unfortunately this doesn't completely fix the issue for me. In my case, I'm using Python to generate source code (e.g. running a Python script as part of the build process with ADD_CUSTOM_COMMAND), so it shouldn't matter what the target platform is. E.g. even if I'm building a Win32 target, using the 64-bit Python is fine. Is there a reasonable way in which this can be supported? I think this falls under build vs. target platform for FIND*? |
|
|
|
(0012130)
|
|
Brad King
|
|
2008-05-27 16:32
|
|
For finding libraries we have to use the target platform.
For finding executables I guess we can support finding them for either the host or target platform. |
|
|
|
(0012131)
|
|
Brad King
|
|
2008-05-27 16:52
|
|
Okay, now find_program() will expand registry values to both the 32-bit and the 64-bit values. The target platform is checked first just in case. Now I can find a 64-bit python.exe when building a 32-bit project.
/cvsroot/CMake/CMake/Source/cmFindBase.cxx,v <-- Source/cmFindBase.cxx
new revision: 1.40; previous revision: 1.39 |
|