Parcourir la source

Adjust CMakeLists.txt as now STB is a header-only implementation.
Additionally, remove all the local changes as they are either not required as the bug has already been fixed upstream or there are other ways to do what we want to do without altering the original code.

Yao Wei Tjong 姚伟忠 il y a 9 ans
Parent
commit
4d67a73bfc

+ 3 - 5
Source/ThirdParty/STB/CMakeLists.txt

@@ -23,11 +23,9 @@
 # Define target name
 set (TARGET_NAME STB)
 
-# Define source files
-define_source_files (GLOB_CPP_PATTERNS *.c)
-
 # Setup target
-setup_library ()
+add_custom_target (${TARGET_NAME} ALL)   # Dummy target just so that its post-build step can install headers to the build tree
+set (STATIC_LIBRARY_TARGETS ${STATIC_LIBRARY_TARGETS} ${TARGET_NAME} PARENT_SCOPE)
 
 # Install headers for building the Urho3D library
-install_header_files (DIRECTORY ./ DESTINATION ${DEST_INCLUDE_DIR}/ThirdParty/STB FILES_MATCHING PATTERN *.h BUILD_TREE_ONLY)  # Note: the trailing slash is significant
+install_header_files (DIRECTORY ./ DESTINATION ${DEST_INCLUDE_DIR}/ThirdParty/STB FILES_MATCHING PATTERN *.h)  # Note: the trailing slash is significant

+ 0 - 3
Source/Tools/RampGenerator/CMakeLists.txt

@@ -26,8 +26,5 @@ set (TARGET_NAME RampGenerator)
 # Define source files
 define_source_files ()
 
-# # Define dependency libs
-# set (LIBS STB)
-
 # Setup target
 setup_executable (TOOL)