MantisBT - CMake | |||||
View Issue Details | |||||
ID | Project | Category | View Status | Date Submitted | Last Update |
0006051 | CMake | CMake | public | 2007-11-14 12:22 | 2007-11-16 15:40 |
Reporter | Sean McBride | ||||
Assigned To | |||||
Priority | normal | Severity | block | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Platform | Mac OS X | OS | Mac OS X | OS Version | 10.5 |
Product Version | |||||
Target Version | Fixed in Version | ||||
Summary | 0006051: CMake cannot build itself as 64 bit on a 64 bit Mac OS X 10.5 machine, incorrect va_list copying performed | ||||
Description | CMake (from today's CVS) it unable to build itself with "CMAKE_OSX_ARCHITECTURES" as 'x86_64', it says: /Users/sean/kitware/CMake/Utilities/cmxmlrpc/xmlrpc_data.c: In function ‘xmlrpc_build_value_va’: /Users/sean/kitware/CMake/Utilities/cmxmlrpc/xmlrpc_data.c:938: error: incompatible types in assignment /Users/sean/kitware/CMake/Utilities/cmxmlrpc/xmlrpc_data.c: In function ‘xmlrpc_parse_value_va’: /Users/sean/kitware/CMake/Utilities/cmxmlrpc/xmlrpc_data.c:1282: error: incompatible types in assignment make[2]: *** [Utilities/cmxmlrpc/CMakeFiles/cmXMLRPC.dir/xmlrpc_data.o] Error 1 make[1]: *** [Utilities/cmxmlrpc/CMakeFiles/cmXMLRPC.dir/all] Error 2 make: *** [all] Error 2 This looks like a legitimate error. The 'va_list' type is opaque and the VA_LIST_COPY macro makes invalid assumptions. Currently, it reads: /* Borrowed from Python 1.5.2. ** Python copies its va_list objects before using them in certain ** tricky fashions. We don't why Python does this, but since we're ** abusing our va_list objects in a similar fashion, we'll copy them ** too. */ #if VA_LIST_IS_ARRAY #define VA_LIST_COPY(dest,src) memcpy((dest), (src), sizeof(va_list)) #else #define VA_LIST_COPY(dest,src) ((dest) = (src)) #endif I changed it to: #define VA_LIST_COPY(dest,src) va_copy((dest), (src)) This fixes the problem, and seems like the best solution. However, va_copy() was added in C99, and maybe you need to support older compilers too? I suggest reviewing the need for VA_LIST_COPY at all, especially in light of the comment just above it. :) | ||||
Steps To Reproduce | |||||
Additional Information | |||||
Tags | No tags attached. | ||||
Relationships | |||||
Attached Files | ![]() https://public.kitware.com/Bug/file/1229/CMakeVAListPatch.txt | ||||
Issue History | |||||
Date Modified | Username | Field | Change | ||
2007-11-14 12:22 | Sean McBride | New Issue | |||
2007-11-14 13:58 | Bill Hoffman | Note Added: 0009673 | |||
2007-11-14 15:12 | Sean McBride | File Added: CMakeVAListPatch.txt | |||
2007-11-14 15:12 | Sean McBride | Note Added: 0009675 | |||
2007-11-15 07:47 | Bill Hoffman | Note Added: 0009680 | |||
2007-11-15 11:47 | Sean McBride | Note Added: 0009687 | |||
2007-11-15 14:21 | Bill Hoffman | Note Added: 0009688 | |||
2007-11-15 14:59 | Sean McBride | Note Added: 0009689 | |||
2007-11-16 14:07 | Bill Hoffman | Note Added: 0009695 | |||
2007-11-16 14:50 | Sean McBride | Note Added: 0009696 | |||
2007-11-16 15:40 | Bill Hoffman | Status | new => closed | ||
2007-11-16 15:40 | Bill Hoffman | Resolution | open => fixed | ||
2007-11-16 15:40 | Bill Hoffman | Category | CMakeSetup => CMake |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|