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

Troubles getting started, thwarted at trying to build TBB on Cygwin

tedbyers
Beginner
1,038 Views

I found the binaries for using TBB on Windows when I develop using MS Visual Studio 2010, but I also develop on Cygwin, and I am having trouble figuring out what arguments to provide to make. I get Javascript errors complaining about arch and runtime. Can anyone provide me with a basic set of parameters to set that will allow me to build TBB within the Cygwin bash environment? Here are the results of my first two attempts:

Ted@Ted-acer-i7w7 ~/tbb40_20120201oss
$ make
'\\"cscript /nologo /E:jscript ./build/detect.js /arch \\""' is not recognized as an internal or external command,
operable program or batch file.
'\\"cscript /nologo /E:jscript ./build/detect.js /runtime \\""' is not recognized as an internal or external command,
operable program or batch file.
build/common.inc:62: *** Architecture not detected. Stop.

Ted@Ted-acer-i7w7 ~/tbb40_20120201oss
$ make arch=ia32
'\\"cscript /nologo /E:jscript ./build/detect.js /runtime \\""' is not recognized as an internal or external command,
operable program or batch file.
build/common.inc:65: *** Runtime version not detected. Stop.


What will let me just build, check and then install the library so that I can start using it?

Thanks

Ted
0 Kudos
8 Replies
Vladimir_P_1234567890
1,038 Views
hello,
could you try to use make with a parameter
[bash]$ make SHELL=/bin/sh[/bash]
--Vladimir
0 Kudos
tedbyers
Beginner
1,038 Views

Thanks Vladimir, That gives some progress, but it leads to a different problem:

Ted@Ted-acer-i7w7 ~/tbb40_20120201oss
$ make SHELL=/bin/sh
Created .\build\windows_unknown_cl_unknown_release and ..._debug directories
make -C ".\\build\\windows_unknown_cl_unknown_debug" -r -f ../../build/Makefile.tbb cfg=debug tbb_root=../..
cygwin warning:
MS-DOS style path detected: .\build\windows_unknown_cl_unknown_debug
Preferred POSIX equivalent is: ./build/windows_unknown_cl_unknown_debug
CYGWIN environment variable option "nodosfilewarning" turns off this warning.
Consult the user's guide for more details about POSIX paths:
http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
make[1]: Entering directory `/home/Ted/tbb40_20120201oss/build/windows_unknown_cl_unknown_debug'
../../build/Makefile.tbb:39: CONFIG: cfg=debug arch=unknown compiler=cl os=windows runtime=unknown
cl /nologo /c /MDd /Od /Ob0 /Zi /EHsc /GR /Zc:forScope /Zc:wchar_t /DTBB_USE_DEBUG /D__TBB_LIB_NAME=tbb_debug.lib /DDO_ITT_NOTIFY /DUSE_WINTHREAD /D_CRT_SECURE_NO_DEPRECATE /D_WIN32_WINNT=0x0501 /D__TBB_BUILD
=1 /W4 /I../../src /I../../src/rml/include /I../../include ../../src/tbb/concurrent_hash_map.cpp
make[1]: cl: Command not found
../../build/common_rules.inc:63: recipe for target `concurrent_hash_map.obj' failed
make[1]: *** [concurrent_hash_map.obj] Error 127
make[1]: Leaving directory `/home/Ted/tbb40_20120201oss/build/windows_unknown_cl_unknown_debug'
Makefile:40: recipe for target `tbb' failed
make: *** [tbb] Error 2

I don't know what cl is supposed to be. If it is a compler, how would I tell it to use the usual GCC compilers?

0 Kudos
Vladimir_P_1234567890
1,038 Views
hello,
In initial post you wrote that you use Dev10 so you need to set compiler command line environemnt ("Visual Studio Tools->required arch/compiler").
if you want to use cygwin's gcc compiler you can run
$ make SHELL=/bin/sh compiler=gcc
but libraries will be incompatible with Dev10 object files/libs.
--Vladimir
0 Kudos
tedbyers
Beginner
1,038 Views
Hi Vladimir

Thanks, but, there seems to be more that is required.

I do not know what Dev10 is. I was talking about getting TBB to build in cygwin, which I find to be a nice environment similar to unix, but running on Windows.

It seem to me that the basic problem is that TBB's makefile knows nothing about cygwin and thus doesn't set a bunch of things that would normally be set.

I will append the current crop of errors, which illustrate what I mean. There are things like, the wrong word size and certain variables not being declared.

Has there been any thought given to providing a configure script, such as is provided in the GCC source, that checks everything that the product both needs and can use if available, and then builds the suite of makefiles required? That would not be useful for Windows devevelopment using MS VS (I have MS VS 2010, and so can use TBB in that environment), but it would go a long way to facilitating building TBB properly on a unix distro with bash or sh or similar.

Thanks again.

Ted
=======errors follow===================

Ted@Ted-acer-i7w7 ~/tbb40_20120201oss
$ make SHELL=/bin/sh compiler=gcc arch=ia32
Created .\build\windows_ia32_gcc_unknown_release and ..._debug directories
make -C ".\\build\\windows_ia32_gcc_unknown_debug" -r -f ../../build/Makefile.tbb cfg=debug tbb_root=../..
make[1]: Entering directory `/home/Ted/tbb40_20120201oss/build/windows_ia32_gcc_unknown_debug'
../../build/Makefile.tbb:39: CONFIG: cfg=debug arch=ia32 compiler=gcc os=windows runtime=unknown
g++ -c -MMD -g -O0 -DTBB_USE_DEBUG -DUSE_WINTHREAD -D_WIN32_WINNT=0x0501 -DMINGW_HAS_SECURE_API=1 -D__MSVCRT_VERSION__=0x0700 -msse -mthreads -m32 -D__TBB_BUILD=1 -Wall -Wno-uninitialized -Wno-parentheses
-I../../src -I../../src/rml/include -I../../include ../../src/tbb/concurrent_hash_map.cpp
In file included from ../../include/tbb/spin_rw_mutex.h:33,
from ../../include/tbb/concurrent_hash_map.h:50,
from ../../src/tbb/concurrent_hash_map.cpp:29:
../../include/tbb/tbb_machine.h:276:6: error: #error Unsupported machine word size.
In file included from ../../include/tbb/spin_rw_mutex.h:33,
from ../../include/tbb/concurrent_hash_map.h:50,
from ../../src/tbb/concurrent_hash_map.cpp:29:
../../include/tbb/tbb_machine.h: In function 'void __TBB_Pause(int32_t)':
../../include/tbb/tbb_machine.h:281: error: '__TBB_Yield' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'void tbb::atomic_fence()':
../../include/tbb/tbb_machine.h:288: error: '__TBB_full_memory_fence' was not declared in this scope
../../include/tbb/tbb_machine.h: In member function 'void tbb::internal::atomic_backoff::pause()':
../../include/tbb/tbb_machine.h:311: error: '__TBB_Yield' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_MaskedCompareAndSwap(volatile T*, T, T)':
../../include/tbb/tbb_machine.h:368: error: there are no arguments to '__TBB_machine_cmpswp4' that depend on a template parameter, so a declaration of '__TBB_machine_cmpswp4' must be available
../../include/tbb/tbb_machine.h:368: error: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_CompareAndSwapGeneric(volatile void*, T, T) [with unsigned int S = 1u, T = unsigned char]':
../../include/tbb/tbb_machine.h:386: error: '__TBB_machine_cmpswp1' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_CompareAndSwapGeneric(volatile void*, T, T) [with unsigned int S = 2u, T = short unsigned int]':
../../include/tbb/tbb_machine.h:395: error: '__TBB_machine_cmpswp2' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_CompareAndSwapGeneric(volatile void*, T, T) [with unsigned int S = 4u, T = unsigned int]':
../../include/tbb/tbb_machine.h:402: error: '__TBB_machine_cmpswp4' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_CompareAndSwapGeneric(volatile void*, T, T) [with unsigned int S = 8u, T = long long unsigned int]':
../../include/tbb/tbb_machine.h:408: error: '__TBB_machine_cmpswp8' was not declared in this scope
../../include/tbb/tbb_machine.h: In static member function 'static T tbb::internal::machine_load_store_seq_cst::load(const volatile T&)':
../../include/tbb/tbb_machine.h:537: error: there are no arguments to '__TBB_full_memory_fence' that depend on a template parameter, so a declaration of '__TBB_full_memory_fence' must be available
../../include/tbb/tbb_machine.h: In static member function 'static void tbb::internal::machine_load_store_seq_cst::store(volatile T&, T)':
../../include/tbb/tbb_machine.h:547: error: there are no arguments to '__TBB_full_memory_fence' that depend on a template parameter, so a declaration of '__TBB_full_memory_fence' must be available
../../include/tbb/tbb_machine.h: In function 'void tbb::internal::__TBB_store_with_release(volatile size_t&, size_t)':
../../include/tbb/tbb_machine.h:609: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'void tbb::internal::__TBB_store_relaxed(volatile size_t&, size_t)':
../../include/tbb/tbb_machine.h:635: error: incomplete type 'tbb::internal::machine_load_store_relaxed' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'void __TBB_AtomicOR(volatile void*, uintptr_t)':
../../include/tbb/tbb_machine.h:762: error: '__TBB_CompareAndSwapW' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'void __TBB_AtomicAND(volatile void*, uintptr_t)':
../../include/tbb/tbb_machine.h:774: error: '__TBB_CompareAndSwapW' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'bool __TBB_TryLockByte(__TBB_atomic_flag&)':
../../include/tbb/tbb_machine.h:788: error: '__TBB_machine_cmpswp1' was not declared in this scope
In file included from ../../include/tbb/tbb_profiling.h:105,
from ../../include/tbb/spin_rw_mutex.h:34,
from ../../include/tbb/concurrent_hash_map.h:50,
from ../../src/tbb/concurrent_hash_map.cpp:29:
../../include/tbb/atomic.h: In static member function 'static int8_t tbb::internal::atomic_traits<1u, M>::compare_and_swap(volatile void*, int8_t, int8_t)':
../../include/tbb/atomic.h:172: error: there are no arguments to '__TBB_machine_cmpswp1' that depend on a template parameter, so a declaration of '__TBB_machine_cmpswp1' must be available
../../include/tbb/atomic.h: In static member function 'static int8_t tbb::internal::atomic_traits<1u, M>::fetch_and_add(volatile void*, int8_t)':
../../include/tbb/atomic.h:172: error: there are no arguments to '__TBB_machine_fetchadd1' that depend on a template parameter, so a declaration of '__TBB_machine_fetchadd1' must be available
../../include/tbb/atomic.h: In static member function 'static int8_t tbb::internal::atomic_traits<1u, M>::fetch_and_store(volatile void*, int8_t)':
../../include/tbb/atomic.h:172: error: there are no arguments to '__TBB_machine_fetchstore1' that depend on a template parameter, so a declaration of '__TBB_machine_fetchstore1' must be available
../../include/tbb/atomic.h: In static member function 'static int16_t tbb::internal::atomic_traits<2u, M>::compare_and_swap(volatile void*, int16_t, int16_t)':
../../include/tbb/atomic.h:173: error: there are no arguments to '__TBB_machine_cmpswp2' that depend on a template parameter, so a declaration of '__TBB_machine_cmpswp2' must be available
../../include/tbb/atomic.h: In static member function 'static int16_t tbb::internal::atomic_traits<2u, M>::fetch_and_add(volatile void*, int16_t)':
../../include/tbb/atomic.h:173: error: there are no arguments to '__TBB_machine_fetchadd2' that depend on a template parameter, so a declaration of '__TBB_machine_fetchadd2' must be available
../../include/tbb/atomic.h: In static member function 'static int16_t tbb::internal::atomic_traits<2u, M>::fetch_and_store(volatile void*, int16_t)':
../../include/tbb/atomic.h:173: error: there are no arguments to '__TBB_machine_fetchstore2' that depend on a template parameter, so a declaration of '__TBB_machine_fetchstore2' must be available
../../include/tbb/atomic.h: In static member function 'static int32_t tbb::internal::atomic_traits<4u, M>::compare_and_swap(volatile void*, int32_t, int32_t)':
../../include/tbb/atomic.h:174: error: there are no arguments to '__TBB_machine_cmpswp4' that depend on a template parameter, so a declaration of '__TBB_machine_cmpswp4' must be available
../../include/tbb/atomic.h: In static member function 'static int32_t tbb::internal::atomic_traits<4u, M>::fetch_and_add(volatile void*, int32_t)':
../../include/tbb/atomic.h:174: error: there are no arguments to '__TBB_machine_fetchadd4' that depend on a template parameter, so a declaration of '__TBB_machine_fetchadd4' must be available
../../include/tbb/atomic.h: In static member function 'static int32_t tbb::internal::atomic_traits<4u, M>::fetch_and_store(volatile void*, int32_t)':
../../include/tbb/atomic.h:174: error: there are no arguments to '__TBB_machine_fetchstore4' that depend on a template parameter, so a declaration of '__TBB_machine_fetchstore4' must be available
../../include/tbb/atomic.h: In static member function 'static int64_t tbb::internal::atomic_traits<8u, M>::compare_and_swap(volatile void*, int64_t, int64_t)':
../../include/tbb/atomic.h:176: error: there are no arguments to '__TBB_machine_cmpswp8' that depend on a template parameter, so a declaration of '__TBB_machine_cmpswp8' must be available
../../include/tbb/atomic.h: In static member function 'static int64_t tbb::internal::atomic_traits<8u, M>::fetch_and_add(volatile void*, int64_t)':
../../include/tbb/atomic.h:176: error: there are no arguments to '__TBB_machine_fetchadd8' that depend on a template parameter, so a declaration of '__TBB_machine_fetchadd8' must be available
../../include/tbb/atomic.h: In static member function 'static int64_t tbb::internal::atomic_traits<8u, M>::fetch_and_store(volatile void*, int64_t)':
../../include/tbb/atomic.h:176: error: there are no arguments to '__TBB_machine_fetchstore8' that depend on a template parameter, so a declaration of '__TBB_machine_fetchstore8' must be available
In file included from ../../include/tbb/concurrent_hash_map.h:55,
from ../../src/tbb/concurrent_hash_map.cpp:29:
../../include/tbb/internal/_concurrent_unordered_impl.h: In member function 'tbb::interface5::internal::split_ordered_list::node* tbb::interface5::internal::split_ordered_list::node
:atomic_set_next(tbb::interface5::internal::split_ordered_list::node*, tbb::interface5::internal::split_ordered_list::node*)':
../../include/tbb/internal/_concurrent_unordered_impl.h:233: error: there are no arguments to '__TBB_CompareAndSwapW' that depend on a template parameter, so a declaration of '__TBB_CompareAndSwapW' must be av
ilable
../../include/tbb/internal/_concurrent_unordered_impl.h: In member function 'std::pair<:INTERFACE5::INTERNAL::SOLIST_ITERATOR><:INTERFACE5::INTERNAL::SPLIT_ORDERED_LIST>, typename Allocator
:rebind::other::value_type>, bool> tbb::interface5::internal::split_ordered_list::try_insert(tbb::interface5::internal::flist_iterator<:INTERFACE5::INTERNAL::SPLIT_ORDERED_LIST>>, typename Allocator::rebind::other::value_type>, tbb::interface5::internal::flist_iterator<:INTERFACE5::INTERNAL::SPLIT_ORDERED_LIST>, typename Allocator::rebind::other::value_type>, c
nst typename Allocator::rebind::other::value_type&, tbb::interface5::internal::sokey_t, typename Allocator::rebind::other::size_type*)':
../../include/tbb/internal/_concurrent_unordered_impl.h:488: error: there are no arguments to '__TBB_FetchAndAddW' that depend on a template parameter, so a declaration of '__TBB_FetchAndAddW' must be availabl

../../include/tbb/internal/_concurrent_unordered_impl.h: In member function 'void tbb::interface5::internal::concurrent_unordered_base::adjust_table_size(typename Traits::allocator_type::size_type, typ
name Traits::allocator_type::size_type)':
../../include/tbb/internal/_concurrent_unordered_impl.h:1299: error: there are no arguments to '__TBB_CompareAndSwapW' that depend on a template parameter, so a declaration of '__TBB_CompareAndSwapW' must be a
ailable
../../include/tbb/internal/_concurrent_unordered_impl.h: In member function 'void tbb::interface5::internal::concurrent_unordered_base::set_bucket(typename Traits::allocator_type::size_type, typename t
b::interface5::internal::split_ordered_list::raw_iterator)':
../../include/tbb/internal/_concurrent_unordered_impl.h:1345: error: there are no arguments to '__TBB_CompareAndSwapW' that depend on a template parameter, so a declaration of '__TBB_CompareAndSwapW' must be a
ailable
In file included from ../../src/tbb/concurrent_hash_map.cpp:29:
../../include/tbb/concurrent_hash_map.h: In member function 'size_t tbb::interface5::internal::hash_map_base::insert_new_node(tbb::interface5::internal::hash_map_base::bucket*, tbb::interface5::internal::hash_
ap_node_base*, size_t)':
../../include/tbb/concurrent_hash_map.h:289: error: '__TBB_CompareAndSwapW' was not declared in this scope
../../include/tbb/concurrent_hash_map.h: In member function 'bool tbb::interface5::concurrent_hash_map::lookup(bool, const Key&, const T*, tbb::interface5::concurrent_hash_mapshCompare, A>::const_accessor*, bool)':
../../include/tbb/concurrent_hash_map.h:1014: error: there are no arguments to '__TBB_Yield' that depend on a template parameter, so a declaration of '__TBB_Yield' must be available
../../include/tbb/tbb_machine.h: In static member function 'static void tbb::internal::machine_load_store_seq_cst::store(volatile T&, T) [with T = unsigned int, unsigned int S = 4u]':
../../include/tbb/tbb_machine.h:622: instantiated from here
../../include/tbb/tbb_machine.h:546: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h:547: error: '__TBB_full_memory_fence' was not declared in this scope
../../include/tbb/tbb_machine.h: In function 'void tbb::internal::__TBB_store_with_release(volatile T&, V) [with T = int64_t, V = long long int]':
../../include/tbb/atomic.h:263: instantiated from 'T tbb::internal::atomic_impl::store_with_release(T) [with T = long long int]'
../../include/tbb/atomic.h:354: instantiated from here
../../include/tbb/tbb_machine.h:605: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_load_with_acquire(const volatile T&) [with T = int64_t]':
../../include/tbb/atomic.h:233: instantiated from 'tbb::internal::atomic_impl::operator T() const volatile [with T = long long int]'
../../include/tbb/atomic.h:354: instantiated from here
../../include/tbb/tbb_machine.h:601: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'void tbb::internal::__TBB_store_with_release(volatile T&, V) [with T = int32_t, V = int]':
../../include/tbb/atomic.h:263: instantiated from 'T tbb::internal::atomic_impl::store_with_release(T) [with T = long int]'
../../include/tbb/atomic.h:359: instantiated from here
../../include/tbb/tbb_machine.h:605: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_load_with_acquire(const volatile T&) [with T = int32_t]':
../../include/tbb/atomic.h:233: instantiated from 'tbb::internal::atomic_impl::operator T() const volatile [with T = long int]'
../../include/tbb/atomic.h:359: instantiated from here
../../include/tbb/tbb_machine.h:601: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'void tbb::internal::__TBB_store_with_release(volatile T&, V) [with T = int16_t, V = short int]':
../../include/tbb/atomic.h:263: instantiated from 'T tbb::internal::atomic_impl::store_with_release(T) [with T = short unsigned int]'
../../include/tbb/atomic.h:380: instantiated from here
../../include/tbb/tbb_machine.h:605: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_load_with_acquire(const volatile T&) [with T = int16_t]':
../../include/tbb/atomic.h:233: instantiated from 'tbb::internal::atomic_impl::operator T() const volatile [with T = short unsigned int]'
../../include/tbb/atomic.h:380: instantiated from here
../../include/tbb/tbb_machine.h:601: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'void tbb::internal::__TBB_store_with_release(volatile T&, V) [with T = int8_t, V = signed char]':
../../include/tbb/atomic.h:263: instantiated from 'T tbb::internal::atomic_impl::store_with_release(T) [with T = char]'
../../include/tbb/atomic.h:382: instantiated from here
../../include/tbb/tbb_machine.h:605: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/tbb_machine.h: In function 'T tbb::internal::__TBB_load_with_acquire(const volatile T&) [with T = int8_t]':
../../include/tbb/atomic.h:233: instantiated from 'tbb::internal::atomic_impl::operator T() const volatile [with T = char]'
../../include/tbb/atomic.h:382: instantiated from here
../../include/tbb/tbb_machine.h:601: error: incomplete type 'tbb::internal::machine_load_store' used in nested name specifier
../../include/tbb/atomic.h: In static member function 'static int32_t tbb::internal::atomic_traits<4u, M>::fetch_and_add(volatile void*, int32_t) [with tbb::memory_semantics M = full_fence]':
../../include/tbb/atomic.h:279: instantiated from 'I tbb::internal::atomic_impl_with_arithmetic::fetch_and_add(D) [with tbb::memory_semantics M = full_fence, I = unsigned int, D = unsigned in
, StepType = char]'
../../include/tbb/atomic.h:283: instantiated from 'I tbb::internal::atomic_impl_with_arithmetic::fetch_and_add(D) [with I = unsigned int, D = unsigned int, StepType = char]'
../../include/tbb/atomic.h:316: instantiated from 'I tbb::internal::atomic_impl_with_arithmetic::operator++() [with I = unsigned int, D = unsigned int, StepType = char]'
../../include/tbb/concurrent_hash_map.h:282: instantiated from here
../../include/tbb/atomic.h:174: error: '__TBB_machine_fetchadd4' was not declared in this scope
../../build/common_rules.inc:63: recipe for target `concurrent_hash_map.o' failed
make[1]: *** [concurrent_hash_map.o] Error 1
make[1]: Leaving directory `/home/Ted/tbb40_20120201oss/build/windows_ia32_gcc_unknown_debug'
Makefile:40: recipe for target `tbb' failed
make: *** [tbb] Error 2

0 Kudos
Alexey-Kukanov
Employee
1,038 Views
Short answer: Cygwin is currently not supported.

Longer answer: as I understand, Cygwin is more than just set of useful utilities; rather it's sort of a UNIX emulatorfor Windows, or, in a sense, a virtual machine or "lightweight" OS on top of Windows. As such, for TBB it probably should be considered as a new OS, not as a new compiler. While you specify the compiler to use and the architecture to build for, TBB makefiles and then code still consider that the program is built for Windows, and follows corresponding paths.

Recommendations: If you need to use GCC on Windows, consider MinGW (and if you also need a UNIX-like set of command line utilities, consider MSYS or GnuWin32). And if you want TBB to work under Cygwin, consider investing your time into developing a support layer for it :) (this is how other enthusiasts enabled TBBfor various architectures, operating systems, and compilers).

In case you go for the latter, I recommend you tostart from copying some of *nix OS files in build/ - for Linux, FreeBSD, or SunOS, whichever Cygwin is closer to - into cygwin.inc and cygwin.gcc.inc, perhaps with some modifications as appropriate. Then, add tbb_os=cygwin (in addition to compiler=gcc and arch=ia32) to the make command, and see how far this will get you. Though it's likely you will get the same errors as above; look into include/tbb/tbb_machine.h, and find the right way to #include "machine/linux_ia32.h" (I guess you will need to put __CYGWIN__ somewhere, perhaps next to __linux__, __FreeBSD__, or __sun, or maybe into its own #elif). I can't imagine what will be the next problem, but whatever it is, report at the forum if you can't work it around, and perhaps someone will help.
0 Kudos
tedbyers
Beginner
1,038 Views
Thanks Alexey

I rather suspected as much when I saw that latestmess of errors.

You are right. Cygwin provides a Unix like environment on Windows. I use it to keep my unix programming skills up, but I use MS VS 2010 (and previously MSVS 2005) for my production Windows programming.

At present, I also use it to produce code that will compile for a colleague of mine who presently uses Ubuntu. He does not yet have the skills to be able to do threading of any kind, so we don't have a critical need for it yet. Right now his skill set is about half way between what I would expect of a recent college grad and a junior programmer. But what I will have to do is set this aside for a time (at work my development team has dwindled from 6 down to just me, but a similar pace of delivery is expected, so I will have to wait for now, either until my own time pressures ease or someone else decides to add support for Cygwin).

I had hoped for an install that was as simple as "./configure, make, make check, make install", much as is the process for many of the libraries we're using. That way, he'd be able to install it in a default location, and I could write infrastructre that would make if feasible for us to use it.

Oh well, thanks anyway.

Ted
0 Kudos
Alexey-Kukanov
Employee
1,038 Views
Quoting tedbyers
I had hoped for an install that was as simple as "./configure, make, make check, make install", much as is the process for many of the libraries we're using.

You are right, TBB open-source packages aren't good in this regard, so installing TBB is not that simple even for Linux. At the very least, we need to add 'make install' with some useful semantics. And I am sorry that there is no ready-to-use Cygwin support; hopefully someone at some point finds time to invest into that.
0 Kudos
Vladimir_P_1234567890
1,038 Views
BTW I've tried to make some port to cygwin a few year ago and it was pretty simple and similar to mingw but there were threading problems with threads number more than 3. I wish they could fix this issue in the latest release.
--Vladimir
0 Kudos
Reply