CMakeLists.txt 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. #
  2. # Copyright 2009-2017 Alibaba Cloud All rights reserved.
  3. #
  4. # Licensed under the Apache License, Version 2.0 (the "License");
  5. # you may not use this file except in compliance with the License.
  6. # You may obtain a copy of the License at
  7. #
  8. # http://www.apache.org/licenses/LICENSE-2.0
  9. #
  10. # Unless required by applicable law or agreed to in writing, software
  11. # distributed under the License is distributed on an "AS IS" BASIS,
  12. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. # See the License for the specific language governing permissions and
  14. # limitations under the License.
  15. #
  16. set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include)
  17. set(imageprocess_public_header
  18. include/alibabacloud/imageprocess/ImageprocessClient.h
  19. include/alibabacloud/imageprocess/ImageprocessExport.h )
  20. set(imageprocess_public_header_model
  21. include/alibabacloud/imageprocess/model/CalcCACSRequest.h
  22. include/alibabacloud/imageprocess/model/CalcCACSResult.h
  23. include/alibabacloud/imageprocess/model/ClassifyFNFRequest.h
  24. include/alibabacloud/imageprocess/model/ClassifyFNFResult.h
  25. include/alibabacloud/imageprocess/model/DetectCovid19CadRequest.h
  26. include/alibabacloud/imageprocess/model/DetectCovid19CadResult.h
  27. include/alibabacloud/imageprocess/model/DetectHipKeypointXRayRequest.h
  28. include/alibabacloud/imageprocess/model/DetectHipKeypointXRayResult.h
  29. include/alibabacloud/imageprocess/model/DetectKneeKeypointXRayRequest.h
  30. include/alibabacloud/imageprocess/model/DetectKneeKeypointXRayResult.h
  31. include/alibabacloud/imageprocess/model/DetectKneeXRayRequest.h
  32. include/alibabacloud/imageprocess/model/DetectKneeXRayResult.h
  33. include/alibabacloud/imageprocess/model/DetectLungNoduleRequest.h
  34. include/alibabacloud/imageprocess/model/DetectLungNoduleResult.h
  35. include/alibabacloud/imageprocess/model/DetectRibFractureRequest.h
  36. include/alibabacloud/imageprocess/model/DetectRibFractureResult.h
  37. include/alibabacloud/imageprocess/model/DetectSkinDiseaseRequest.h
  38. include/alibabacloud/imageprocess/model/DetectSkinDiseaseResult.h
  39. include/alibabacloud/imageprocess/model/DetectSpineMRIRequest.h
  40. include/alibabacloud/imageprocess/model/DetectSpineMRIResult.h
  41. include/alibabacloud/imageprocess/model/GetAsyncJobResultRequest.h
  42. include/alibabacloud/imageprocess/model/GetAsyncJobResultResult.h
  43. include/alibabacloud/imageprocess/model/RunCTRegistrationRequest.h
  44. include/alibabacloud/imageprocess/model/RunCTRegistrationResult.h
  45. include/alibabacloud/imageprocess/model/RunMedQARequest.h
  46. include/alibabacloud/imageprocess/model/RunMedQAResult.h
  47. include/alibabacloud/imageprocess/model/ScreenChestCTRequest.h
  48. include/alibabacloud/imageprocess/model/ScreenChestCTResult.h
  49. include/alibabacloud/imageprocess/model/TranslateMedRequest.h
  50. include/alibabacloud/imageprocess/model/TranslateMedResult.h )
  51. set(imageprocess_src
  52. src/ImageprocessClient.cc
  53. src/model/CalcCACSRequest.cc
  54. src/model/CalcCACSResult.cc
  55. src/model/ClassifyFNFRequest.cc
  56. src/model/ClassifyFNFResult.cc
  57. src/model/DetectCovid19CadRequest.cc
  58. src/model/DetectCovid19CadResult.cc
  59. src/model/DetectHipKeypointXRayRequest.cc
  60. src/model/DetectHipKeypointXRayResult.cc
  61. src/model/DetectKneeKeypointXRayRequest.cc
  62. src/model/DetectKneeKeypointXRayResult.cc
  63. src/model/DetectKneeXRayRequest.cc
  64. src/model/DetectKneeXRayResult.cc
  65. src/model/DetectLungNoduleRequest.cc
  66. src/model/DetectLungNoduleResult.cc
  67. src/model/DetectRibFractureRequest.cc
  68. src/model/DetectRibFractureResult.cc
  69. src/model/DetectSkinDiseaseRequest.cc
  70. src/model/DetectSkinDiseaseResult.cc
  71. src/model/DetectSpineMRIRequest.cc
  72. src/model/DetectSpineMRIResult.cc
  73. src/model/GetAsyncJobResultRequest.cc
  74. src/model/GetAsyncJobResultResult.cc
  75. src/model/RunCTRegistrationRequest.cc
  76. src/model/RunCTRegistrationResult.cc
  77. src/model/RunMedQARequest.cc
  78. src/model/RunMedQAResult.cc
  79. src/model/ScreenChestCTRequest.cc
  80. src/model/ScreenChestCTResult.cc
  81. src/model/TranslateMedRequest.cc
  82. src/model/TranslateMedResult.cc )
  83. add_library(imageprocess ${LIB_TYPE}
  84. ${imageprocess_public_header}
  85. ${imageprocess_public_header_model}
  86. ${imageprocess_src})
  87. set_target_properties(imageprocess
  88. PROPERTIES
  89. LINKER_LANGUAGE CXX
  90. ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
  91. LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
  92. RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
  93. OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}imageprocess
  94. )
  95. if(${LIB_TYPE} STREQUAL "SHARED")
  96. set_target_properties(imageprocess
  97. PROPERTIES
  98. DEFINE_SYMBOL ALIBABACLOUD_IMAGEPROCESS_LIBRARY)
  99. endif()
  100. target_include_directories(imageprocess
  101. PRIVATE include
  102. ${CMAKE_SOURCE_DIR}/core/include
  103. )
  104. target_link_libraries(imageprocess
  105. core)
  106. if(CMAKE_HOST_WIN32)
  107. ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
  108. set(jsoncpp_install_dir ${INSTALL_DIR})
  109. add_dependencies(imageprocess
  110. jsoncpp)
  111. target_include_directories(imageprocess
  112. PRIVATE ${jsoncpp_install_dir}/include)
  113. target_link_libraries(imageprocess
  114. ${jsoncpp_install_dir}/lib/jsoncpp.lib)
  115. set_target_properties(imageprocess
  116. PROPERTIES
  117. COMPILE_OPTIONS "/bigobj")
  118. else()
  119. target_include_directories(imageprocess
  120. PRIVATE /usr/include/jsoncpp)
  121. target_link_libraries(imageprocess
  122. jsoncpp)
  123. endif()
  124. install(FILES ${imageprocess_public_header}
  125. DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/imageprocess)
  126. install(FILES ${imageprocess_public_header_model}
  127. DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/imageprocess/model)
  128. install(TARGETS imageprocess
  129. ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
  130. LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
  131. RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
  132. )