Skip to content

Commit

Permalink
Remove redundant calls to set_property("cmake_target_name")
Browse files Browse the repository at this point in the history
  • Loading branch information
robomics committed May 29, 2024
1 parent a42790d commit fc113f0
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions recipes/arrow/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,6 @@ def package_info(self):
cmake_suffix = "shared" if self.options.shared else "static"

self.cpp_info.components["libarrow"].set_property("pkg_config_name", "arrow")
self.cpp_info.components["libarrow"].set_property("cmake_target_name", f"Arrow::arrow_{cmake_suffix}")
self.cpp_info.components["libarrow"].libs = [f"arrow{suffix}"]
if not self.options.shared:
self.cpp_info.components["libarrow"].defines = ["ARROW_STATIC"]
Expand All @@ -441,46 +440,41 @@ def package_info(self):

if self.options.parquet:
self.cpp_info.components["libparquet"].set_property("pkg_config_name", "parquet")
self.cpp_info.components["libparquet"].set_property("cmake_target_name", f"Parquet::parquet_{cmake_suffix}")
self.cpp_info.components["libparquet"].libs = [f"parquet{suffix}"]
self.cpp_info.components["libparquet"].requires = ["libarrow"]
if not self.options.shared:
self.cpp_info.components["libparquet"].defines = ["PARQUET_STATIC"]

if self.options.get_safe("substrait"):
self.cpp_info.components["libarrow_substrait"].set_property("pkg_config_name", "arrow_substrait")
self.cpp_info.components["libarrow_substrait"].set_property("cmake_target_name", f"Arrow::arrow_substrait_{cmake_suffix}")
self.cpp_info.components["libarrow_substrait"].libs = [f"arrow_substrait{suffix}"]
self.cpp_info.components["libarrow_substrait"].requires = ["libparquet", "dataset"]

# Plasma was deprecated in Arrow 12.0.0
del self.options.plasma

if self.options.acero:
self.cpp_info.components["libacero"].set_property("pkg_config_name", "acero")
self.cpp_info.components["libacero"].libs = [f"arrow_acero{suffix}"]
self.cpp_info.components["libacero"].set_property("cmake_target_name", f"Acero::arrow_acero_{cmake_suffix}")
self.cpp_info.components["libacero"].names["cmake_find_package"] = "acero"
self.cpp_info.components["libacero"].names["cmake_find_package_multi"] = "acero"
self.cpp_info.components["libacero"].names["pkg_config"] = "acero"
self.cpp_info.components["libacero"].requires = ["libarrow"]

if self.options.gandiva:
self.cpp_info.components["libgandiva"].set_property("pkg_config_name", "gandiva")
self.cpp_info.components["libgandiva"].set_property("cmake_target_name", f"Gandiva::gandiva_{cmake_suffix}")
self.cpp_info.components["libgandiva"].libs = [f"gandiva{suffix}"]
self.cpp_info.components["libgandiva"].requires = ["libarrow"]
if not self.options.shared:
self.cpp_info.components["libgandiva"].defines = ["GANDIVA_STATIC"]

if self.options.with_flight_rpc:
self.cpp_info.components["libarrow_flight"].set_property("pkg_config_name", "flight_rpc")
self.cpp_info.components["libarrow_flight"].set_property("cmake_target_name", f"ArrowFlight::arrow_flight_{cmake_suffix}")
self.cpp_info.components["libarrow_flight"].libs = [f"arrow_flight{suffix}"]
self.cpp_info.components["libarrow_flight"].requires = ["libarrow"]

if self.options.get_safe("with_flight_sql"):
self.cpp_info.components["libarrow_flight_sql"].set_property("pkg_config_name", "flight_sql")
self.cpp_info.components["libarrow_flight_sql"].set_property("cmake_target_name", f"ArrowFlightSql::arrow_flight_sql_{cmake_suffix}")
self.cpp_info.components["libarrow_flight_sql"].libs = [f"arrow_flight_sql{suffix}"]
self.cpp_info.components["libarrow_flight_sql"].requires = ["libarrow", "libarrow_flight"]

Expand Down

0 comments on commit fc113f0

Please sign in to comment.