diff --git a/thirdparty/abseil-cpp/HPKBUILD b/thirdparty/abseil-cpp/HPKBUILD new file mode 100644 index 0000000000000000000000000000000000000000..b1b0712aa2ae127ee9b910256e4013b0e76efeff --- /dev/null +++ b/thirdparty/abseil-cpp/HPKBUILD @@ -0,0 +1,49 @@ +# Contributor: liulihong +# Maintainer: liulihong +pkgname=abseil-cpp +pkgver=20230125.3 +pkgrel=0 +pkgdesc="The repository contains the Abseil C++ library code. Abseil is an open-source collection of C++ code (compliant to C++14) designed to augment the C++ standard library." +url="https://github.com/abseil/abseil-cpp" +archs=("armeabi-v7a" "arm64-v8a") +license=("Apache-2.0 license") +depends=() +makedepends=() + +source="https://github.com/abseil/$pkgname/archive/refs/tags/$pkgver.tar.gz" + +autounpack=true +downloadpackage=true + +builddir=$pkgname-$pkgver +packagename=$builddir.tar.gz + +prepare() { + mkdir -p $builddir/$ARCH-build +} + +build() { + cd $builddir + ${OHOS_SDK}/native/build-tools/cmake/bin/cmake "$@" -DABSL_ENABLE_INSTALL=ON -DABSL_BUILD_TESTING=ON \ + -DABSL_USE_GOOGLETEST_HEAD=ON -DOHOS_ARCH=$ARCH -B$ARCH-build -S./ -L > `pwd`/$ARCH-build/build.log 2>&1 + make VERBOSE=1 -j4 -C $ARCH-build >> `pwd`/$ARCH-build/build.log 2>&1 + ret=$? + cd $OLDPWD + return $ret +} + +package() { + cd $builddir + make -C $ARCH-build install >> `pwd`/$ARCH-build/build.log 2>&1 + cd $OLDPWD +} + +check() { + echo "The test must be on an OpenHarmony device!" + # 执行 ctest 测试 +} + +# 清理环境 +cleanbuild(){ + rm -rf ${PWD}/$builddir #${PWD}/$packagename +} diff --git a/thirdparty/abseil-cpp/SHA512SUM b/thirdparty/abseil-cpp/SHA512SUM new file mode 100644 index 0000000000000000000000000000000000000000..afd1ba432f5216fa76b5d2de884f72c5027660fe --- /dev/null +++ b/thirdparty/abseil-cpp/SHA512SUM @@ -0,0 +1 @@ +50509acfc4128fd31435631f71ac8cd0350acd9e290f78502723149016e7f07c9d84182ba99e0938b1873fecda09393d3fd7af8dabfb0d89cdcdd8a69a917e70 abseil-cpp-20230125.3.tar.gz