diff --git a/core/os/thread.cpp b/core/os/thread.cpp index 73e31bdb3d4f..92e43963d2c7 100644 --- a/core/os/thread.cpp +++ b/core/os/thread.cpp @@ -28,6 +28,10 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ +// Define PLATFORM_CUSTOM_THREAD_H in platform_config.h +// Overriding the platform implementation is required in some proprietary platforms +#ifndef PLATFORM_CUSTOM_THREAD_H + #include "thread.h" #include "core/object/script_language.h" @@ -126,3 +130,4 @@ Thread::~Thread() { } #endif +#endif // PLATFORM_CUSTOM_THREAD_H diff --git a/core/os/thread.h b/core/os/thread.h index 17ac82c6506a..3a0938c7f752 100644 --- a/core/os/thread.h +++ b/core/os/thread.h @@ -28,6 +28,11 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ +// Define PLATFORM_CUSTOM_THREAD_H in platform_config.h +// Overriding the platform implementation is required in some proprietary platforms +#ifdef PLATFORM_CUSTOM_THREAD_H +#include PLATFORM_CUSTOM_THREAD_H +#else #ifndef THREAD_H #define THREAD_H @@ -116,3 +121,4 @@ class Thread { }; #endif // THREAD_H +#endif // PLATFORM_CUSTOM_THREAD_H