Intel® oneAPI Threading Building Blocks
Ask questions and share information about adding parallelism to your applications when using this threading library.

Unable to build sample examples

Abhay_Hegde
Beginner
1,125 Views

Hi everyone..

I am trying to build the sample code from here http://software.intel.com/en-us/articles/tbb-game-technology-demo-download/

I have followed the instruction given in the Readme. When i build the solution ..it gives me the following error.

[bash]1>------ Build started: Project: Common, Configuration: Release Win32 ------
1>Compiling...
1>common.cpp
1>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
1>Build log was saved at "file://C:\code\Release\BuildLog.htm"
1>Common - 1 error(s), 0 warning(s)
2>------ Build started: Project: Sample8, Configuration: Release Win32 ------
3>------ Build started: Project: Sample7, Configuration: Release Win32 ------
4>------ Build started: Project: Sample6, Configuration: Release Win32 ------
3>Sample7 : warning PRJ0009 : Build log could not be opened for writing.
3>Make sure that the file is not open by another process and is not write-protected.
5>------ Build started: Project: Sample5, Configuration: Release Win32 ------
4>Sample6 : warning PRJ0009 : Build log could not be opened for writing.
4>Make sure that the file is not open by another process and is not write-protected.
5>Sample5 : warning PRJ0009 : Build log could not be opened for writing.
5>Make sure that the file is not open by another process and is not write-protected.
2>Compiling...
3>Compiling...
4>Compiling...
5>Compiling...
2>sample8.cpp
3>sample7.cpp
4>sample6.cpp
5>sample5.cpp
5>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
2>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
4>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
3>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
5>Build log was saved at "file://c:\code\Release\BuildLog.htm"
2>Build log was saved at "file://c:\code\Release\BuildLog.htm"
4>Build log was saved at "file://c:\code\Release\BuildLog.htm"
5>Sample5 - 1 error(s), 1 warning(s)
2>Sample8 - 1 error(s), 0 warning(s)
3>Build log was saved at "file://c:\code\Release\BuildLog.htm"
3>Sample7 - 1 error(s), 1 warning(s)
4>Sample6 - 1 error(s), 1 warning(s)
6>------ Build started: Project: Sample4, Configuration: Release Win32 ------
7>------ Build started: Project: Sample3, Configuration: Release Win32 ------
7>Sample3 : warning PRJ0009 : Build log could not be opened for writing.
7>Make sure that the file is not open by another process and is not write-protected.
6>Compiling...
7>Compiling...
6>sample4.cpp
7>sample3.cpp
8>------ Build started: Project: Sample2, Configuration: Release Win32 ------
8>Sample2 : warning PRJ0009 : Build log could not be opened for writing.
8>Make sure that the file is not open by another process and is not write-protected.
9>------ Build started: Project: Sample1, Configuration: Release Win32 ------
9>Sample1 : warning PRJ0009 : Build log could not be opened for writing.
9>Make sure that the file is not open by another process and is not write-protected.
8>Compiling...
9>Compiling...
6>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
7>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
7>Build log was saved at "file://c:\code\Release\BuildLog.htm"
6>Build log was saved at "file://c:\code\Release\BuildLog.htm"
7>Sample3 - 1 error(s), 1 warning(s)
6>Sample4 - 1 error(s), 0 warning(s)
8>sample2.cpp
9>sample1.cpp
8>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
9>c:\code\common.h(16) : fatal error C1083: Cannot open include file: 'tbb/tick_count.h': No such file or directory
9>Build log was saved at "file://c:\code\Release\BuildLog.htm"
9>Sample1 - 1 error(s), 1 warning(s)
8>Build log was saved at "file://c:\code\Release\BuildLog.htm"
8>Sample2 - 1 error(s), 1 warning(s)
========== Build: 0 succeeded, 9 failed, 0 up-to-date, 0 skipped ==========




I have included the necessary header files (/include/tbb) and library files.. I am using VS 2008. How do i proceed?

Thanks
Abhay[/bash]

0 Kudos
1 Solution
Nav
New Contributor I
1,125 Views

Shall we start from the beginning? Unzip the file you've downloaded and follow the readme file.

The readme says: "copy the contents of the "tbb21_012oss" directory to the "code/TBB" directory"

You weren't supposed to copy the tbb21_012oss directory as it is, into code/TBB

(would've been able to help better if I had visual studio. Am having a look at it though, coz I can learn something from the code)

View solution in original post

0 Kudos
7 Replies
Nav
New Contributor I
1,125 Views

I have a feeling you've already tried this, but for a start, you could enter the full path (from the root directory till the file) for 'tbb/tick_count.h' in the file "c:\code\common.h"

0 Kudos
Vladimir_P_1234567890
1,125 Views

hello, where is tbb located? do you have tbb/include/tbb folder next to your solution? i.e. if this example is located in c:\code folder then you need to copy tbb package to c:\code\tbb and you will see c:\code\tbb\include\tbb\tick_count.h file

--Vladimir

0 Kudos
Abhay_Hegde
Beginner
1,125 Views

Thanks Nav, that really didn't stike to mind. I tried adding the exact path as you suggested in the source file, but the error became recursive with header files as well. Therefore i thought of building it file by file at a time, so that i can narrow down the errors.

Common.cpp was the file i tried and while bulding it gave me " Project : error PRJ0019: A tool returned an error code from "Copying DLLs to output directory"

How do i proceed?

Thanks

0 Kudos
Abhay_Hegde
Beginner
1,125 Views

Hi Vladmir, this is my path to tbb - C:\code\TBB\tbb21_012oss. TBB is a directory that i created which is just besides the .sln file

Regards

0 Kudos
Nav
New Contributor I
1,126 Views

Shall we start from the beginning? Unzip the file you've downloaded and follow the readme file.

The readme says: "copy the contents of the "tbb21_012oss" directory to the "code/TBB" directory"

You weren't supposed to copy the tbb21_012oss directory as it is, into code/TBB

(would've been able to help better if I had visual studio. Am having a look at it though, coz I can learn something from the code)

0 Kudos
Abhay_Hegde
Beginner
1,125 Views
Thanks Nav. It worked. What does the code basically do?
0 Kudos
Nav
New Contributor I
1,125 Views

Great!

I'm a little pressed for time to do my own experiments with the code...also given that I don't have Visual Studio.

From a cursory overview it looks like they're showing in each sample program, how different TBB constructs give better performance than serial code.

It'd be great if you could share anything that you find out about it.

0 Kudos
Reply