代码拉取完成,页面将自动刷新
cmake_minimum_required(VERSION 3.1)
cmake_policy(VERSION 3.1)
if(POLICY CMP0072)
cmake_policy(SET CMP0072 NEW)
endif(POLICY CMP0072)
set(CMAKE_CXX_STANDARD 11)
project(ks-vaudit VERSION 0.4.4)
if(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64|i386|i686")
set(PROCESSOR_IS_X86 TRUE)
else()
set(PROCESSOR_IS_X86 FALSE)
endif()
# AddressSanitizer to check memleak
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-omit-frame-pointer -fsanitize=leak")
option(ENABLE_32BIT_GLINJECT "Build the 32-bit version of 'libssr-glinject' on 64-bit systems (in addition to the 64-bit version). Required for OpenGL recording of 32-bit applications on 64-bit systems." FALSE)
option(ENABLE_X86_ASM "Allow x86/x64 assembly or intrinsics." ${PROCESSOR_IS_X86})
option(ENABLE_FFMPEG_VERSIONS "Use FFmpeg version numbers for feature support tests. Enable when using FFmpeg, disable when using Libav." TRUE)
option(ENABLE_JACK_METADATA "Use the JACK metadata API. May not work with very old JACK versions." FALSE)
option(WITH_OPENGL_RECORDING "Build with OpenGL recording support." FALSE)
option(WITH_V4L2 "Build with V4L2 support." FALSE)
option(WITH_ALSA "Build with ALSA support." FALSE)
option(WITH_PULSEAUDIO "Build with PulseAudio support." TRUE)
option(WITH_JACK "Build with JACK support." FALSE)
option(WITH_SIMPLESCREENRECORDER "Build the 'ks-vaudit' executable." TRUE)
option(WITH_GLINJECT "Build the 'libssr-glinject' library. Required for OpenGL recording." FALSE)
set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
include(FeatureSummary)
include(GNUInstallDirs)
# try to guess the correct 32-bit library path on 64-bit systems
if(ENABLE_32BIT_GLINJECT)
if(NOT DEFINED CMAKE_INSTALL_LIB32DIR)
set(_LIB32DIR_DEFAULT "lib32")
if(EXISTS "/etc/debian_version")
if(EXISTS "/usr/lib/i386-linux-gnu")
set(_LIB32DIR_DEFAULT "lib/i386-linux-gnu")
elseif(EXISTS "/usr/lib/i686-linux-gnu")
set(_LIB32DIR_DEFAULT "lib/i686-linux-gnu")
else()
message(WARNING "Could not find correct multiarch 32-bit library path, falling back to 'lib32'.")
endif()
endif()
set(CMAKE_INSTALL_LIB32DIR "${_LIB32DIR_DEFAULT}" CACHE PATH "object code libraries, 32-bit (${_LIB32DIR_DEFAULT})")
endif()
mark_as_advanced(CMAKE_INSTALL_LIB32DIR)
if(NOT IS_ABSOLUTE ${CMAKE_INSTALL_LIB32DIR})
set(CMAKE_INSTALL_FULL_LIB32DIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIB32DIR}")
else()
set(CMAKE_INSTALL_FULL_LIB32DIR "${CMAKE_INSTALL_LIB32DIR}")
endif()
endif()
if(WITH_GLINJECT)
add_subdirectory(glinject)
endif()
if(WITH_SIMPLESCREENRECORDER)
add_subdirectory(src)
# add_subdirectory(src/translations)
if(WITH_OPENGL_RECORDING)
# the 'ssr-glinject' script is installed together with the main SSR executable to avoid problems with multiarch packages
install(
FILES scripts/ssr-glinject
DESTINATION ${CMAKE_INSTALL_FULL_BINDIR}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
)
endif()
# install(
# DIRECTORY data/output-profiles
# DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/ks-vaudit
# )
# install(
# DIRECTORY data/man/
# DESTINATION ${CMAKE_INSTALL_FULL_MANDIR}/man1
# )
# install(
# FILES data/ks-vaudit.desktop
# DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/applications
# )
install(
FILES data/ks-vaudit.metainfo.xml
DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/metainfo
)
# icons
# set(icons_res 16 22 24 32 48 64 96 128 192 256)
# foreach(res IN LISTS icons_res)
# install(
# DIRECTORY data/icons/${res}/
# DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/icons/hicolor/${res}x${res}/apps
# )
# endforeach()
# install(
# DIRECTORY data/icons/scalable/
# DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/icons/hicolor/scalable/apps
# )
endif()
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。