pitrou commented on code in PR #35924:
URL: https://github.com/apache/arrow/pull/35924#discussion_r1234963665
##########
docs/source/developers/cpp/building.rst:
##########
@@ -254,6 +254,34 @@ Several build types are possible:
* ``Release``: applies compiler optimizations and removes debug information
from the binary.
+.. note::
+
+ These built types provide suitable optimization/debug flags by
+ default but you can change them by specifying
+ ``-DARROW_C_FLAGS_${BUILD_TYPE}=...`` and/or
+ ``-DARROW_CXX_FLAGS_${BUILD_TYPE}=...``. ``${BUILD_TYPE}`` is upper
+ case of build type. For example, ``DEBUG``
+ (``-DARROW_C_FLAGS_DEBUG=...`` / ``-DARROW_CXX_FLAGS_DEBUG=...``) for the
+ ``Debug`` build type and ``RELWITHDEBINFO``
+ (``-DARROW_C_FLAGS_RELWITHDEBINFO=...`` /
+ ``-DARROW_CXX_FLAGS_RELWITHDEBINFO=...``) for the ``RelWithDebInfo``
+ build type.
+
+ For example, you can use ``-O3`` as an optimization flag by
+ specifying ``-DARROW_CXX_FLAGS_RELEASE=-O3`` for the ``Release``
+ build type. You can use ``-g3`` as a debug flag by specifying
+ ``-DARROW_CXX_FLAGS_DEBUG=-g3`` for the ``Debug`` build type.
+
+ You can also use the standard ``-DCMAKE_C_FLAGS_${BUILD_TYPE}=...``
+ and ``-DCMAKE_CXX_FLAGS_${BUILD_TYPE}=...`` style but
Review Comment:
```suggestion
You can also use the standard ``CMAKE_C_FLAGS_${BUILD_TYPE}``
and ``CMAKE_CXX_FLAGS_${BUILD_TYPE}`` variables but
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]