Skip to content

Commit

Permalink
Update CMakeLists
Browse files Browse the repository at this point in the history
Update for SpoutDX12 and SpoutDX9 build
  • Loading branch information
leadedge committed Aug 27, 2024
1 parent 9293e0c commit 923e9b5
Showing 1 changed file with 37 additions and 2 deletions.
39 changes: 37 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#\-------------------------------------- . -----------------------------------/#
# Filename : CMakeList.txt | Main Spout CMakeList #
# Filename : CMakeLists.txt | Main Spout CMakeList #
# Author : Alexandre Buge | #
# Started : 08/09/2020 12:00 | #
#/-------------------------------------- . -----------------------------------\#
Expand All @@ -12,6 +12,8 @@
# Add necessary SpoutGL headers to SpoutDX includes #
# 07/10/23 - Add SPOUT_BUILD_ARM option and download sse2neon.h #
# Add compiler include_directory and /Zc:preprocessor define #
# 20/07/24 - Add SpoutDX12 library #
# 21/07/24 - Add SpoutDX9 library #
#/-------------------------------------- . -----------------------------------\#

cmake_minimum_required(VERSION 3.15)
Expand Down Expand Up @@ -66,9 +68,11 @@ endif()
# The SpoutDX CMakeLists needs this option
OPTION(SPOUT_BUILD_SPOUTDX_EXAMPLES "Build SpoutDX examples" OFF)

OPTION(SPOUT_BUILD_SPOUTDX "Build SpoutDX DirectX11 support library" OFF)
OPTION(SPOUT_BUILD_SPOUTDX "Build SpoutDX DirectX 9/11/12 libraries" OFF)
if(SPOUT_BUILD_SPOUTDX OR SPOUT_BUILD_SPOUTDX_EXAMPLES)
add_subdirectory(SPOUTSDK/SpoutDirectX/SpoutDX)
add_subdirectory(SPOUTSDK/SpoutDirectX/SpoutDX/SpoutDX12)
add_subdirectory(SPOUTSDK/SpoutDirectX/SpoutDX/SpoutDX9)
endif()

# Install option check boxes
Expand All @@ -92,6 +96,8 @@ if(NOT SKIP_INSTALL_ALL)

if(SPOUT_BUILD_SPOUTDX OR SPOUT_BUILD_SPOUTDX_EXAMPLES)
list(APPEND Spout2InstallTargets SpoutDX SpoutDX_static)
list(APPEND Spout2InstallTargets SpoutDX12 SpoutDX12_static)
list(APPEND Spout2InstallTargets SpoutDX9 SpoutDX9_static)
endif()

if(SPOUT_BUILD_LIBRARY)
Expand Down Expand Up @@ -154,6 +160,7 @@ if(NOT SKIP_INSTALL_ALL)

if(SPOUT_BUILD_SPOUTDX OR SPOUT_BUILD_SPOUTDX_EXAMPLES)
install(
# SpoutDX
FILES
SPOUTSDK/SpoutDirectX/SpoutDX/SpoutDX.h
SPOUTSDK/SpoutGL/SpoutCommon.h
Expand All @@ -165,7 +172,35 @@ if(NOT SKIP_INSTALL_ALL)
SPOUTSDK/SpoutGL/SpoutUtils.h
DESTINATION
${CMAKE_INSTALL_PREFIX}/include/SpoutDX

)
install(
# SpoutDX12
FILES
SPOUTSDK/SpoutDirectX/SpoutDX/SpoutDX12/SpoutDX12.h
SPOUTSDK/SpoutDirectX/SpoutDX/SpoutDX.h
SPOUTSDK/SpoutGL/SpoutCommon.h
SPOUTSDK/SpoutGL/SpoutCopy.h
SPOUTSDK/SpoutGL/SpoutDirectX.h
SPOUTSDK/SpoutGL/SpoutFrameCount.h
SPOUTSDK/SpoutGL/SpoutSenderNames.h
SPOUTSDK/SpoutGL/SpoutSharedMemory.h
SPOUTSDK/SpoutGL/SpoutUtils.h
DESTINATION
${CMAKE_INSTALL_PREFIX}/include/SpoutDX12
)
install(
# SpoutDX9
FILES
SPOUTSDK/SpoutDirectX/SpoutDX/SpoutDX9/SpoutDX9.h
SPOUTSDK/SpoutGL/SpoutCommon.h
SPOUTSDK/SpoutGL/SpoutFrameCount.h
SPOUTSDK/SpoutGL/SpoutSenderNames.h
SPOUTSDK/SpoutGL/SpoutSharedMemory.h
SPOUTSDK/SpoutGL/SpoutUtils.h
DESTINATION
${CMAKE_INSTALL_PREFIX}/include/SpoutDX9
)
endif()

if(SPOUT_BUILD_LIBRARY)
Expand Down

0 comments on commit 923e9b5

Please sign in to comment.