Skip to content

Commit

Permalink
Merge Pull Request #12389 from sebrowne/Trilinos/enhance_install_find…
Browse files Browse the repository at this point in the history
…_test

Automatically Merged using Trilinos Pull Request AutoTester
PR Title: b'Framework: Enhance find_package(Trilinos) test'
PR Author: sebrowne
  • Loading branch information
trilinos-autotester authored Oct 19, 2023
2 parents b05c397 + 5b35834 commit 99b6ee3
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ SET(${PROJECT_NAME}_ENABLE_CPACK_PACKAGING_DEFAULT ON)
# Don't allow disabled subpackages to be excluded from tarball
SET(${PROJECT_NAME}_EXCLUDE_DISABLED_SUBPACKAGES_FROM_DISTRIBUTION_DEFAULT FALSE)


SET(Trilinos_USE_GNUINSTALLDIRS_DEFAULT ON)

SET(Trilinos_MUST_FIND_ALL_TPL_LIBS_DEFAULT TRUE)
Expand Down
6 changes: 6 additions & 0 deletions packages/TrilinosInstallTests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,12 @@ tribits_add_advanced_test(find_package_Trilinos
"-- Configuring done"
"-- Generating done"
ALWAYS_FAIL_ON_NONZERO_RETURN

TEST_1
MESSAGE "Build a dummy project that calls find_package(Trilinos)"
CMND "${CMAKE_COMMAND}"
ARGS --build .

ADDED_TEST_NAME_OUT find_package_Trilinos_name
)
# NOTE: The above test will run find_package(Trilinos) for **all** of the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@ find_package(Trilinos REQUIRED)
message("Trilinos_FOUND = '${Trilinos_FOUND}'")
message("Trilinos_SELECTED_PACAKGES_LIST = '${Trilinos_SELECTED_PACAKGES_LIST}'")
message("Trilinos_LIBRARIES = '${Trilinos_LIBRARIES}'")

add_executable(hello hello.cpp)
target_link_libraries(hello PUBLIC ${Trilinos_LIBRARIES})
6 changes: 6 additions & 0 deletions packages/TrilinosInstallTests/find_package_Trilinos/hello.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#include <iostream>

int main() {
std::cout << "Hello World!";
return 0;
}

0 comments on commit 99b6ee3

Please sign in to comment.