-
Notifications
You must be signed in to change notification settings - Fork 104
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
Fix BUILD_CLONE_SUBMODULES CMake config option #76
Fix BUILD_CLONE_SUBMODULES CMake config option #76
Conversation
…garw13/coreMQTT into update-cmake-submodule-option
test/unit-test/cmock_build.cmake
Outdated
@@ -3,7 +3,7 @@ macro( clone_cmock ) | |||
find_package( Git REQUIRED ) | |||
message( "Cloning submodule CMock." ) | |||
execute_process( COMMAND rm -rf ${CMOCK_DIR} | |||
COMMAND ${GIT_EXECUTABLE} submodule update --init --recursive ${CMOCK_DIR} | |||
COMMAND ${GIT_EXECUTABLE} submodule update checkout --init --recursive ${CMOCK_DIR} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this need to be --checkout?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we take out the clone you added to the ci.yml, we could test this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this need to be --checkout?
Yes, that is how the update = none
option is overriden
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we take out the clone you added to the ci.yml, we could test this?
Sure
With submodule configuration changes made in #75, the
BUILD_CLONE_SUBMODULES
CMake config became disfynctional (as it uses thegit submodule update --recursive
command).This PR updates the CMake logic to use
git submodule update --checkout --init
command to fix the CMake config option.Also, this PR changes the default value of
BUILD_CLONE_SUBMODULES
to beOFF
to avoid always auto-cloning the CMock submodule.