mirror of
https://github.com/azahar-emu/dynarmic
synced 2025-11-07 07:29:59 +01:00
build(cmake): add version and soversion to the library
This adds versioning information to the built library. When building the shared library on Linux systems, a new object will be created: libdynarmic.so.5 This is really useful when talking about ABI compatibility. The variables dynarmic_VERSION and dynarmic_VERSION_MAJOR are implicitly created when calling project(dynarmic VERSION x.y.z)
This commit is contained in:
parent
55bede81f8
commit
b87a889d98
@ -1,5 +1,5 @@
|
|||||||
cmake_minimum_required(VERSION 3.8)
|
cmake_minimum_required(VERSION 3.8)
|
||||||
project(dynarmic C CXX ASM)
|
project(dynarmic LANGUAGES C CXX ASM VERSION 5)
|
||||||
|
|
||||||
# Determine if we're built as a subproject (using add_subdirectory)
|
# Determine if we're built as a subproject (using add_subdirectory)
|
||||||
# or if this is the master project.
|
# or if this is the master project.
|
||||||
|
|||||||
@ -364,6 +364,10 @@ include(CreateDirectoryGroups)
|
|||||||
create_target_directory_groups(dynarmic)
|
create_target_directory_groups(dynarmic)
|
||||||
|
|
||||||
target_include_directories(dynarmic PUBLIC ..)
|
target_include_directories(dynarmic PUBLIC ..)
|
||||||
|
set_target_properties(dynarmic PROPERTIES
|
||||||
|
VERSION ${dynarmic_VERSION}
|
||||||
|
SOVERSION ${dynarmic_VERSION_MAJOR}
|
||||||
|
)
|
||||||
target_compile_options(dynarmic PRIVATE ${DYNARMIC_CXX_FLAGS})
|
target_compile_options(dynarmic PRIVATE ${DYNARMIC_CXX_FLAGS})
|
||||||
target_link_libraries(dynarmic
|
target_link_libraries(dynarmic
|
||||||
PUBLIC
|
PUBLIC
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user