Skip to content
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

script: add option for debug build #53855

Merged
merged 1 commit into from Oct 7, 2023
Merged

Conversation

batrick
Copy link
Member

@batrick batrick commented Oct 6, 2023

See: ceph/ceph-build#2167

Contribution Guidelines

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows

@batrick batrick added the script label Oct 6, 2023
src/script/ptl-tool.py Outdated Show resolved Hide resolved
See: ceph/ceph-build#2167

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
@batrick
Copy link
Member Author

batrick commented Oct 6, 2023

+ [[ wip-batrick-testing-20231006.014828-debug == *-debug ]]
+ CEPH_EXTRA_CMAKE_ARGS+=' -DCMAKE_BUILD_TYPE=Debug -DWITH_CEPH_DEBUG_MUTEX=ON'
+ printf 'Added debug cmake configs to branch %s. CEPH_EXTRA_CMAKE_ARGS: %s\n' wip-batrick-testing-20231006.014828-debug ' -DCMAKE_BUILD_TYPE=Debug -DWITH_CEPH_DEBUG_MUTEX=ON'
Added debug cmake configs to branch wip-batrick-testing-20231006.014828-debug. CEPH_EXTRA_CMAKE_ARGS:  -DCMAKE_BUILD_TYPE=Debug -DWITH_CEPH_DEBUG_MUTEX=ON

https://jenkins.ceph.com/job/ceph-dev-new-setup/74098/console

https://shaman.ceph.com/builds/ceph/wip-batrick-testing-20231006.014828-debug/cfbdc475a5ca4098c0330e42cd978c9fd647e012/

centos 8 fails with numerous compiler warnings:

https://shaman.ceph.com/builds/ceph/wip-batrick-testing-20231006.014828-debug/cfbdc475a5ca4098c0330e42cd978c9fd647e012/default/360990/

@batrick batrick marked this pull request as ready for review October 6, 2023 16:09
@batrick
Copy link
Member Author

batrick commented Oct 6, 2023

This PR is ready to go though.

@idryomov
Copy link
Contributor

idryomov commented Oct 6, 2023

centos 8 fails with numerous compiler warnings:

https://shaman.ceph.com/builds/ceph/wip-batrick-testing-20231006.014828-debug/cfbdc475a5ca4098c0330e42cd978c9fd647e012/default/360990/

There is a ton of -Wdeprecated noise, but the actual error is in the arrow submodule:

[  4%] Building CXX object src/arrow/CMakeFiles/arrow_objlib.dir/array/array_binary.cc.o
In file included from �[01m�[K/opt/rh/gcc-toolset-11/root/usr/include/c++/11/x86_64-redhat-linux/bits/os_defines.h:39�[m�[K,
                 from �[01m�[K/opt/rh/gcc-toolset-11/root/usr/include/c++/11/x86_64-redhat-linux/bits/c++config.h:2732�[m�[K,
                 from �[01m�[K/opt/rh/gcc-toolset-11/root/usr/include/c++/11/cstdint:38�[m�[K,
                 from �[01m�[K/home/jenkins-build/build/workspace/ceph-dev-new-build/ARCH/x86_64/AVAILABLE_ARCH/x86_64/AVAILABLE_DIST/centos8/DIST/centos8/MACHINE_SIZE/gigantic/release/18.0.0-6631-gcfbdc475/rpm/el8/BUILD/ceph-18.0.0-6631-gcfbdc475/src/arrow/cpp/src/arrow/array/array_binary.h:23�[m�[K,
                 from �[01m�[K/home/jenkins-build/build/workspace/ceph-dev-new-build/ARCH/x86_64/AVAILABLE_ARCH/x86_64/AVAILABLE_DIST/centos8/DIST/centos8/MACHINE_SIZE/gigantic/release/18.0.0-6631-gcfbdc475/rpm/el8/BUILD/ceph-18.0.0-6631-gcfbdc475/src/arrow/cpp/src/arrow/array/array_binary.cc:18�[m�[K:
�[01m�[K/usr/include/features.h:381:4:�[m�[K �[01;31m�[Kerror: �[m�[K#warning _FORTIFY_SOURCE requires compiling with optimization (-O) [�[01;31m�[K-Werror=cpp�[m�[K]
  381 | #  �[01;31m�[Kwarning�[m�[K _FORTIFY_SOURCE requires compiling with optimization (-O)
      |    �[01;31m�[K^~~~~~~�[m�[K
cc1plus: all warnings being treated as errors
make[5]: *** [src/arrow/CMakeFiles/arrow_objlib.dir/build.make:90: src/arrow/CMakeFiles/arrow_objlib.dir/array/array_binary.cc.o] Error 1
make[5]: *** Waiting for unfinished jobs....

cc @cbodley

Copy link
Contributor

@idryomov idryomov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is ready to go though.

Seems obviously correct to me! (I don't use this script)

@idryomov
Copy link
Contributor

idryomov commented Oct 6, 2023

jenkins test api

@cbodley
Copy link
Contributor

cbodley commented Oct 6, 2023

_FORTIFY_SOURCE requires compiling with optimization (-O)

our build is injecting this -D_FORTIFY_SOURCE=2 define, so we could remove that from these debug builds. another option is to always build arrow in release mode. in https://github.com/ceph/ceph/blob/080768f/cmake/modules/BuildArrow.cmake#L84-L88, our CMAKE_BUILD_TYPE gets forwarded to the arrow build, but we could leave that on Release instead

@batrick
Copy link
Member Author

batrick commented Oct 6, 2023

jenkins test api

@batrick
Copy link
Member Author

batrick commented Oct 6, 2023

_FORTIFY_SOURCE requires compiling with optimization (-O)

our build is injecting this -D_FORTIFY_SOURCE=2 define, so we could remove that from these debug builds. another option is to always build arrow in release mode. in https://github.com/ceph/ceph/blob/080768f/cmake/modules/BuildArrow.cmake#L84-L88, our CMAKE_BUILD_TYPE gets forwarded to the arrow build, but we could leave that on Release instead

https://tracker.ceph.com/issues/63130

@batrick batrick merged commit 617f715 into ceph:main Oct 7, 2023
10 of 11 checks passed
@batrick batrick deleted the ptl-tool-debug branch October 7, 2023 00:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants