On 10/02/2015 01:51 AM, Damian Rouson wrote:
All,
Could someone advise me on building CMake from source on OS X 10.10.5
(Yosemite)? At the bottom of this email is the tail of the output from the
following build script:
g++
-I/Users/rouson/Code/sourceryinstitute/AdHoc/src/cmake/bug-xxxx/cmake-3.3.0/Bootstrap.cmk
-I/Users/rouson/Code/sourceryinstitute/AdHoc/src/cmake/bug-xxxx/cmake-3.3.0/Source
-I/Users/rouson/Code/sourceryinstitute/AdHoc/src/cmake/bug-xxxx/cmake-3.3.0/Bootstrap.cmk
-c
/Users/rouson/Code/sourceryinstitute/AdHoc/src/cmake/bug-xxxx/cmake-3.3.0/Source/cmBootstrapCommands1.cxx
-o cmBootstrapCommands1.o
In file included from /usr/include/dispatch/dispatch.h:51:0,
from
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFStream.h:15,
from
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFPropertyList.h:13,
from
/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:55,
from
/Users/rouson/Code/sourceryinstitute/AdHoc/src/cmake/bug-xxxx/cmake-3.3.0/Source/cmFindProgramCommand.cxx:16,
from
/Users/rouson/Code/sourceryinstitute/AdHoc/src/cmake/bug-xxxx/cmake-3.3.0/Source/cmBootstrapCommands1.cxx:52:
/usr/include/dispatch/object.h:143:15: error: expected unqualified-id before
'^' token
typedef void (^dispatch_block_t)(void);
^
/usr/include/dispatch/object.h:143:15: error: expected ')' before '^' token
/usr/include/dispatch/object.h:362:3: error: 'dispatch_block_t' has not been
declared
dispatch_block_t notification_block);
^
I found
http://hamelot.co.uk/programming/osx-gcc-dispatch_block_t-has-not-been-declared-invalid-typedef/
which says this is due to that bit of syntax (I've never seen that
either) within /usr/include/dispatch/object.h being understood by clang
but not by gcc.
Other sources [1] seem to say that this bit of syntax is supported by
gcc as it used to be provided by Xcode.
I am guessing you are also using gcc without apple provided patches
(e.g. homebrew)?
Nils
[1]
https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/Blocks/Articles/00_Introduction.html
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Kitware offers various services to support the CMake community. For more
information on each offering, please visit:
CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake