Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
matrix-org
Olm
Commits
21ba95ad
Commit
21ba95ad
authored
Feb 22, 2021
by
Hubert Chathi
Browse files
create and install a pkg-config file on Unix-like systems
parent
cabefb17
Changes
2
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
21ba95ad
...
...
@@ -64,10 +64,14 @@ set_target_properties(olm PROPERTIES
LIBRARY_OUTPUT_DIRECTORY
${
CMAKE_BINARY_DIR
}
/
${
CMAKE_INSTALL_LIBDIR
}
RUNTIME_OUTPUT_DIRECTORY
${
CMAKE_BINARY_DIR
}
/
${
CMAKE_INSTALL_LIBDIR
}
)
include
(
GNUInstallDirs
)
# Make a pkg-config file
configure_file
(
${
PROJECT_NAME
}
.pc.in
${
PROJECT_NAME
}
.pc @ONLY NEWLINE_STYLE UNIX
)
#
# Installation
#
include
(
GNUInstallDirs
)
set
(
INSTALL_CONFIGDIR
${
CMAKE_INSTALL_LIBDIR
}
/cmake/Olm
)
install
(
TARGETS olm
EXPORT olm-targets
...
...
@@ -86,6 +90,12 @@ install(FILES
${
CMAKE_CURRENT_SOURCE_DIR
}
/include/olm/sas.h
DESTINATION
${
CMAKE_INSTALL_INCLUDEDIR
}
/olm
)
if
(
UNIX AND NOT APPLE
)
install
(
FILES
${
CMAKE_CURRENT_BINARY_DIR
}
/
${
PROJECT_NAME
}
.pc
DESTINATION
${
CMAKE_INSTALL_LIBDIR
}
/pkgconfig
)
endif
()
# Export the targets to a script.
install
(
EXPORT olm-targets
FILE OlmTargets.cmake
...
...
olm.pc.in
0 → 100644
View file @
21ba95ad
prefix=@CMAKE_INSTALL_PREFIX@
exec_prefix=${prefix}
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@
libdir=${exec_prefix}/@CMAKE_INSTALL_LIBDIR@
Name: olm
Description: implementation of the Double Ratchet cryptographic ratchet in C++
Version: @PROJECT_VERSION@
Cflags: -I${includedir}
Libs: -L${libdir} -lolm
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment