Skip to content

Commit

Permalink
fix install + cpp_info system_libs and name
Browse files Browse the repository at this point in the history
Co-Authored-By: Uilian Ries <uilianries@gmail.com>
  • Loading branch information
SpaceIm and uilianries committed Feb 20, 2020
1 parent 6c01c01 commit 3abb616
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 17 deletions.
2 changes: 1 addition & 1 deletion recipes/c-blosc/all/conandata.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ sources:
sha256: "19a6948b579c27e8ac440b4f077f99fc90e7292b1d9cb896bec0fd781d68fba2"
patches:
"1.17.1":
- patch_file: "patches/cmake-dependencies_and_install.patch"
- patch_file: "patches/cmake-dependencies_and_cxx_linker.patch"
base_path: "source_subfolder"
6 changes: 3 additions & 3 deletions recipes/c-blosc/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def _configure_cmake(self):
if self._cmake:
return self._cmake
self._cmake = CMake(self)
self._cmake.definitions["BLOSC_INSTALL"] = True
self._cmake.definitions["BUILD_STATIC"] = not self.options.shared
self._cmake.definitions["BUILD_SHARED"] = self.options.shared
self._cmake.definitions["BUILD_TESTS"] = False
Expand All @@ -99,10 +100,9 @@ def package(self):
self.copy(license_file, dst="licenses", src=os.path.join(self._source_subfolder, "LICENSES"))
cmake = self._configure_cmake()
cmake.install()
tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig"))

def package_info(self):
self.cpp_info.libs = tools.collect_libs(self)
if self.settings.os == "Linux":
self.cpp_info.libs.append("pthread")
self.cpp_info.names["cmake_find_package"] = "Blosc"
self.cpp_info.names["cmake_find_package_multi"] = "Blosc"
self.cpp_info.system_libs.append("pthread")
Original file line number Diff line number Diff line change
Expand Up @@ -153,16 +153,3 @@
target_include_directories(blosc_shared PUBLIC ${BLOSC_INCLUDE_DIRS})
endif()

@@ -212,7 +157,6 @@ if(BUILD_STATIC)
endif(BUILD_STATIC)

# install
-if(BLOSC_INSTALL)
install(FILES blosc.h blosc-export.h DESTINATION include COMPONENT DEV)
if(BUILD_SHARED)
install(TARGETS blosc_shared LIBRARY DESTINATION ${lib_dir} ARCHIVE DESTINATION ${lib_dir} RUNTIME DESTINATION bin COMPONENT LIB)
@@ -220,4 +164,3 @@ if(BLOSC_INSTALL)
if(BUILD_STATIC)
install(TARGETS blosc_static LIBRARY DESTINATION ${lib_dir} ARCHIVE DESTINATION ${lib_dir} RUNTIME DESTINATION bin COMPONENT DEV)
endif(BUILD_STATIC)
-endif(BLOSC_INSTALL)

0 comments on commit 3abb616

Please sign in to comment.