Skip to content

build: temporarily map Release builds to RelWithDebInfo#234

Open
plexoos wants to merge 2 commits intomainfrom
build-rel-deb
Open

build: temporarily map Release builds to RelWithDebInfo#234
plexoos wants to merge 2 commits intomainfrom
build-rel-deb

Conversation

@plexoos
Copy link
Member

@plexoos plexoos commented Mar 16, 2026

No description provided.

Copilot AI review requested due to automatic review settings March 16, 2026 21:36
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the top-level CMake configuration for eic-opticks to adjust how CMAKE_BUILD_TYPE is set, aiming to prefer a debuggable optimized configuration.

Changes:

  • Adds logic that forces CMAKE_BUILD_TYPE from Release to RelWithDebInfo under certain conditions.
  • Keeps the existing defaulting of CMAKE_BUILD_TYPE to Debug when unset for single-config generators.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment on lines 9 to +16
# Default CMAKE_BUILD_TYPE=Debug for single-config generators (Ninja/Makefiles) when not specified
if(NOT CMAKE_CONFIGURATION_TYPES AND NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Debug CACHE STRING "Build type")
else()
# Temp fix: Force RelWithDebInfo even if user specified Release
if(CMAKE_BUILD_TYPE STREQUAL "Release")
set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Build type" FORCE)
endif()
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0ecd361bb8

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

else()
# Temp fix: Force RelWithDebInfo even if user specified Release
if(CMAKE_BUILD_TYPE STREQUAL "Release")
set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Build type" FORCE)

Choose a reason for hiding this comment

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

P1 Badge Preserve PRODUCTION define when remapping Release

For single-config builds where users request -DCMAKE_BUILD_TYPE=Release, this forces RelWithDebInfo, which means $<$<CONFIG:Release>:PRODUCTION> in sysrap/CMakeLists.txt no longer applies and the code is compiled through many #ifndef PRODUCTION debug/non-production paths. That changes runtime behavior (not just symbol/debug info) for what callers explicitly asked to be a Release build, which can impact performance and experiment behavior.

Useful? React with 👍 / 👎.

@plexoos plexoos requested a review from ggalgoczi March 16, 2026 21:53
@plexoos plexoos self-assigned this Mar 16, 2026
plexoos and others added 2 commits March 17, 2026 11:39
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants