Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix build problem after #3575 #3584

Merged
merged 1 commit into from
Oct 10, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions cmake/Modules/BuildDExecutable.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -98,16 +98,16 @@ function(build_d_executable target_name output_exe d_src_files compiler_args lin
set(translated_linker_args "-gcc=${CMAKE_CXX_COMPILER}" ${translated_linker_args})
endif()

# Use an extra custom target as dependency for the executable instead
# of the object files directly to improve parallelization.
# Use an extra custom target as dependency for the executable in
# addition to the object files directly to improve parallelization.
# See https://github.com/ldc-developers/ldc/pull/3575.
add_custom_target(${target_name}_d_objects DEPENDS ${object_files})

add_custom_command(
OUTPUT ${output_exe}
COMMAND ${D_COMPILER} ${dflags} -of${output_exe} ${objects_args} ${dep_libs} ${translated_linker_args}
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
DEPENDS ${target_name}_d_objects ${link_deps}
DEPENDS ${target_name}_d_objects ${object_files} ${link_deps}
)
add_custom_target(${target_name} ALL DEPENDS ${output_exe})
endif()
Expand Down