Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
ApplicationCore
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
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
ChimeraTK Mirror
ApplicationCore
Commits
b8ca0b56
Commit
b8ca0b56
authored
8 years ago
by
Martin Christoph Hierholzer
Browse files
Options
Downloads
Plain Diff
Merge remote-tracking branch 'project-template/master'
parents
fe36e9e6
2a109312
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
cmake/FindPROJECT_NAME.cmake.in.in
+4
-0
4 additions, 0 deletions
cmake/FindPROJECT_NAME.cmake.in.in
cmake/create_cmake_config_files.cmake
+12
-7
12 additions, 7 deletions
cmake/create_cmake_config_files.cmake
with
16 additions
and
7 deletions
cmake/FindPROJECT_NAME.cmake.in.in
+
4
−
0
View file @
b8ca0b56
...
...
@@ -7,6 +7,8 @@
# @PROJECT_NAME@_INCLUDE_DIRS : path to the include directory
# @PROJECT_NAME@_LIBRARY_DIRS : path to the library directory
# @PROJECT_NAME@_LIBRARIES : the provided libraries
# @PROJECT_NAME@_CXX_FLAGS : additional C++ compiler flags
# @PROJECT_NAME@_LINKER_FLAGS : additional linker flags
#
# @author Martin Killenberg, DESY
#
...
...
@@ -17,6 +19,8 @@ set(@PROJECT_NAME@_VERSION @@PROJECT_NAME@_SOVERSION@)
set(@PROJECT_NAME@_INCLUDE_DIRS @@PROJECT_NAME@_INCLUDE_DIRS@)
set(@PROJECT_NAME@_LIBRARY_DIRS @@PROJECT_NAME@_LIBRARY_DIRS@)
set(@PROJECT_NAME@_LIBRARIES @@PROJECT_NAME@_LIBRARIES@)
set(@PROJECT_NAME@_CXX_FLAGS @@PROJECT_NAME@_CXX_FLAGS@)
set(@PROJECT_NAME@_LINKER_FLAGS @@PROJECT_NAME@_LINKER_FLAGS@)
# Use a macro provided by CMake to check if all the listed arguments are valid and set @PROJECT_NAME@_FOUND accordingly.
# This is mainly important to check the version.
...
...
This diff is collapsed.
Click to expand it.
cmake/create_cmake_config_files.cmake
+
12
−
7
View file @
b8ca0b56
...
...
@@ -8,31 +8,36 @@
# ${PROJECT_NAME}_INCLUDE_DIRS - list include directories needed when compiling against this project
# ${PROJECT_NAME}_LIBRARY_DIRS - list of library directories needed when linking against this project
# ${PROJECT_NAME}_LIBRARIES - list of libraries needed when linking against this project
# ${PROJECT_NAME}_C
PP
FLAGS - list of C++ compiler flags when compiling against this project
# ${PROJECT_NAME}_L
D
FLAGS - list of linker flags when linking against this project
# ${PROJECT_NAME}_C
XX_
FLAGS - list of
additional
C++ compiler flags
needed
when compiling against this project
# ${PROJECT_NAME}_L
INKER_
FLAGS - list of
additional
linker flags
needed
when linking against this project
#
#######################################################################################################################
# create variables for standard makefiles
set
(
${
PROJECT_NAME
}
_C
PP
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_C
PP
FLAGS
}
"
)
set
(
${
PROJECT_NAME
}
_C
XX_
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_C
XX_
FLAGS
}
"
)
string
(
REPLACE
" "
";"
LIST
${${
PROJECT_NAME
}
_INCLUDE_DIRS
}
)
foreach
(
INCLUDE_DIR
${
LIST
}
)
set
(
${
PROJECT_NAME
}
_C
PP
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_C
PP
FLAGS_MAKEFILE
}
-I
${
INCLUDE_DIR
}
"
)
set
(
${
PROJECT_NAME
}
_C
XX_
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_C
XX_
FLAGS_MAKEFILE
}
-I
${
INCLUDE_DIR
}
"
)
endforeach
()
set
(
${
PROJECT_NAME
}
_L
D
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_L
D
FLAGS
}
"
)
set
(
${
PROJECT_NAME
}
_L
INKER_
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_L
INKER_
FLAGS
}
"
)
string
(
REPLACE
" "
";"
LIST
${${
PROJECT_NAME
}
_LIBRARY_DIRS
}
)
foreach
(
LIBRARY_DIR
${
LIST
}
)
set
(
${
PROJECT_NAME
}
_L
D
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_L
D
FLAGS_MAKEFILE
}
-L
${
LIBRARY_DIR
}
"
)
set
(
${
PROJECT_NAME
}
_L
INKER_
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_L
INKER_
FLAGS_MAKEFILE
}
-L
${
LIBRARY_DIR
}
"
)
endforeach
()
string
(
REPLACE
" "
";"
LIST
${${
PROJECT_NAME
}
_LIBRARIES
}
)
foreach
(
LIBRARY
${
LIST
}
)
set
(
${
PROJECT_NAME
}
_L
D
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_L
D
FLAGS_MAKEFILE
}
-l
${
LIBRARY
}
"
)
set
(
${
PROJECT_NAME
}
_L
INKER_
FLAGS_MAKEFILE
"
${${
PROJECT_NAME
}
_L
INKER_
FLAGS_MAKEFILE
}
-l
${
LIBRARY
}
"
)
endforeach
()
# force the lists to be space separated (may be sometimes semicolon separated)
string
(
REPLACE
";"
" "
${
PROJECT_NAME
}
_INCLUDE_DIRS
${${
PROJECT_NAME
}
_INCLUDE_DIRS
}
)
string
(
REPLACE
";"
" "
${
PROJECT_NAME
}
_LIBRARY_DIRS
${${
PROJECT_NAME
}
_LIBRARY_DIRS
}
)
string
(
REPLACE
";"
" "
${
PROJECT_NAME
}
_LIBRARIES
${${
PROJECT_NAME
}
_LIBRARIES
}
)
# we have nested @-statements, so we have to parse twice:
# create the cmake Find package script
...
...
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