diff --git a/CHANGES.md b/CHANGES.md index 9062726..028c887 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,6 +1,11 @@ # libpath - Changes +## 0.3.0-beta3 - 27th October 2026 + +* Defined `HAS_xTests` and `HAS_XTESTS` when **xTests** is detected; + + ## 0.3.0-beta2 - 20th October 2026 * Aligned the **run_all_examples.sh**, **run_all_scratch_tests.sh** / **.cmd**, and **run_all_unit_tests.sh** helper scripts with **misc-dev-scripts** gold tip **0754c23**, excluding **CMakeFiles** and `*.d` / `*.o` / `*.obj` from discovery and adding scratch `--skip-interactive`; diff --git a/CMakeLists.txt b/CMakeLists.txt index 63797a2..872d0c1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -155,6 +155,12 @@ if(BUILD_TESTING) include_directories(${STLSOFT_INCLUDE_DIR}) endif() + + if(DEFINED STLSOFT_INCLUDE_DIR OR DEFINED STLSoft_FOUND) + + add_compile_definitions(HAS_STLSOFT) + add_compile_definitions(HAS_STLSoft) + endif() endif(BUILD_TESTING) @@ -163,11 +169,16 @@ endif(BUILD_TESTING) if(BUILD_TESTING) - set(xTests_REQUIRED_VERSION_ 0.26) + set(xTests_REQUIRED_VERSION_ 0.28) find_package(xTests ${xTests_REQUIRED_VERSION_} REQUIRED) message("-- CMake package xTests found (version ${xTests_VERSION}; ${xTests_REQUIRED_VERSION_} requested)") + + add_compile_definitions( + HAS_xTests + HAS_XTESTS + ) endif(BUILD_TESTING) diff --git a/NEWS.md b/NEWS.md index 2a0f3e3..19ce8e0 100644 --- a/NEWS.md +++ b/NEWS.md @@ -3,6 +3,7 @@ | Date | News Item | Details | | ------------------- | ----------------------------------- | ------------------------------- | +| 27th October 2026 | Release of [libpath 0.3.0-beta3](https://github.com/synesissoftware/libpath/releases/tag/0.3.0-beta3) | `HAS_xTests` / `HAS_XTESTS` when **xTests** is detected | | 20th October 2026 | Release of [**libpath** 0.3.0-beta2](https://github.com/synesissoftware/libpath/releases/tag/0.3.0-beta2) | Gold tip helpers | | 14th October 2026 | Release of [**libpath** 0.3.0-beta1](https://github.com/synesissoftware/libpath/releases/tag/0.3.0-beta1) | Gold helpers; modular CI; `LIBPATH_VER_RELSTATUS` | | 15th March 2025 | Release of [**libpath** 0.3.0-alpha1](https://github.com/synesissoftware/libpath/releases/tag/0.3.0-alpha1) | Changed API | diff --git a/include/libpath/common/version.h b/include/libpath/common/version.h index c8ee68a..4814b7f 100644 --- a/include/libpath/common/version.h +++ b/include/libpath/common/version.h @@ -4,7 +4,7 @@ * Purpose: Portability discrimination for libpath library. * * Created: 9th November 2012 - * Updated: 20th October 2026 + * Updated: 27th October 2026 * * Home: https://github.com/synesissoftware/libpath * @@ -96,7 +96,7 @@ #define LIBPATH_VER_MAJOR 0 #define LIBPATH_VER_MINOR 3 #define LIBPATH_VER_PATCH 0 -#define LIBPATH_VER_RELSTATUS 0x82 +#define LIBPATH_VER_RELSTATUS 0x83 #define LIBPATH_VER \ (0\ diff --git a/test/scratch/versions/CMakeLists.txt b/test/scratch/versions/CMakeLists.txt index 316c4d2..1aef27b 100644 --- a/test/scratch/versions/CMakeLists.txt +++ b/test/scratch/versions/CMakeLists.txt @@ -1,2 +1,9 @@ -# SIS:AUTO_GENERATED: Remove this line if you edit the file, otherwise it will be overwritten define_example_program(test.scratch.versions main.cpp) + +if(TARGET xTests::core) + + target_link_libraries(test.scratch.versions + PRIVATE + xTests::core + ) +endif() diff --git a/test/scratch/versions/main.cpp b/test/scratch/versions/main.cpp index 81073e7..8bc5a2c 100644 --- a/test/scratch/versions/main.cpp +++ b/test/scratch/versions/main.cpp @@ -1,6 +1,14 @@ #include +#ifdef HAS_STLSoft +# include +#endif + +#ifdef HAS_xTests +# include +#endif + #include #include @@ -45,11 +53,41 @@ version( int main(int /*argc*/, char* /*argv*/[]) { + int efferents_count = 0; + { unsigned const libver = LIBPATH_VER; version(std::cout, "", "libpath", "LIBPATH_VER", libver); } +#ifdef HAS_STLSoft + + if (0 == efferents_count++) + { + std::cout << "\n" << "efferent dependencies:" << std::endl; + } + + { + unsigned const libver = _STLSOFT_VER; + + version(std::cout, "\t", "STLSoft", "_STLSOFT_VER", libver); + } +#endif + +#ifdef HAS_xTests + + if (0 == efferents_count++) + { + std::cout << "\n" << "efferent dependencies:" << std::endl; + } + + { + unsigned const libver = _XTESTS_VER; + + version(std::cout, "\t", "xTests", "_XTESTS_VER", libver); + } +#endif + return EXIT_SUCCESS; }