Modify test target and add build instructions to readme

This commit is contained in:
Mario Hüttel 2020-11-02 22:31:19 +01:00
parent 2035cf0ad8
commit 5aa063cafd
2 changed files with 7 additions and 2 deletions

View File

@ -7,3 +7,8 @@ If it is set, the lookup table will be moved to the section specified by the def
``#define BASE64_LOOKUP_TABLE_SECTION ".bss"``
This project is licensed under GPLv2.
## Build Instructions
* Type ``make`` to build the static library object.
* Type ``make execute-base64-test`` to build and run the tests

View File

@ -1,9 +1,9 @@
project(base64-test)
add_custom_target(test "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}" "-r compact" "-s" DEPENDS ${PROJECT_NAME})
add_custom_target("execute-${PROJECT_NAME}" "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}" "-r compact" "-s" DEPENDS ${PROJECT_NAME})
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/catch-framework")
aux_source_directory("src" TEST_SOURCES)
add_executable(${PROJECT_NAME} ${TEST_SOURCES})
add_executable(${PROJECT_NAME} EXCLUDE_FROM_ALL ${TEST_SOURCES})
target_link_libraries(${PROJECT_NAME} base64-lib)