This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/orc.git


The following commit(s) were added to refs/heads/main by this push:
     new 0d4597af1 ORC-1937: Use the default `buildtype` in Meson config
0d4597af1 is described below

commit 0d4597af1ae964cd7d7045b0923be6f1f8d1acde
Author: Will Ayd <[email protected]>
AuthorDate: Wed Jun 25 13:58:43 2025 -0700

    ORC-1937: Use the default `buildtype` in Meson config
    
    ### What changes were proposed in this pull request?
    This removes setting the Meson configuration to remove the buildtype of 
release by default.
    
    ### Why are the changes needed?
    While coming from CMake it may seem like a good idea to build release 
builds by default, the setting is either ignored or problematic when orc is 
used as a subproject in other projects, especially on Windows where a main 
project building a library with debug symbols may fail if a subproject tries to 
force release symbols.
    
    ### How was this patch tested?
    Compiled locally
    
    ### Was this patch authored or co-authored using generative AI tooling?
    No
    
    Closes #2298 from WillAyd/remove-meson-release-build.
    
    Authored-by: Will Ayd <[email protected]>
    Signed-off-by: Dongjoon Hyun <[email protected]>
---
 .github/workflows/build_and_test.yml | 2 +-
 README.md                            | 4 ++--
 meson.build                          | 1 -
 3 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/.github/workflows/build_and_test.yml 
b/.github/workflows/build_and_test.yml
index 1d3bdd17c..750dec550 100644
--- a/.github/workflows/build_and_test.yml
+++ b/.github/workflows/build_and_test.yml
@@ -252,6 +252,6 @@ jobs:
         pip install meson
     - name: Test
       run: |
-        meson setup build
+        meson setup build -Dbuildtype=release
         meson compile -C build
         meson test -C build
diff --git a/README.md b/README.md
index e23ccdb84..2ddf0849b 100644
--- a/README.md
+++ b/README.md
@@ -126,10 +126,10 @@ meson compile -C build
 meson test -C build
 ```
 
-By default, Meson will build release libraries. If you would instead like 
debug libraries, you can use the ``-Dbuildtype=debug`` argument to setup. You 
must either remove the existing build directory before changing that setting, 
or alternatively pass the ``--reconfigure`` flag:
+By default, Meson will build unoptimized libraries with debug symbols. By 
contrast, the CMake build system generates release libraries by default. If you 
would like to create release libraries ala CMake, you should set the buildtype 
option. You must either remove the existing build directory before changing 
that setting, or alternatively pass the ``--reconfigure`` flag:
 
 ```shell
-meson setup build -Dbuildtype=debug --reconfigure
+meson setup build -Dbuildtype=release --reconfigure
 meson compile -C build
 meson test -C build
 ```
diff --git a/meson.build b/meson.build
index 8ab3a0cd8..db23c300a 100644
--- a/meson.build
+++ b/meson.build
@@ -22,7 +22,6 @@ project(
     license: 'Apache-2.0',
     meson_version: '>=1.3.0',
     default_options: [
-        'buildtype=release',
         'warning_level=2',
         'cpp_std=c++17',
     ],

Reply via email to