puremvc-cpp-multicore-framework
puremvc-cpp-multicore-framework copied to clipboard
pureMVC-cpp-multicore can not build in Cygwin
my solution is:
first solution: change PureMVC.cpp
from:
if defined(APPLE)
define PTHREAD_MUTEX_RECURSIVE_NP PTHREAD_MUTEX_RECURSIVE
endif
to:
if defined(APPLE) || defined(CYGWIN)
define PTHREAD_MUTEX_RECURSIVE_NP PTHREAD_MUTEX_RECURSIVE
endif
second solution: change PureMVC.cpp, int Mutex::Mutex(void)
from: ::pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE_NP);
to:
if defined(PTHREAD_MUTEX_RECURSIVE_NP)
::pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE_NP);
else
::pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE);
endif
I don't know which is better.
The first is less intrusive, I'd go with that. If you want to make a pull request, I'll accept it.
read the HowToBuild.txt