- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I attempted to build the 4.4 U3 release for the upcoming Fedora 24 with a gcc 6 prerelease. The build failed as follows:
In file included from /usr/include/c++/6.0.0/memory:62:0, from ../../include/tbb/tbb_stddef.h:421, from ../../src/tbb/itt_notify.h:24, from ../../src/tbb/itt_notify.cpp:67: /usr/include/c++/6.0.0/bits/stl_algobase.h:243:56: error: macro "min" passed 3 arguments, but takes just 2 min(const _Tp& __a, const _Tp& __b, _Compare __comp) ^ In file included from ../../src/tbb/itt_notify.cpp:47:0: /usr/include/c++/6.0.0/bits/stl_algobase.h:195:5: error: expected unqualified-id before 'const' min(const _Tp& __a, const _Tp& __b)
[many more errors snipped]
This appears to be due to the following change to src/tbb/tools_api/ittnotify_static.c from 4.4 U2 to 4.4 U3:
@@ -806,12 +777,13 @@ static const char* __itt_get_lib_name(vo return lib_name; } -/* Avoid clashes with std::min */ -#define __itt_min(a,b) (a) < (b) ? (a) : (b) +#ifndef min +#define min(a,b) (a) < (b) ? (a) : (b) +#endif /* min */ static __itt_group_id __itt_get_groups(void) {
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Adding #undef min to the end of src/tbb/tools_api/ittnotify_static.c fixes the build.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I hope this is addressed in Development Release tbb44_20160316oss_src.tgz
https://www.threadingbuildingblocks.org/download#development-releases
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, that fixes the problem. Thank you, Alexandr.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page