generated from threeal/project-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: rename sample project to
MyProject
Signed-off-by: Alfi Maulana <alfi.maulana.f@gmail.com>
- Loading branch information
Showing
7 changed files
with
15 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,38 @@ | ||
cmake_minimum_required(VERSION 3.21) | ||
|
||
project( | ||
MyMkdir | ||
MyProject | ||
VERSION 0.0.0 | ||
DESCRIPTION "A starter CMake package for creating directories recursively" | ||
HOMEPAGE_URL https://github.com/threeal/cmake-starter | ||
LANGUAGES NONE) | ||
|
||
option(MY_MKDIR_ENABLE_TESTS "Enable test targets.") | ||
option(MY_MKDIR_ENABLE_INSTALL "Enable install targets." "${PROJECT_IS_TOP_LEVEL}") | ||
option(MY_PROJECT_ENABLE_TESTS "Enable test targets.") | ||
option(MY_PROJECT_ENABLE_INSTALL "Enable install targets." "${PROJECT_IS_TOP_LEVEL}") | ||
|
||
# Prefer system packages over the find modules provided by this project. | ||
if(NOT DEFINED CMAKE_FIND_PACKAGE_PREFER_CONFIG) | ||
set(CMAKE_FIND_PACKAGE_PREFER_CONFIG TRUE) | ||
endif() | ||
|
||
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) | ||
include(MkdirRecursive) | ||
include(MyProject) | ||
|
||
if(MY_MKDIR_ENABLE_TESTS) | ||
if(MY_PROJECT_ENABLE_TESTS) | ||
enable_testing() | ||
|
||
find_package(Assertion 1.0.0 REQUIRED) | ||
assertion_add_test(test/mkdir_recursive.cmake) | ||
endif() | ||
|
||
if(MY_MKDIR_ENABLE_INSTALL) | ||
if(MY_PROJECT_ENABLE_INSTALL) | ||
include(CMakePackageConfigHelpers) | ||
write_basic_package_version_file( | ||
MyMkdirConfigVersion.cmake COMPATIBILITY SameMajorVersion) | ||
MyProjectConfigVersion.cmake COMPATIBILITY SameMajorVersion) | ||
|
||
install( | ||
FILES cmake/MkdirRecursive.cmake | ||
cmake/MyMkdirConfig.cmake | ||
${CMAKE_CURRENT_BINARY_DIR}/MyMkdirConfigVersion.cmake | ||
DESTINATION lib/cmake/MyMkdir) | ||
FILES cmake/MyProject.cmake | ||
cmake/MyProjectConfig.cmake | ||
${CMAKE_CURRENT_BINARY_DIR}/MyProjectConfigVersion.cmake | ||
DESTINATION lib/cmake/MyProject) | ||
endif() |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
include(${CMAKE_CURRENT_LIST_DIR}/MyProject.cmake) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters