Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libmtime
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
icon-libraries
libmtime
Commits
e552932d
Commit
e552932d
authored
4 months ago
by
Sergey Kosukhin
Browse files
Options
Downloads
Patches
Plain Diff
cmake: pure decorative
parent
b26aff79
No related branches found
No related tags found
1 merge request
!50
Refactor CMake scripts
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CMakeLists.txt
+13
-13
13 additions, 13 deletions
CMakeLists.txt
src/CMakeLists.txt
+3
-3
3 additions, 3 deletions
src/CMakeLists.txt
with
16 additions
and
16 deletions
CMakeLists.txt
+
13
−
13
View file @
e552932d
...
...
@@ -8,7 +8,7 @@ cmake_minimum_required(VERSION 3.18)
project
(
mtime
VERSION 1.2.2
LANGUAGES Fortran
C
LANGUAGES
C
Fortran
)
option
(
BUILD_TESTING
"Build tests"
ON
)
...
...
@@ -29,24 +29,22 @@ include(GNUInstallDirs)
add_subdirectory
(
src
)
include
(
CTest
)
if
(
BUILD_TESTING
)
add_subdirectory
(
test
)
else
()
# Allow for 'make test' even if the tests are disabled:
enable_testing
()
if
(
MTIME_BUILD_DOCS
)
add_subdirectory
(
doc
)
endif
()
if
(
MTIME_BUILD_EXAMPLES
)
add_subdirectory
(
examples
)
endif
()
if
(
MTIME_BUILD_DOCS
)
add_subdirectory
(
doc
)
include
(
CTest
)
if
(
BUILD_TESTING
)
add_subdirectory
(
test
)
else
()
# Allow for 'make test' even if the tests are disabled:
enable_testing
()
endif
()
export
(
EXPORT mtime-targets FILE
${
PROJECT_BINARY_DIR
}
/mtime-targets.cmake
)
include
(
CMakePackageConfigHelpers
)
configure_package_config_file
(
${
PROJECT_SOURCE_DIR
}
/cmake/config.cmake.in
...
...
@@ -61,10 +59,12 @@ write_basic_package_version_file(
COMPATIBILITY SameMajorVersion
)
install
(
EXPORT mtime-targets DESTINATION
${
CMAKE_INSTALL_LIBDIR
}
/mtime/cmake
)
install
(
FILES
${
PROJECT_BINARY_DIR
}
/mtime-config.cmake
${
PROJECT_BINARY_DIR
}
/mtime-config-version.cmake
DESTINATION
${
CMAKE_INSTALL_LIBDIR
}
/mtime/cmake
)
export
(
EXPORT mtime-targets FILE
${
PROJECT_BINARY_DIR
}
/mtime-targets.cmake
)
install
(
EXPORT mtime-targets DESTINATION
${
CMAKE_INSTALL_LIBDIR
}
/mtime/cmake
)
This diff is collapsed.
Click to expand it.
src/CMakeLists.txt
+
3
−
3
View file @
e552932d
...
...
@@ -64,11 +64,11 @@ add_library(mtime::mtime ALIAS mtime)
set
(
Fortran_MODULE_DIRECTORY
${
CMAKE_CURRENT_BINARY_DIR
}
/mod
)
set_target_properties
(
mtime
PROPERTIES Fortran_PREPROCESS ON
Fortran_MODULE_DIRECTORY
${
Fortran_MODULE_DIRECTORY
}
C_STANDARD 99
PROPERTIES C_STANDARD 99
C_STANDARD_REQUIRED ON
PUBLIC_HEADER
"
${
public_headers
}
"
Fortran_PREPROCESS ON
Fortran_MODULE_DIRECTORY
${
Fortran_MODULE_DIRECTORY
}
EXPORT_NAME mtime::mtime
VERSION
${
PROJECT_VERSION
}
SOVERSION
${
PROJECT_VERSION_MAJOR
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment