Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix incomplete autotools cmake module install
The autotools install was missing two cmake modules needed for downstream
consumers to use cpputest_discover_tests():

- CppUTest.cmake and _CppUTestDiscovery.cmake were not listed in
  cmakemodules_DATA in Makefile.am
- CppUTestConfig.cmake.autotools.in did not append the Modules directory
  to CMAKE_MODULE_PATH, so include(CppUTest) would fail even if the files
  were present

Both are present in the CMake install; bring the autotools install into
parity.
  • Loading branch information
thetic committed Mar 3, 2026
commit 147579ecc9efa2fdd57e155e1a57a137981dddc8
4 changes: 3 additions & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ pkgconfig_DATA = cpputest.pc

cmakemodulesdir = $(libdir)/CppUTest/cmake/Modules
cmakemodules_DATA = \
cmake/Modules/CppUTestBuildTimeDiscoverTests.cmake
cmake/Modules/CppUTest.cmake \
cmake/Modules/CppUTestBuildTimeDiscoverTests.cmake \
cmake/Modules/_CppUTestDiscovery.cmake

cmakescriptsdir = $(libdir)/CppUTest/cmake/Scripts
cmakescripts_DATA = \
Expand Down
1 change: 1 addition & 0 deletions pkg/CppUTestConfig.cmake.autotools.in
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ endmacro()
####################################################################################

set_and_check(CppUTest_INCLUDE_DIRS "${PACKAGE_PREFIX_DIR}/include")
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/Modules")
include("${CMAKE_CURRENT_LIST_DIR}/CppUTestTargets.cmake")
set(CppUTest_LIBRARIES CppUTest CppUTestExt)
include("${CMAKE_CURRENT_LIST_DIR}/Modules/CppUTestBuildTimeDiscoverTests.cmake")
Expand Down