[
https://issues.apache.org/jira/browse/ARROW-4407?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16755200#comment-16755200
]
Wes McKinney commented on ARROW-4407:
-------------------------------------
While it's a good idea to fix this particular issue, I think we should be
careful about spending very much time on having the CMake build preserve the
environment of where it was first invoked. Instead, we should encourage
developers to keep their environment variables consistent (through the use of
files that are sourced on each shell initialization, here is mine:
https://github.com/wesm/dev-toolchain/blob/master/toolchain/arrow-toolchain.sh)
while they are developing
> [C++] ExternalProject_Add does not capture CC/CXX correctly
> -----------------------------------------------------------
>
> Key: ARROW-4407
> URL: https://issues.apache.org/jira/browse/ARROW-4407
> Project: Apache Arrow
> Issue Type: Bug
> Components: C++
> Affects Versions: 0.12.0
> Reporter: Francois Saint-Jacques
> Assignee: Francois Saint-Jacques
> Priority: Minor
> Labels: pull-request-available
> Fix For: 0.13.0
>
> Time Spent: 40m
> Remaining Estimate: 0h
>
> The issue is that CC/CXX environment variables are captured on the first
> invocation of the builder (e.g make or ninja) instead of when CMake is
> invoked into to build directory. This can lead to compilation errors (notably
> when compiling with clang in the top directory due to the addition of the
> `-Qunused-arguments` option).
> This leads to an issue where I have a script that prepare the build directory
> and export CXX within the script. When I jump in the build folder, there's a
> mismatch between the external gbenchmark (and all deps if conda is not used)
> compiler and the build.
> To reproduce:
> # Create a new build directory with clang as compiler, don't build yet
> # In a new shell (without the compiler environment variable), go into
> directory invoke make/ninja
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)