Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
60d565e6
Commit
60d565e6
authored
Nov 04, 2021
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmake: detect lz4 version, require >= 1.6
parent
182bf9b3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
3 deletions
+11
-3
cmake/FindLZ4.cmake
cmake/FindLZ4.cmake
+10
-2
plugin/provider_lz4/CMakeLists.txt
plugin/provider_lz4/CMakeLists.txt
+1
-1
No files found.
cmake/FindLZ4.cmake
View file @
60d565e6
find_path
(
LZ4_INCLUDE_DIRS NAMES lz4.h
)
find_library
(
LZ4_LIBRARIES NAMES lz4
)
if
(
LZ4_INCLUDE_DIRS AND EXISTS
"
${
LZ4_INCLUDE_DIRS
}
/lz4.h"
)
file
(
STRINGS
"
${
LZ4_INCLUDE_DIRS
}
/lz4.h"
LZ4_H REGEX
"^#define LZ4_VERSION_[MR]"
)
string
(
REGEX REPLACE
"LZ4_VERSION"
""
LZ4_H
"
${
LZ4_H
}
"
)
string
(
REGEX MATCHALL
"[0-9]+"
LZ4_H
"
${
LZ4_H
}
"
)
string
(
REGEX REPLACE
";"
"."
LZ4_VERSION_STRING
"
${
LZ4_H
}
"
)
endif
()
include
(
FindPackageHandleStandardArgs
)
FIND_PACKAGE_HANDLE_STANDARD_ARGS
(
LZ4 DEFAULT_MSG
LZ4_LIBRARIES LZ4_INCLUDE_DIRS
)
LZ4
REQUIRED_VARS LZ4_LIBRARIES LZ4_INCLUDE_DIRS
VERSION_VAR LZ4_VERSION_STRING
)
mark_as_advanced
(
LZ4_INCLUDE_DIRS LZ4_LIBRARIES
)
plugin/provider_lz4/CMakeLists.txt
View file @
60d565e6
FIND_PACKAGE
(
LZ4
)
FIND_PACKAGE
(
LZ4
1.6
)
IF
(
LZ4_FOUND
)
GET_PROPERTY
(
dirs DIRECTORY PROPERTY INCLUDE_DIRECTORIES
)
...
...
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