- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the past I managed to compile Intel Threading Building Blocks on Linux using the GNU C/C++ compiler or the Intel C/C++ compiler. TBB also support Sun Studio compilers on Solaris. Today I tried to compile TBB on a Linux box running Ubuntu 9.10 (x86) using the Sun Studio 12.1 compilers, unfortunately without success.
This combination of OS and compiler is not supported by TBB 2.2. Thus, I copied the file SunOS.suncc.inc to linux.suncc.inc and started the compilation of TBB by "OS=linux compiler=suncc make". However, I got several errors. My approach is probably to naive.
Has anybody managed to compile TBB on Linux using Sun Studio compilers?
This combination of OS and compiler is not supported by TBB 2.2. Thus, I copied the file SunOS.suncc.inc to linux.suncc.inc and started the compilation of TBB by "OS=linux compiler=suncc make". However, I got several errors. My approach is probably to naive.
Has anybody managed to compile TBB on Linux using Sun Studio compilers?
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Your approach is basically right. Please check whether some OS-specific stuff sneaked into compiler-specific "linux.suncc.inc" or vice-versa, compiler-spicifics come into linux.inc. E.g. I found "EXPORT_KEY" definition in linux.inc which should not be there by design. So, please try to move it into compiler files instead.
If you still are not able to compile with suncc, could you share the output with the errors?
If you still are not able to compile with suncc, could you share the output with the errors?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Finally, I managed to compile TBB on Linux using the Sun compiler. However, just editing "linux.suncc.inc" was not enough. The main problem is that TBB includes several Linux system headers that declare different sets of functions and macros depending on the compiler. For example syscall and pthread_getattr_np cannot be found if the Sun compiler is used. Thus, I had to apply several work-arounds. E.g. in scheduler.cpp I had to add
[cpp]extern "C" int pthread_getattr_np(pthread_t thread, pthread_attr_t *attr); [/cpp]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We would be glad to accept your work as a contribution, and see whether we can incorporate it into the main source trunk, should anybody else be interested in it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Heiko,
I also want to compile TBB on linux with Oracle Studio 12.2. Could you plese tell me in detail about the modifications you made?
Thanks,
Zhongze
I also want to compile TBB on linux with Oracle Studio 12.2. Could you plese tell me in detail about the modifications you made?
Thanks,
Zhongze
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