Skip to content

Conversation

@rschu1ze
Copy link
Member

@rschu1ze rschu1ze commented May 12, 2022

Just some random build script fixes done when teaching myself cmake for an issue.

See commit msgs of individual commits for details.

Changelog category (leave one):

  • Build/Testing/Packaging Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

  • Make cmake build scripts a bit more robust.

@rschu1ze rschu1ze changed the title Cmake cleanup Misc cmake cleanup May 12, 2022
@robot-ch-test-poll2 robot-ch-test-poll2 added the submodule changed At least one submodule changed in this PR. label May 12, 2022
@robot-ch-test-poll1 robot-ch-test-poll1 added the pr-build Pull request with build/testing/packaging improvement label May 12, 2022
@rschu1ze rschu1ze force-pushed the cmake-cleanup branch 6 times, most recently from f61eb48 to 8650e43 Compare May 13, 2022 07:29
@rschu1ze rschu1ze marked this pull request as ready for review May 13, 2022 11:05
@alexey-milovidov alexey-milovidov self-assigned this May 13, 2022
rschu1ze added 14 commits May 15, 2022 09:48
Both are equivalent and removing the duplication was a leftover of PR #36614
- Variable CMAKE_BUILD_COLOR_MAKEFILE has no effect (perhaps it had in
  ancient CMake), the actual variable is called CMAKE_COLOR_MAKEFILE
Looks like an unused leftover
The module path makes CMake find scripts in directories without
directory qualification, e.g.
    include (tools)
instead of
    include (cmake/tools.cmake)
The latter is a little bit longer but less ambiguous (imho). Therefore,
removing CMAKE_MODULE_PATH. Note that it pointed to a non-existing
directory anyways ...
As far as I see these were necessary for super old Cmake versions and
when contrib libraries (snappy, re2, google test) were still unbundled.
CMake will translate this to a compiler-specific flag to pass the flags
to the linker, e.g. for Clang: "-Xlinker", for GCC: "-Wl,". It worked so
far because Clang supports -Wl in the meantime too but we should prefer
the portable method.
@rschu1ze rschu1ze merged commit 51ad78c into master May 15, 2022
@rschu1ze rschu1ze deleted the cmake-cleanup branch May 15, 2022 07:56
yokofly added a commit to timeplus-io/proton that referenced this pull request Oct 22, 2023
ld: warning: -undefined error is deprecated
porting missing code line in ClickHouse/ClickHouse#37169
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-build Pull request with build/testing/packaging improvement submodule changed At least one submodule changed in this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants