- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi~
I am trying to add a new function into the class task.
I have add the following code right down the set_affinity() in the class task in task.h:
void set_affinity_priority(int id);
Then I add the following code in the task.cpp:
void task::set_affinity_priority(int id){
int i;
}
After that, I typed make to compile the tbb library succefully.
However, when I try to compile a small example which call the set_affinity_priority() function.
I got the following error message:
/tmp/cc6wmAFt.o: In function `StartTask::StartTask(int, int, int)':
main_v3.cpp:(.text._ZN9StartTaskC1Eiii[StartTask::StartTask(int, int, int)]+0x60): undefined reference to `tbb::task::set_affinity_priority(int)'
collect2: ld returned 1 exit status
make: *** [ALL] Error 1
main_v3.cpp:(.text._ZN9StartTaskC1Eiii[StartTask::StartTask(int, int, int)]+0x60): undefined reference to `tbb::task::set_affinity_priority(int)'
collect2: ld returned 1 exit status
make: *** [ALL] Error 1
Could anybody give me some help?
Dennis
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Havea look at those src/tbb/*.def files... I found them very frightening myself (for manual editing, anyway), but you'll need to deal with them if you want to get something into a dynamic library.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quoting - Raf Schietekat
Havea look at those src/tbb/*.def files... I found them very frightening myself (for manual editing, anyway), but you'll need to deal with them if you want to get something into a dynamic library.
I found the def files already.
What should I add the corresponding entry into this file?
I have tried to google something useful about this stuff but finding nothing.
Could anyone give me a hint?
Dennis
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