Skip to content

Bugfix: mysql-connector-cpp cmake files not work well when as a third party #22

New issue

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

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

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
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/libutils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ configure_file(
if(NOT MSBUILD AND NOT TARGET save_linker_opts)
add_executable(save_linker_opts ${LIBUTILS_SCRIPT_DIR}/save_linker_opts.cc)
set_property(TARGET save_linker_opts PROPERTY
OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}
OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
)
endif()

Expand Down Expand Up @@ -217,7 +217,7 @@ function(merge_libraries TARGET)

add_dependencies(${TARGET}-deps save_linker_opts)
set_target_properties(${TARGET}-deps PROPERTIES
RULE_LAUNCH_LINK "${CMAKE_BINARY_DIR}/save_linker_opts ${log_file}.STATIC "
RULE_LAUNCH_LINK "${CMAKE_CURRENT_BINARY_DIR}/save_linker_opts ${log_file}.STATIC "
)

# Arrange for ${TARGET}-deps to be built before ${TARGET}
Expand All @@ -235,7 +235,7 @@ function(merge_libraries TARGET)
#

set_target_properties(${TARGET} PROPERTIES
RULE_LAUNCH_LINK "${CMAKE_BINARY_DIR}/save_linker_opts ${log_file}.SHARED "
RULE_LAUNCH_LINK "${CMAKE_CURRENT_BINARY_DIR}/save_linker_opts ${log_file}.SHARED "
)

else(NOT MSBUILD)
Expand Down
2 changes: 1 addition & 1 deletion config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,6 @@ else()
SET(CONCPP_LICENSE "GPL-2.0")
endif()

CONFIGURE_FILE(config.h.in ${CMAKE_BINARY_DIR}/include/config.h)
CONFIGURE_FILE(config.h.in ${CMAKE_CURRENT_BINARY_DIR}/include/config.h)
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/include)