move ui/impl.cmake to src/
Now that there is no separate UI-specific wrapper, it belongs to the implementation rather than to the UI, probably
This commit is contained in:
parent
751408ea92
commit
9742916bd6
|
|
@ -13,4 +13,5 @@ include(diplomat.cmake)
|
||||||
|
|
||||||
qt_standard_project_setup()
|
qt_standard_project_setup()
|
||||||
|
|
||||||
|
add_subdirectory(src)
|
||||||
add_subdirectory(ui)
|
add_subdirectory(ui)
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ add_custom_target(build_impl
|
||||||
DEPENDS "${impl_basename}.a"
|
DEPENDS "${impl_basename}.a"
|
||||||
)
|
)
|
||||||
|
|
||||||
add_library(PROJECT_NAME_impl STATIC IMPORTED)
|
add_library(PROJECT_NAME_impl STATIC IMPORTED GLOBAL)
|
||||||
|
|
||||||
set_target_properties(PROJECT_NAME_impl PROPERTIES
|
set_target_properties(PROJECT_NAME_impl PROPERTIES
|
||||||
IMPORTED_LOCATION "${impl_basename}.a"
|
IMPORTED_LOCATION "${impl_basename}.a"
|
||||||
|
|
@ -48,11 +48,16 @@ set(bindings
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
OUTPUT ${bindings}
|
OUTPUT ${bindings}
|
||||||
COMMAND ${diplomat} cpp "${bindings_dir}"
|
COMMAND ${diplomat} cpp "${bindings_dir}"
|
||||||
MAIN_DEPENDENCY "${CMAKE_SOURCE_DIR}/src/lib.rs"
|
MAIN_DEPENDENCY "lib.rs"
|
||||||
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
|
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
|
||||||
VERBATIM
|
VERBATIM
|
||||||
${diplomat_cmake_args}
|
${diplomat_cmake_args}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# HACK ensure CMake *actually adds* the command above
|
||||||
|
add_custom_target(codegen_impl
|
||||||
|
DEPENDS ${bindings}
|
||||||
|
)
|
||||||
|
|
||||||
target_sources(PROJECT_NAME_impl INTERFACE ${bindings})
|
target_sources(PROJECT_NAME_impl INTERFACE ${bindings})
|
||||||
target_include_directories(PROJECT_NAME_impl INTERFACE "${bindings_dir}")
|
target_include_directories(PROJECT_NAME_impl INTERFACE "${bindings_dir}")
|
||||||
|
|
@ -1,5 +1,3 @@
|
||||||
include(impl.cmake)
|
|
||||||
|
|
||||||
qt_add_executable(PROJECT-NAME
|
qt_add_executable(PROJECT-NAME
|
||||||
src/main.cxx
|
src/main.cxx
|
||||||
src/main_window.cxx
|
src/main_window.cxx
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user