mirror of
https://github.com/isar/libmdbx.git
synced 2024-12-30 02:54:13 +08:00
mdbx-cmake: one more fix fetch_version macro.
Change-Id: Ic1cd4d2005149305ce320171f13edf3416e0b8f3
This commit is contained in:
parent
83cf4cd3d5
commit
1cab079d6f
@ -169,32 +169,19 @@ macro(fetch_version name source_root_directory parent_scope)
|
||||
list(GET ${name}_VERSION_LIST 2 "${name}_VERSION_RELEASE")
|
||||
list(GET ${name}_VERSION_LIST 3 "${name}_VERSION_REVISION")
|
||||
|
||||
if(parent_scope)
|
||||
set(${name}_VERSION_MAJOR ${${name}_VERSION_MAJOR} PARENT_SCOPE)
|
||||
set(${name}_VERSION_MINOR ${${name}_VERSION_MINOR} PARENT_SCOPE)
|
||||
set(${name}_VERSION_RELEASE ${${name}_VERSION_RELEASE} PARENT_SCOPE)
|
||||
set(${name}_VERSION_REVISION ${${name}_VERSION_REVISION} PARENT_SCOPE)
|
||||
set(${name}_VERSION ${${name}_VERSION} PARENT_SCOPE)
|
||||
if(${parent_scope})
|
||||
set(${name}_VERSION_MAJOR "${${name}_VERSION_MAJOR}" PARENT_SCOPE)
|
||||
set(${name}_VERSION_MINOR "${${name}_VERSION_MINOR}" PARENT_SCOPE)
|
||||
set(${name}_VERSION_RELEASE "${${name}_VERSION_RELEASE}" PARENT_SCOPE)
|
||||
set(${name}_VERSION_REVISION "${${name}_VERSION_REVISION}" PARENT_SCOPE)
|
||||
set(${name}_VERSION "${${name}_VERSION}" PARENT_SCOPE)
|
||||
|
||||
set(${name}_GIT_DESCRIBE ${${name}_GIT_DESCRIBE} PARENT_SCOPE)
|
||||
set(${name}_GIT_TIMESTAMP ${${name}_GIT_TIMESTAMP} PARENT_SCOPE)
|
||||
set(${name}_GIT_TREE ${${name}_GIT_TREE} PARENT_SCOPE)
|
||||
set(${name}_GIT_COMMIT ${${name}_GIT_COMMIT} PARENT_SCOPE)
|
||||
set(${name}_GIT_REVISION ${${name}_GIT_REVISION} PARENT_SCOPE)
|
||||
set(${name}_GIT_VERSION ${${name}_GIT_VERSION} PARENT_SCOPE)
|
||||
else()
|
||||
set(${name}_VERSION_MAJOR ${${name}_VERSION_MAJOR})
|
||||
set(${name}_VERSION_MINOR ${${name}_VERSION_MINOR})
|
||||
set(${name}_VERSION_RELEASE ${${name}_VERSION_RELEASE})
|
||||
set(${name}_VERSION_REVISION ${${name}_VERSION_REVISION})
|
||||
set(${name}_VERSION ${${name}_VERSION})
|
||||
|
||||
set(${name}_GIT_DESCRIBE ${${name}_GIT_DESCRIBE})
|
||||
set(${name}_GIT_TIMESTAMP ${${name}_GIT_TIMESTAMP})
|
||||
set(${name}_GIT_TREE ${${name}_GIT_TREE})
|
||||
set(${name}_GIT_COMMIT ${${name}_GIT_COMMIT})
|
||||
set(${name}_GIT_REVISION ${${name}_GIT_REVISION})
|
||||
set(${name}_GIT_VERSION ${${name}_GIT_VERSION})
|
||||
set(${name}_GIT_DESCRIBE "${${name}_GIT_DESCRIBE}" PARENT_SCOPE)
|
||||
set(${name}_GIT_TIMESTAMP "${${name}_GIT_TIMESTAMP}" PARENT_SCOPE)
|
||||
set(${name}_GIT_TREE "${${name}_GIT_TREE}" PARENT_SCOPE)
|
||||
set(${name}_GIT_COMMIT "${${name}_GIT_COMMIT}" PARENT_SCOPE)
|
||||
set(${name}_GIT_REVISION "${${name}_GIT_REVISION}" PARENT_SCOPE)
|
||||
set(${name}_GIT_VERSION "${${name}_GIT_VERSION}" PARENT_SCOPE)
|
||||
endif()
|
||||
endmacro(fetch_version)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user