You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@arrow.apache.org by "Karl Dunkle Werner (Jira)" <ji...@apache.org> on 2021/10/03 22:23:00 UTC
[jira] [Created] (ARROW-14210) [C++] CMAKE_AR is not passed to
bzip2 thirdparty dependency
Karl Dunkle Werner created ARROW-14210:
------------------------------------------
Summary: [C++] CMAKE_AR is not passed to bzip2 thirdparty dependency
Key: ARROW-14210
URL: https://issues.apache.org/jira/browse/ARROW-14210
Project: Apache Arrow
Issue Type: Bug
Components: C++
Affects Versions: 5.0.0
Reporter: Karl Dunkle Werner
It seems like the {{AR}} or {{CMAKE_AR}} variables aren't getting passed for the bzip2 build, which causes if to fail if we're doing a {{BUNDLED}} build and {{ar}} isn't available in the {{$PATH}} (e.g. in a conda environment).
To replicate:
1. Download Arrow and start an interactive shell in a container
(docker should be fine if you prefer it to podman)
{code:sh}
git clone --depth 1 git@github.com:apache/arrow.git
podman run -it --rm -v ./arrow:/arrow:Z docker://ursalab/amd64-ubuntu-18.04-conda-python-3.6:worker bash
{code}
2. Build Arrow by running this in in the container:
{code:sh}
export ARROW_BUILD_TOOLCHAIN=$CONDA_PREFIX
export ARROW_HOME=$CONDA_PREFIX
export PARQUET_HOME=$CONDA_PREFIX
cd /arrow
mkdir -p cpp/build
pushd cpp/build
cmake \
-DCMAKE_BUILD_TYPE=$ARROW_BUILD_TYPE \
-DCMAKE_INSTALL_PREFIX=$ARROW_HOME \
-DCMAKE_AR=${AR} \
-DCMAKE_RANLIB=${RANLIB} \
-DARROW_WITH_BZ2=ON \
-DARROW_VERBOSE_THIRDPARTY_BUILD=ON \
-DARROW_JEMALLOC=OFF \
-DARROW_SIMD_LEVEL=NONE -DARROW_RUNTIME_SIMD_LEVEL=NONE \
-DARROW_DEPENDENCY_SOURCE=BUNDLED \
..
make
# make[3]: ar: No such file or directory
# make[3]: *** [Makefile:48: libbz2.a] Error 127
# make[2]: *** [CMakeFiles/bzip2_ep.dir/build.make:135: bzip2_ep-prefix/src/bzip2_ep-stamp/bzip2_ep-build] Error 2
# make[1]: *** [CMakeFiles/Makefile2:726: CMakeFiles/bzip2_ep.dir/all] Error 2
{code}
In the cmake call above, {{ARROW_JEMALLOC}} and the SIMD flags are just to skip compiling irrelevant things.
I think this line in {{ThirdpartyToolchain.cmake}} needs to be changed to pass {{CMAKE_AR}}.
[https://github.com/apache/arrow/blob/bad8824d5cda0fd8337c7167729c49af868f93a5/cpp/cmake_modules/ThirdpartyToolchain.cmake#L2211]
Other related issues have also needed to pass {{CMAKE_RANLIB}}, in addition to {{CMAKE_AR}}. I'm not sure if that applies here.
Related: ARROW-4471, ARROW-4831
--
This message was sent by Atlassian Jira
(v8.3.4#803005)