CMakeLists.txt 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. #
  2. # Copyright (c) 2008-2020 the Urho3D project.
  3. #
  4. # Permission is hereby granted, free of charge, to any person obtaining a copy
  5. # of this software and associated documentation files (the "Software"), to deal
  6. # in the Software without restriction, including without limitation the rights
  7. # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  8. # copies of the Software, and to permit persons to whom the Software is
  9. # furnished to do so, subject to the following conditions:
  10. #
  11. # The above copyright notice and this permission notice shall be included in
  12. # all copies or substantial portions of the Software.
  13. #
  14. # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  15. # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  16. # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  17. # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  18. # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  19. # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  20. # THE SOFTWARE.
  21. #
  22. if (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
  23. # Set CMake minimum version and CMake policy required by UrhoCommon module
  24. cmake_minimum_required (VERSION 3.10.2)
  25. if (COMMAND cmake_policy)
  26. # Libraries linked via full path no longer produce linker search paths
  27. cmake_policy (SET CMP0003 NEW)
  28. # INTERFACE_LINK_LIBRARIES defines the link interface
  29. cmake_policy (SET CMP0022 NEW)
  30. # Disallow use of the LOCATION target property - so we set to OLD as we still need it
  31. cmake_policy (SET CMP0026 OLD)
  32. # MACOSX_RPATH is enabled by default
  33. cmake_policy (SET CMP0042 NEW)
  34. # Honor the visibility properties for SHARED target types only
  35. cmake_policy (SET CMP0063 OLD)
  36. endif ()
  37. # Set project name
  38. project (Urho3D-ExternalProject-BindingGenerator)
  39. # Set CMake modules search path
  40. set (CMAKE_MODULE_PATH ${BAKED_CMAKE_SOURCE_DIR}/CMake/Modules)
  41. # Include UrhoCommon.cmake module after setting project name
  42. include (UrhoCommon)
  43. # Add dependency targets
  44. add_subdirectory (${BAKED_CMAKE_SOURCE_DIR}/Source/ThirdParty/PugiXml host/PugiXml)
  45. # Setup SDK-like include dir in the build tree for building the host-tools
  46. set (DEST_INCLUDE_DIR include/Urho3D)
  47. set (INCLUDE_DIRS ${BAKED_CMAKE_BINARY_DIR}/${DEST_INCLUDE_DIR}/ThirdParty)
  48. endif ()
  49. # Define target name
  50. set (TARGET_NAME BindingGenerator)
  51. # Define source files
  52. define_source_files ()
  53. # Define dependency libs
  54. set (LIBS PugiXml)
  55. # Setup target
  56. setup_executable (TOOL NODEPS)