diff --git a/include/etl/mutex.h b/include/etl/mutex.h index 33abe27b..d8c74b86 100644 --- a/include/etl/mutex.h +++ b/include/etl/mutex.h @@ -43,6 +43,9 @@ SOFTWARE. #elif defined(ETL_COMPILER_GCC) #include "mutex/mutex_gcc_sync.h" #define ETL_HAS_MUTEX 1 +#elif defined(ETL_COMPILER_GCC) + #include "mutex/mutex_clang_sync.h" + #define ETL_HAS_MUTEX 1 #else #define ETL_HAS_MUTEX 0 #endif diff --git a/include/etl/mutex/mutex_clang_sync.h b/include/etl/mutex/mutex_clang_sync.h new file mode 100644 index 00000000..29434219 --- /dev/null +++ b/include/etl/mutex/mutex_clang_sync.h @@ -0,0 +1,34 @@ +/****************************************************************************** +The MIT License(MIT) + +Embedded Template Library. +https://github.com/ETLCPP/etl +https://www.etlcpp.com + +Copyright(c) 2020 jwellbelove + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files(the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and / or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions : + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +******************************************************************************/ + +#ifndef ETL_MUTEX_CLANG_INCLUDED +#define ETL_MUTEX_CLANG_INCLUDED + +#include "mutex_gcc_sync.h" + +#endif diff --git a/include/etl/version.h b/include/etl/version.h index fc27b601..321a42f5 100644 --- a/include/etl/version.h +++ b/include/etl/version.h @@ -39,7 +39,7 @@ SOFTWARE. #define ETL_VERSION_MAJOR 19 #define ETL_VERSION_MINOR 3 -#define ETL_VERSION_PATCH 1 +#define ETL_VERSION_PATCH 2 #define ETL_VERSION ETL_STRINGIFY(ETL_VERSION_MAJOR) "." ETL_STRINGIFY(ETL_VERSION_MINOR) "." ETL_STRINGIFY(ETL_VERSION_PATCH) #define ETL_VERSION_W ETL_STRINGIFY(ETL_VERSION_MAJOR) L"." ETL_STRINGIFY(ETL_VERSION_MINOR) L"." ETL_STRINGIFY(ETL_VERSION_PATCH) #define ETL_VERSION_U16 ETL_STRINGIFY(ETL_VERSION_MAJOR) u"." ETL_STRINGIFY(ETL_VERSION_MINOR) u"." ETL_STRINGIFY(ETL_VERSION_PATCH) diff --git a/library.json b/library.json index d9f410cf..df8ea384 100644 --- a/library.json +++ b/library.json @@ -1,6 +1,6 @@ { "name": "Embedded Template Library", - "version": "19.3.1", + "version": "19.3.2", "author s": { "name": "John Wellbelove", "email": "john.wellbelove@etlcpp.com" diff --git a/library.properties b/library.properties index 391e5a89..e71da2f9 100644 --- a/library.properties +++ b/library.properties @@ -1,5 +1,5 @@ name=Embedded Template Library -version=19.3.1 +version=19.3.2 author= John Wellbelove maintainer=John Wellbelove license=MIT diff --git a/support/Release notes.txt b/support/Release notes.txt index ff8dd86f..7a9754d1 100644 --- a/support/Release notes.txt +++ b/support/Release notes.txt @@ -1,3 +1,7 @@ +=============================================================================== +19.3.2 +Added No-STL clang mutex that uses GCC implementation. + =============================================================================== 19.3.1 Fixed etl::format_spec constexpr compatibility with C++11. diff --git a/test/test_queue_mpmc_mutex.cpp b/test/test_queue_mpmc_mutex.cpp index ed7fb3fe..10866fba 100644 --- a/test/test_queue_mpmc_mutex.cpp +++ b/test/test_queue_mpmc_mutex.cpp @@ -80,13 +80,6 @@ namespace using ItemM = TestDataM; -// std::ostream& operator <<(std::ostream& os, const Data& data) -// { -// os << data.a << " " << data.b << " " << data.c << " " << data.d; -// -// return os; -// } - SUITE(test_queue_mpmc_mutex) { //************************************************************************* diff --git a/test/vs2019/etl.vcxproj b/test/vs2019/etl.vcxproj index 7fae2640..a43557aa 100644 --- a/test/vs2019/etl.vcxproj +++ b/test/vs2019/etl.vcxproj @@ -1291,6 +1291,7 @@ + diff --git a/test/vs2019/etl.vcxproj.filters b/test/vs2019/etl.vcxproj.filters index 2c69e527..9ab6eff0 100644 --- a/test/vs2019/etl.vcxproj.filters +++ b/test/vs2019/etl.vcxproj.filters @@ -894,6 +894,9 @@ ETL\Containers + + ETL\Utilities\Mutex +