Skip to content

ARROW-16168: [C++][CMake] Use target to add include paths - #12861

Closed
kou wants to merge 46 commits into
apache:masterfrom
kou:cpp-target-include-path
Closed

ARROW-16168: [C++][CMake] Use target to add include paths#12861
kou wants to merge 46 commits into
apache:masterfrom
kou:cpp-target-include-path

Conversation

@kou

@koukou commented Apr 12, 2022

Copy link
Copy Markdown
Member

We can remove "include_directories(SYSTEM)" by this.

@github-actions

Copy link
Copy Markdown

@kou

This comment was marked as outdated.

@github-actions

This comment was marked as outdated.

@kou

kou commented Apr 19, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit amazon* ubuntu-18.04ubuntu-20.04

@github-actions

This comment was marked as outdated.

@github-actions

This comment was marked as outdated.

@kou
kouforce-pushed the cpp-target-include-path branch from 1f48a2d to c7b478cCompareApril 20, 2022 00:14
@kou

kou commented Apr 20, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit ubuntu-18.04

@github-actions

This comment was marked as outdated.

@kou
kouforce-pushed the cpp-target-include-path branch from c7b478c to 10a4387CompareApril 23, 2022 22:08
@kou

kou commented Apr 23, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit verify-rc-source-cpp-linux-ubuntu-18.04-amd64

@github-actions

This comment was marked as outdated.

@kou

kou commented Apr 24, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit verify-rc-source-cpp-linux-ubuntu-*-amd64

@github-actions

This comment was marked as outdated.

@kou

kou commented Apr 25, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit -g nightly-tests -g nightly-packaging -g nightly-release

@github-actions

This comment was marked as outdated.

@pitrou

Copy link
Copy Markdown
Member

@kou Should this be updated for git master? Is there anything left to do otherwise?

@kou

kou commented May 4, 2022

Copy link
Copy Markdown
MemberAuthor

Should this be updated for git master?

Yes.

Is there anything left to do otherwise?

I need to confirm that the current failures are fixed by rebasing on the master. If there are unknown failures, I need to fix them in this pull request. (I prioritized 8.0.0 release related tasks over this.)

@kou
kouforce-pushed the cpp-target-include-path branch from 10a4387 to cfd32d1CompareMay 6, 2022 06:41
@kou

kou commented May 6, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit -g nightly-tests -g nightly-packaging -g nightly-release

@github-actions

This comment was marked as outdated.

@kou
kouforce-pushed the cpp-target-include-path branch from cfd32d1 to be18666CompareMay 7, 2022 20:48
@kou
kouforce-pushed the cpp-target-include-path branch from be18666 to b583fd7CompareMay 9, 2022 03:09
@kou

kou commented May 9, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit almalinux-8-amd64

@github-actions

This comment was marked as outdated.

@kou

kou commented May 9, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit almalinux-8-amd64 ubuntu-bionic-amd64 test-ubuntu-20.04-cpp-thread-sanitizer wheel-windows-cp310-amd64

@github-actions

This comment was marked as outdated.

@kou

kou commented May 9, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit -g nightly-tests -g nightly-packaging -g nightly-release

@github-actions

This comment was marked as outdated.

@kou

kou commented May 10, 2022

Copy link
Copy Markdown
MemberAuthor

This is ready to merge.
I'll merge this tomorrow if there is no objection.

Comment threadcpp/CMakeLists.txt
# Libraries to link statically with libarrow.so
set(ARROW_LINK_LIBS)
set(ARROW_STATIC_LINK_LIBS)
set(ARROW_LINK_LIBS arrow::flatbuffers arrow::hadoop)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, is arrow::hadoop enabled unconditionally??

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Because we build cpp/src/arrow/io_hdfs_internal.cc unconditionally.

Note that arrow::hadoop is a header only target that refers cpp/thirdparty/hadoop/include/.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. Can you add that last sentence as a comment?

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

Comment threadcpp/cmake_modules/BuildUtils.cmake
Comment threadcpp/CMakeLists.txt Outdated
set(ARROW_STATIC_LINK_LIBS arrow::flatbuffers arrow::hadoop)
set(ARROW_STATIC_INSTALL_INTERFACE_LIBS)

if(TARGET Boost::headers)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks a bit weird, shouldn't the condition be based on enabled Arrow components instead?

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. I'll use ARROW_BOOST_REQUIRED.

Comment threadcpp/CMakeLists.txt
elseif(ARG_SHARED_LIB)
set(AUG_LIB_NAME "${LIB_NAME}_shared")
add_library(${AUG_LIB_NAME} SHARED IMPORTED)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice simplification here!

set(BUILD_SHARED_LIBS ON)
else()
# Find static boost headers and libs
# TODO Differentiate here between release and debug builds

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you open a JIRA for this TODO?

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just copied from removed FindBoostAlt.cmake...
To be honest, I don't know what should be done by this TODO. We may be able to just remove this TODO.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, let's just remove it.

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

@pitrou

Copy link
Copy Markdown
Member

@kou Is the AppVeyor failure unrelated?

@kou

kou commented May 10, 2022

Copy link
Copy Markdown
MemberAuthor

@kou Is the AppVeyor failure unrelated?

Yes. It should be fixed by #13101 .

@kou

kou commented May 11, 2022

Copy link
Copy Markdown
MemberAuthor

@github-actions crossbow submit -g nightly-tests -g nightly-packaging -g nightly-release

@github-actions

Copy link
Copy Markdown

Revision: e643481

Submitted crossbow builds: ursacomputing/crossbow @ actions-2061

TaskStatus
almalinux-8-amd64Github Actions
almalinux-8-arm64TravisCI
amazon-linux-2-amd64Github Actions
centos-7-amd64Github Actions
centos-8-stream-amd64Github Actions
centos-8-stream-arm64TravisCI
conan-minimumGithub Actions
conda-cleanAzure
conda-linux-gcc-py310-arm64Azure
conda-linux-gcc-py310-cpuAzure
conda-linux-gcc-py310-cudaAzure
conda-linux-gcc-py310-ppc64leAzure
conda-linux-gcc-py37-arm64Azure
conda-linux-gcc-py37-cpu-r40Azure
conda-linux-gcc-py37-cpu-r41Azure
conda-linux-gcc-py37-cudaAzure
conda-linux-gcc-py37-ppc64leAzure
conda-linux-gcc-py38-arm64Azure
conda-linux-gcc-py38-cpuAzure
conda-linux-gcc-py38-cudaAzure
conda-linux-gcc-py38-ppc64leAzure
conda-linux-gcc-py39-arm64Azure
conda-linux-gcc-py39-cpuAzure
conda-linux-gcc-py39-cudaAzure
conda-linux-gcc-py39-ppc64leAzure
conda-osx-arm64-clang-py310Azure
conda-osx-arm64-clang-py38Azure
conda-osx-arm64-clang-py39Azure
conda-osx-clang-py310Azure
conda-osx-clang-py37-r40Azure
conda-osx-clang-py37-r41Azure
conda-osx-clang-py38Azure
conda-osx-clang-py39Azure
conda-win-vs2017-py310Azure
conda-win-vs2017-py37-r40Azure
conda-win-vs2017-py37-r41Azure
conda-win-vs2017-py38Azure
conda-win-vs2017-py39Azure
debian-bookworm-amd64Github Actions
debian-bookworm-arm64TravisCI
debian-bullseye-amd64Github Actions
debian-bullseye-arm64TravisCI
debian-buster-amd64Github Actions
debian-buster-arm64TravisCI
example-cpp-minimal-build-staticGithub Actions
example-cpp-minimal-build-static-system-dependencyGithub Actions
homebrew-cppGithub Actions
homebrew-r-autobrewGithub Actions
homebrew-r-brewGithub Actions
java-jarsGithub Actions
nugetGithub Actions
python-sdistGithub Actions
test-build-cpp-fuzzGithub Actions
test-build-vcpkg-winGithub Actions
test-conda-cppGithub Actions
test-conda-cpp-valgrindAzure
test-conda-python-3.10Github Actions
test-conda-python-3.7Github Actions
test-conda-python-3.7-hdfs-2.9.2Github Actions
test-conda-python-3.7-hdfs-3.2.1Github Actions
test-conda-python-3.7-kartothek-latestGithub Actions
test-conda-python-3.7-kartothek-masterGithub Actions
test-conda-python-3.7-pandas-0.24Github Actions
test-conda-python-3.7-pandas-latestGithub Actions
test-conda-python-3.7-spark-v3.1.2Github Actions
test-conda-python-3.8Github Actions
test-conda-python-3.8-hypothesisGithub Actions
test-conda-python-3.8-pandas-latestGithub Actions
test-conda-python-3.8-pandas-nightlyGithub Actions
test-conda-python-3.8-spark-v3.2.0Github Actions
test-conda-python-3.9Github Actions
test-conda-python-3.9-dask-latestGithub Actions
test-conda-python-3.9-dask-masterGithub Actions
test-conda-python-3.9-pandas-masterGithub Actions
test-conda-python-3.9-spark-masterGithub Actions
test-debian-10-cpp-amd64Github Actions
test-debian-10-cpp-i386Github Actions
test-debian-11-cpp-amd64Github Actions
test-debian-11-cpp-i386Github Actions
test-debian-11-go-1.16Azure
test-debian-11-python-3Azure
test-debian-c-glibGithub Actions
test-debian-rubyGithub Actions
test-fedora-35-cppGithub Actions
test-fedora-35-python-3Azure
test-fedora-r-clang-sanitizerAzure
test-r-arrow-backwards-compatibilityGithub Actions
test-r-depsource-bundledAzure
test-r-depsource-systemGithub Actions
test-r-dev-duckdbGithub Actions
test-r-devdocsGithub Actions
test-r-gcc-11Github Actions
test-r-gcc-12Github Actions
test-r-install-localGithub Actions
test-r-linux-as-cranGithub Actions
test-r-linux-rchkGithub Actions
test-r-linux-valgrindAzure
test-r-minimal-buildAzure
test-r-offline-maximalGithub Actions
test-r-offline-minimalAzure
test-r-rhub-debian-gcc-devel-lto-latestAzure
test-r-rhub-debian-gcc-release-custom-ccacheAzure
test-r-rhub-ubuntu-gcc-release-latestAzure
test-r-rocker-r-base-latestAzure
test-r-rstudio-r-base-4.1-centos7-devtoolset-8Azure
test-r-rstudio-r-base-4.1-focalAzure
test-r-rstudio-r-base-4.1-opensuse15Azure
test-r-rstudio-r-base-4.1-opensuse42Azure
test-r-ubuntu-22.04Github Actions
test-r-versionsGithub Actions
test-skyhook-integrationGithub Actions
test-ubuntu-18.04-cppGithub Actions
test-ubuntu-18.04-cpp-releaseGithub Actions
test-ubuntu-18.04-cpp-staticGithub Actions
test-ubuntu-18.04-r-sanitizerAzure
test-ubuntu-20.04-cppGithub Actions
test-ubuntu-20.04-cpp-14Github Actions
test-ubuntu-20.04-cpp-17Github Actions
test-ubuntu-20.04-cpp-bundledGithub Actions
test-ubuntu-20.04-cpp-thread-sanitizerGithub Actions
test-ubuntu-20.04-python-3Azure
test-ubuntu-22.04-cppGithub Actions
test-ubuntu-c-glibGithub Actions
test-ubuntu-default-docsAzure
test-ubuntu-rubyGithub Actions
ubuntu-bionic-amd64Github Actions
ubuntu-bionic-arm64TravisCI
ubuntu-focal-amd64Github Actions
ubuntu-focal-arm64TravisCI
ubuntu-impish-amd64Github Actions
ubuntu-impish-arm64TravisCI
ubuntu-jammy-amd64Github Actions
ubuntu-jammy-arm64TravisCI
verify-rc-source-cpp-linux-almalinux-8-amd64Github Actions
verify-rc-source-cpp-linux-conda-latest-amd64Github Actions
verify-rc-source-cpp-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-cpp-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-cpp-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-cpp-macos-amd64Github Actions
verify-rc-source-cpp-macos-arm64Github Actions
verify-rc-source-cpp-macos-conda-amd64Github Actions
verify-rc-source-csharp-linux-almalinux-8-amd64Github Actions
verify-rc-source-csharp-linux-conda-latest-amd64Github Actions
verify-rc-source-csharp-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-csharp-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-csharp-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-csharp-macos-amd64Github Actions
verify-rc-source-csharp-macos-arm64Github Actions
verify-rc-source-go-linux-almalinux-8-amd64Github Actions
verify-rc-source-go-linux-conda-latest-amd64Github Actions
verify-rc-source-go-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-go-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-go-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-go-macos-amd64Github Actions
verify-rc-source-go-macos-arm64Github Actions
verify-rc-source-integration-linux-almalinux-8-amd64Github Actions
verify-rc-source-integration-linux-conda-latest-amd64Github Actions
verify-rc-source-integration-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-integration-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-integration-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-integration-macos-amd64Github Actions
verify-rc-source-integration-macos-arm64Github Actions
verify-rc-source-integration-macos-conda-amd64Github Actions
verify-rc-source-java-linux-almalinux-8-amd64Github Actions
verify-rc-source-java-linux-conda-latest-amd64Github Actions
verify-rc-source-java-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-java-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-java-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-java-macos-amd64Github Actions
verify-rc-source-js-linux-almalinux-8-amd64Github Actions
verify-rc-source-js-linux-conda-latest-amd64Github Actions
verify-rc-source-js-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-js-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-js-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-js-macos-amd64Github Actions
verify-rc-source-js-macos-arm64Github Actions
verify-rc-source-python-linux-almalinux-8-amd64Github Actions
verify-rc-source-python-linux-conda-latest-amd64Github Actions
verify-rc-source-python-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-python-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-python-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-python-macos-amd64Github Actions
verify-rc-source-python-macos-arm64Github Actions
verify-rc-source-python-macos-conda-amd64Github Actions
verify-rc-source-ruby-linux-almalinux-8-amd64Github Actions
verify-rc-source-ruby-linux-conda-latest-amd64Github Actions
verify-rc-source-ruby-linux-ubuntu-18.04-amd64Github Actions
verify-rc-source-ruby-linux-ubuntu-20.04-amd64Github Actions
verify-rc-source-ruby-linux-ubuntu-22.04-amd64Github Actions
verify-rc-source-ruby-macos-amd64Github Actions
verify-rc-source-ruby-macos-arm64Github Actions
verify-rc-source-windowsGithub Actions
wheel-macos-big-sur-cp310-arm64Github Actions
wheel-macos-big-sur-cp310-universal2Github Actions
wheel-macos-big-sur-cp38-arm64Github Actions
wheel-macos-big-sur-cp39-arm64Github Actions
wheel-macos-big-sur-cp39-universal2Github Actions
wheel-macos-high-sierra-cp310-amd64Github Actions
wheel-macos-high-sierra-cp37-amd64Github Actions
wheel-macos-high-sierra-cp38-amd64Github Actions
wheel-macos-high-sierra-cp39-amd64Github Actions
wheel-macos-mavericks-cp310-amd64Github Actions
wheel-macos-mavericks-cp37-amd64Github Actions
wheel-macos-mavericks-cp38-amd64Github Actions
wheel-macos-mavericks-cp39-amd64Github Actions
wheel-manylinux2010-cp310-amd64Github Actions
wheel-manylinux2010-cp37-amd64Github Actions
wheel-manylinux2010-cp38-amd64Github Actions
wheel-manylinux2010-cp39-amd64Github Actions
wheel-manylinux2014-cp310-amd64Github Actions
wheel-manylinux2014-cp310-arm64TravisCI
wheel-manylinux2014-cp37-amd64Github Actions
wheel-manylinux2014-cp37-arm64TravisCI
wheel-manylinux2014-cp38-amd64Github Actions
wheel-manylinux2014-cp38-arm64TravisCI
wheel-manylinux2014-cp39-amd64Github Actions
wheel-manylinux2014-cp39-arm64TravisCI
wheel-windows-cp310-amd64Github Actions
wheel-windows-cp37-amd64Github Actions
wheel-windows-cp38-amd64Github Actions
wheel-windows-cp39-amd64Github Actions

@kou

kou commented May 11, 2022

Copy link
Copy Markdown
MemberAuthor

+1

@koukou closed this in d653b71May 11, 2022
@kou
kou deleted the cpp-target-include-path branch May 11, 2022 20:24
@ursabot

Copy link
Copy Markdown

Benchmark runs are scheduled for baseline = bb190bb and contender = d653b71. d653b71 is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
Conbench compare runs links:
[Finished ⬇️0.0% ⬆️0.0%] ec2-t3-xlarge-us-east-2
[Failed ⬇️0.31% ⬆️0.0%] test-mac-arm
[Finished ⬇️0.0% ⬆️0.36%] ursa-i9-9960x
[Finished ⬇️1.14% ⬆️0.08%] ursa-thinkcentre-m75q
Buildkite builds:
[Finished] d653b71d ec2-t3-xlarge-us-east-2
[Finished] d653b71d test-mac-arm
[Finished] d653b71d ursa-i9-9960x
[Finished] d653b71d ursa-thinkcentre-m75q
[Finished] bb190bbc ec2-t3-xlarge-us-east-2
[Failed] bb190bbc test-mac-arm
[Finished] bb190bbc ursa-i9-9960x
[Finished] bb190bbc ursa-thinkcentre-m75q
Supported benchmarks:
ec2-t3-xlarge-us-east-2: Supported benchmark langs: Python, R. Runs only benchmarks with cloud = True
test-mac-arm: Supported benchmark langs: C++, Python, R
ursa-i9-9960x: Supported benchmark langs: Python, R, JavaScript
ursa-thinkcentre-m75q: Supported benchmark langs: C++, Java

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@kou@pitrou@ursabot@cyb70289