Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ci/scripts/python_build.sh
Original file line numberDiff line numberDiff line change
Expand Up@@ -89,7 +89,7 @@ cp -aL "${source_dir}" "${python_build_dir}"
pushd "${python_build_dir}"
# - Cannot use build isolation as we want to use specific dependency versions
# (e.g. Numpy, Pandas) on some CI jobs.
${PYTHON:-python} -m pip install --no-deps --no-build-isolation -vv -C cmake.build-type="${CMAKE_BUILD_TYPE:-Debug}" .
time ${PYTHON:-python} -m pip install --no-deps --no-build-isolation -vv -C cmake.build-type="${CMAKE_BUILD_TYPE:-Debug}" .
popd

if [ "${BUILD_DOCS_PYTHON}" == "ON" ]; then
Expand Down
17 changes: 12 additions & 5 deletions python/CMakeLists.txt
Original file line numberDiff line numberDiff line change
Expand Up@@ -130,11 +130,18 @@ if(CCACHE_FOUND
AND NOT CMAKE_C_COMPILER_LAUNCHER
AND NOT CMAKE_CXX_COMPILER_LAUNCHER)
message(STATUS "Using ccache: ${CCACHE_FOUND}")
set(CMAKE_C_COMPILER_LAUNCHER ${CCACHE_FOUND})
set(CMAKE_CXX_COMPILER_LAUNCHER ${CCACHE_FOUND})
# ARROW-3985: let ccache preserve C++ comments, because some of them may be
# meaningful to the compiler
set(ENV{CCACHE_COMMENTS} "1")
# 1. Let ccache preserve C++ comments, because some of them may be
# meaningful to the compiler (ARROW-3985)
# 2. Set ccache base_dir to the build output directory as it is typically
# a temporary directory, and would otherwise fail caching because of
# using different paths everytime.
# Also, we use `cmake -E env` to set environment variables as the
# `ccache option=value ...` form of passing configuration options
# is not supported by ccache < 4.8.
set(ccache_command ${CMAKE_COMMAND} -E env CCACHE_COMMENTS=1
CCACHE_BASEDIR=${CMAKE_BINARY_DIR} -- ${CCACHE_FOUND})
set(CMAKE_C_COMPILER_LAUNCHER ${ccache_command})
set(CMAKE_CXX_COMPILER_LAUNCHER ${ccache_command})
endif()

#
Expand Down
Loading