Skip to content

Commit

Permalink
Add installable exec to help test RPATH (#126)
Browse files Browse the repository at this point in the history
  • Loading branch information
bartlettroscoe committed Oct 27, 2016
1 parent 12de101 commit 54cd803
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,12 @@ TRIBITS_ADD_LIBRARY(
HEADERS ${HEADERS}
SOURCES ${SOURCES}
)

#
# D) Define an executable that gets installed
#

TRIBITS_ADD_EXECUTABLE(simplecxx-helloworld NOEXEPREFIX NOEXESUFFIX
SOURCES SimpleCxx_HelloWorld_Prog.cpp
INSTALLABLE
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#include <iostream>

#include "SimpleCxx_HelloWorld.hpp"

int main()
{
const SimpleCxx::HelloWorld helloWorld;
helloWorld.printHelloWorld(std::cout);
return 0;
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,10 @@ TRIBITS_ADD_EXECUTABLE_AND_TEST(
NUM_MPI_PROCS 1
STANDARD_PASS_OUTPUT
)

TRIBITS_ADD_TEST(simplecxx-helloworld NOEXEPREFIX NOEXESUFFIX
NAME HelloWorldProg
DIRECTORY ${PACKAGE_BINARY_DIR}/src
NUM_MPI_PROCS 1
PASS_REGULAR_EXPRESSION "Hello World"
)

0 comments on commit 54cd803

Please sign in to comment.