ysyx-workbench/abstract-machine/am/CMakeLists.txt

27 lines
729 B
Text
Raw Normal View History

add_subdirectory(src)
2024-03-25 08:56:16 +00:00
foreach(PLATFORM IN LISTS PLATFORMS)
2024-07-09 09:26:11 +00:00
if(ISA MATCHES "native")
set(ARCH "native")
else()
set(ARCH ${ISA}-${PLATFORM})
endif()
install(
TARGETS am-${ARCH}
EXPORT amTargets-${ARCH}
LIBRARY DESTINATION lib)
2024-07-09 09:26:11 +00:00
install(
EXPORT amTargets-${ARCH}
FILE amTargets.cmake
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/am-${ARCH})
2024-07-09 09:26:11 +00:00
configure_package_config_file(
${CMAKE_SOURCE_DIR}/cmake/am-config.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/am-${ARCH}-config.cmake
INSTALL_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/am-${ARCH})
2024-03-25 08:56:16 +00:00
2024-07-09 09:26:11 +00:00
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/am-${ARCH}-config.cmake
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/am-${ARCH})
endforeach()