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

CMake: Style fixes #2727

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
3 participants
@ruslo
Contributor

ruslo commented Jul 10, 2018

No description provided.

@bagder bagder added the cmake label Jul 10, 2018

@snikulov

This comment has been minimized.

Show comment
Hide comment
@snikulov

snikulov Jul 16, 2018

Member

@ruslo Could you please squash your changes into a single commit?
Commit message also should be updated to

cmake: style fixes [according to link to style guide?]

Also, it would be great to provide a link to cmake style guide your using

Thank you.

Member

snikulov commented Jul 16, 2018

@ruslo Could you please squash your changes into a single commit?
Commit message also should be updated to

cmake: style fixes [according to link to style guide?]

Also, it would be great to provide a link to cmake style guide your using

Thank you.

@ruslo

This comment has been minimized.

Show comment
Hide comment
@ruslo

ruslo Jul 16, 2018

Contributor

Could you please squash your changes into a single commit?

For review reason I made a few small commits, but if you want to squash them anyway you can do it using GitHub:
image

it would be great to provide a link to cmake style guide your using

I was not using any guide, I just made syntax consistent. E.g. currently in master most of the CMake code is lower-case, no tabs and if(A) ... endif() instead of if(A) ... endif(A):

  • curl/CMakeLists.txt

    Lines 93 to 104 in 092f681

    if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG)
    if (PICKY_COMPILER)
    foreach (_CCOPT -pedantic -Wall -W -Wpointer-arith -Wwrite-strings -Wunused -Wshadow -Winline -Wnested-externs -Wmissing-declarations -Wmissing-prototypes -Wno-long-long -Wfloat-equal -Wno-multichar -Wsign-compare -Wundef -Wno-format-nonliteral -Wendif-labels -Wstrict-prototypes -Wdeclaration-after-statement -Wstrict-aliasing=3 -Wcast-align -Wtype-limits -Wold-style-declaration -Wmissing-parameter-type -Wempty-body -Wclobbered -Wignored-qualifiers -Wconversion -Wno-sign-conversion -Wvla -Wdouble-promotion -Wno-system-headers)
    # surprisingly, CHECK_C_COMPILER_FLAG needs a new variable to store each new
    # test result in.
    CHECK_C_COMPILER_FLAG(${_CCOPT} OPT${_CCOPT})
    if(OPT${_CCOPT})
    set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${_CCOPT}")
    endif()
    endforeach()
    endif()
    endif()
Contributor

ruslo commented Jul 16, 2018

Could you please squash your changes into a single commit?

For review reason I made a few small commits, but if you want to squash them anyway you can do it using GitHub:
image

it would be great to provide a link to cmake style guide your using

I was not using any guide, I just made syntax consistent. E.g. currently in master most of the CMake code is lower-case, no tabs and if(A) ... endif() instead of if(A) ... endif(A):

  • curl/CMakeLists.txt

    Lines 93 to 104 in 092f681

    if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG)
    if (PICKY_COMPILER)
    foreach (_CCOPT -pedantic -Wall -W -Wpointer-arith -Wwrite-strings -Wunused -Wshadow -Winline -Wnested-externs -Wmissing-declarations -Wmissing-prototypes -Wno-long-long -Wfloat-equal -Wno-multichar -Wsign-compare -Wundef -Wno-format-nonliteral -Wendif-labels -Wstrict-prototypes -Wdeclaration-after-statement -Wstrict-aliasing=3 -Wcast-align -Wtype-limits -Wold-style-declaration -Wmissing-parameter-type -Wempty-body -Wclobbered -Wignored-qualifiers -Wconversion -Wno-sign-conversion -Wvla -Wdouble-promotion -Wno-system-headers)
    # surprisingly, CHECK_C_COMPILER_FLAG needs a new variable to store each new
    # test result in.
    CHECK_C_COMPILER_FLAG(${_CCOPT} OPT${_CCOPT})
    if(OPT${_CCOPT})
    set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${_CCOPT}")
    endif()
    endforeach()
    endif()
    endif()
@snikulov

This comment has been minimized.

Show comment
Hide comment
@snikulov

snikulov Jul 17, 2018

Member

@ruslo Thanks for the tip.
But for review reasons, it is better to provide small changes with clear descriptions as described here.

While I'm not objecting in general for those changes, the clear description should be provided.
If no guide used, why you name it - style fixes? The whole commit could be named as cmake: update scripts to use consistent style

Member

snikulov commented Jul 17, 2018

@ruslo Thanks for the tip.
But for review reasons, it is better to provide small changes with clear descriptions as described here.

While I'm not objecting in general for those changes, the clear description should be provided.
If no guide used, why you name it - style fixes? The whole commit could be named as cmake: update scripts to use consistent style

@ruslo

This comment has been minimized.

Show comment
Hide comment
@ruslo

ruslo Jul 17, 2018

Contributor

Could you please squash your changes into a single commit?

Squashed into one commit

The whole commit could be named as cmake: update scripts to use consistent style

Renamed

Contributor

ruslo commented Jul 17, 2018

Could you please squash your changes into a single commit?

Squashed into one commit

The whole commit could be named as cmake: update scripts to use consistent style

Renamed

@snikulov snikulov self-requested a review Jul 17, 2018

@snikulov

This comment has been minimized.

Show comment
Hide comment
@snikulov

snikulov Jul 17, 2018

Member

LGTM

Member

snikulov commented Jul 17, 2018

LGTM

@bagder

This comment has been minimized.

Show comment
Hide comment
@bagder

bagder Jul 17, 2018

Member

Thanks!

Member

bagder commented Jul 17, 2018

Thanks!

@bagder bagder closed this in d1207c0 Jul 17, 2018

@ruslo ruslo deleted the ruslo:pr.cmake.style branch Jul 17, 2018

xquery added a commit to xquery/curl that referenced this pull request Aug 9, 2018

CMake: Update scripts to use consistent style
Closes #2727
Reviewed-by: Sergei Nikulov

falconindy added a commit to falconindy/curl that referenced this pull request Sep 10, 2018

CMake: Update scripts to use consistent style
Closes #2727
Reviewed-by: Sergei Nikulov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment