summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Zaman <perfinion@gentoo.org>2022-02-27 10:48:48 -0800
committerJason Zaman <perfinion@gentoo.org>2022-02-27 16:40:47 -0800
commit353bb85d92306ade2372aa79c43bef0b3d876b9b (patch)
tree93007dba17862862534716286fc86f34a061f996 /net-libs/google-cloud-cpp
parentapp-i18n/librime: Stabilize 1.7.3-r1 ppc, #793926 (diff)
downloadgentoo-353bb85d92306ade2372aa79c43bef0b3d876b9b.tar.gz
gentoo-353bb85d92306ade2372aa79c43bef0b3d876b9b.tar.bz2
gentoo-353bb85d92306ade2372aa79c43bef0b3d876b9b.zip
net-libs/google-cloud-cpp: port to cmake.eclass
Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Jason Zaman <perfinion@gentoo.org>
Diffstat (limited to 'net-libs/google-cloud-cpp')
-rw-r--r--net-libs/google-cloud-cpp/google-cloud-cpp-0.10.0-r2.ebuild61
1 files changed, 61 insertions, 0 deletions
diff --git a/net-libs/google-cloud-cpp/google-cloud-cpp-0.10.0-r2.ebuild b/net-libs/google-cloud-cpp/google-cloud-cpp-0.10.0-r2.ebuild
new file mode 100644
index 000000000000..b441242910a4
--- /dev/null
+++ b/net-libs/google-cloud-cpp/google-cloud-cpp-0.10.0-r2.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR=emake
+inherit cmake
+
+JSON_VER="3.4.0"
+GOOGLEAPIS_COMMIT="6a3277c0656219174ff7c345f31fb20a90b30b97"
+
+DESCRIPTION="Google Cloud Client Library for C++"
+HOMEPAGE="https://cloud.google.com/"
+SRC_URI="https://github.com/GoogleCloudPlatform/google-cloud-cpp/archive/v${PV}.tar.gz -> ${P}.tar.gz
+ https://github.com/nlohmann/json/releases/download/v${JSON_VER}/json.hpp -> nlohmann-json-${JSON_VER}-json.hpp
+ https://github.com/googleapis/googleapis/archive/${GOOGLEAPIS_COMMIT}.tar.gz -> googleapis-${GOOGLEAPIS_COMMIT}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RESTRICT="test"
+RDEPEND="dev-libs/protobuf:=
+ dev-libs/crc32c
+ dev-libs/openssl:=
+ net-misc/curl
+ net-libs/grpc:="
+DEPEND="${RDEPEND}
+ dev-cpp/gtest"
+
+DOCS=( README.md )
+PATCHES=(
+ "${FILESDIR}/google-cloud-cpp-0.9.0-offline_nlohmannjson.patch"
+)
+
+src_configure() {
+ local mycmakeargs=(
+ -DGOOGLE_CLOUD_CPP_DEPENDENCY_PROVIDER=package
+ -DBUILD_TESTING=OFF
+ -DCMAKE_CXX_STANDARD=17
+ )
+
+ cmake_src_configure
+
+ mkdir -p "${BUILD_DIR}/external/nlohmann_json/src/" || die
+ cp "${DISTDIR}/nlohmann-json-${JSON_VER}-json.hpp" "${BUILD_DIR}/external/nlohmann_json/src/json.hpp" || die
+
+ mkdir -p "${BUILD_DIR}/external/googleapis/src/" || die
+ cp "${DISTDIR}/googleapis-${GOOGLEAPIS_COMMIT}.tar.gz" \
+ "${BUILD_DIR}/external/googleapis/src/${GOOGLEAPIS_COMMIT}.tar.gz" || die
+}
+
+src_test() {
+ # test fails
+ local myctestargs=(
+ -E internal_parse_rfc3339_test
+ )
+
+ cmake_src_test
+}