# Copyright (C) 2023 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause

if(${STANDALONE})
        list(APPEND CMAKE_INSTALL_RPATH ${base}/Qt/lib)
else()
        list(APPEND CMAKE_INSTALL_RPATH ${QT6_INSTALL_PREFIX}/${QT6_INSTALL_LIBS}
             ${libclang_lib_dir})
endif()

add_executable(dumpcodemodel main.cpp)

target_include_directories(dumpcodemodel
    PRIVATE
        ${CMAKE_CURRENT_SOURCE_DIR}
        ${CMAKE_CURRENT_SOURCE_DIR}/../ApiExtractor
)

target_link_libraries(dumpcodemodel
    PRIVATE
        apiextractor
        Qt::Core
)

install(TARGETS dumpcodemodel
        DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
