View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0003478CMakeCMakepublic2006-07-03 22:592016-06-06 16:35
ReporterDavid Leimbach 
Assigned ToBill Hoffman 
PriorityhighSeveritymajorReproducibilityalways
StatusclosedResolutionno change required 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0003478: CHECK_TYPE_SIZE doesn't work on Mac OS X
DescriptionSET(CMAKE_REQUIRED_INCLUDES sys/types.h)
CHECK_TYPE_SIZE("dev_t" DEV_T_SIZE)
SET(CMAKE_REQUIRED_INCLUDES)

and

SET(CMAKE_EXTRA_INCLUDE_FILES sys/types.h)
CHECK_TYPE_SIZE("dev_t" DEV_T_SIZE)
SET(CMAKE_EXTRA_INCLUDE_FILES)

both fail to get the size of dev_t on the latest released version on Mac OS X Tiger.

I tried getting the latest version of CheckTypeSize.cmake from CVS and including it in my project's own include directory. After this I was able to get the sizeof(int) but not dev_t.

Without this feature properly functioning I will be unable to use CMake for anything as it doesn't work on Mac OS X.

I can work around this by writing individual programs that determine the size of the 4 types I need and just doing "return sizeof(type)" but that's a huge annoyance and certainly no better than our current autoconf code.

The project I'm trying to port is "xar". The eXtensible ARchiver. See URL for details.

Thanks in advance!
TagsNo tags attached.
Attached Files

 Relationships

  Notes
(0004440)
Bill Hoffman (manager)
2006-07-11 13:18

CMAKE_EXTRA_INCLUDE_FILES works here.
Although if HAVE_SYS_TYPES_H is set to TRUE before
calling this, it will include sys/types.h automatically.
Look at CMakeFiles/CMakeError.log to see why it failed, it will also include a copy of the file that gets compiled.
(0004446)
David Leimbach (reporter)
2006-07-11 17:53

CMakeFiles/CMakeError.log made my error clear.

Thanks Bill, I think you can close this... in case I didn't just do it.

 Issue History
Date Modified Username Field Change
2016-06-06 16:35 Brad King Resolution open => no change required


Copyright © 2000 - 2018 MantisBT Team