Protect from regressions due to use of undefined or
implementation-specific behavior when using `std::` containers and smart
pointers.
This only has effect on platforms with the GNU standard C++ library.
Refer to https://gcc.gnu.org/onlinedocs/libstdc++/manual/debug_mode.html.
There is no need to use the embedded gtest code copy in Linux systems, if they already provide the googletest framework system-wide.
Search for it, and fallback to the embedded one if the system one is not detected.
This patch has been also contributed by Simon Quigley <tsimonq2@debian.org>
* CMake: Add option to set the package install dir.
* CMake: Fix generated config.
- `YAML_CPP_SHARED_LIBS_BUILT` should not be set with a `PATH_VAR` as it
would always evaluate to true.
- `YAML_CPP_LIBRARIES` should used the exported target name including
the namespace, but `check_required_components` shouldn't.
- Use `CMAKE_CURRENT_LIST_DIR` to find the target file, instead of a
`PATH_VAR`. Package managers such as vcpkg move CMake configs after
installing.
* CI: Test the generated CMake package.
* CMake: Create add a deprecated yaml-cpp target.
This target is meant to provide compatibility with versions prior to
0.8.0.
* CMake: mark the yaml-cpp target as IMPORTED.
---------
Co-authored-by: Jesse Beder <jbeder+github@gmail.com>
* CI: test with supported C++ standards
let's test with the supported standards for better coverage.
C++23 standard was just out, but the support on the toolchain is
not quite ready yet. so let's leave it for a future change.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* CI: drop redundant Build step
"Build Tests" is strictly a superset of "Build". in addition to
the library, the former builds the tests also. both these
steps share the same set of command line arguments. by removing
"Build" step, we don't lose anything regarding the test coverage
and information for further investigation if the build fails.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
---------
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* Test(CMake) set NAME and COMMAND in add_test
* (CMake) add enable_testing()
* (CMake) move cmake_dependent_option up, before using them
* (CMake) use YAML_CPP_MAIN_PROJECT in cmake_dependent_option
* (CMake) log values regarding tests
* (CMake) always find CTest, but don't enable tests
* (CMAKE)(temp) fix logging
* (actions) set YAML_CPP_BUILD_TESTS for tests
* (actions) provide YAML_CPP_BUILD_TESTS to ctest
* (actions) set -DYAML_CPP_BUILD_TESTS at build
* (actions) don't fail false
* (actions) build tests in Test step
* (actions) run tests verbose
* (CMake) remove temp logging
* (actions) split building from running tests
* (actions) ctest Debug
* (actions) ctest Debug
* Remove enable_testing
It secures the repo against erroneous or malicious actions from external jobs you call from your workflow. It's specially important for the case they get compromised, for example.
Add copying of shared library to the output directory with a test binary.
[binary] removed using of non unsigned char as argument at
'std::isspace' function that was provokes undefined behavior.
[.github/workflows/build.yml] enabled run of test at the
'windows-latest' environment.