From 9a3b2fbbc5117a4a20c8ee274bfee9240ff265ac Mon Sep 17 00:00:00 2001 From: delphi Date: Thu, 4 Jun 2020 21:28:47 +0300 Subject: [PATCH] testing/cryfs: new aport Signed-off-by: delphi --- testing/cryfs/0001-fix-for-python3.patch | 22 +++++++++++ testing/cryfs/APKBUILD | 49 ++++++++++++++++++++++++ 2 files changed, 71 insertions(+) create mode 100644 testing/cryfs/0001-fix-for-python3.patch create mode 100644 testing/cryfs/APKBUILD diff --git a/testing/cryfs/0001-fix-for-python3.patch b/testing/cryfs/0001-fix-for-python3.patch new file mode 100644 index 00000000000..2629a4691a7 --- /dev/null +++ b/testing/cryfs/0001-fix-for-python3.patch @@ -0,0 +1,22 @@ +Upstream: No +Reason: Fix default python version for this script + +--- a/src/gitversion/getversion.py 2020-06-05 00:07:29.206108295 +0300 ++++ b/src/gitversion/getversion.py 2020-06-05 00:07:48.846126599 +0300 +@@ -1,4 +1,4 @@ +-#!/usr/bin/env python ++#!/usr/bin/env python3 + + import versioneer + +--- a/src/gitversion/gitversion.cmake 2020-06-05 00:39:47.862225137 +0300 ++++ b/src/gitversion/gitversion.cmake 2020-06-05 00:40:18.162282012 +0300 +@@ -1,7 +1,7 @@ + set(DIR_OF_GITVERSION_TOOL "${CMAKE_CURRENT_LIST_DIR}" CACHE INTERNAL "DIR_OF_GITVERSION_TOOL") + + function (get_git_version OUTPUT_VARIABLE) +- EXECUTE_PROCESS(COMMAND python ${DIR_OF_GITVERSION_TOOL}/getversion.py ++ EXECUTE_PROCESS(COMMAND python3 ${DIR_OF_GITVERSION_TOOL}/getversion.py + WORKING_DIRECTORY ${DIR_OF_GITVERSION_TOOL} + OUTPUT_VARIABLE VERSION + ERROR_VARIABLE error diff --git a/testing/cryfs/APKBUILD b/testing/cryfs/APKBUILD new file mode 100644 index 00000000000..ed7e37ff8a9 --- /dev/null +++ b/testing/cryfs/APKBUILD @@ -0,0 +1,49 @@ +# Contributor: Pavel Pletenev +# Maintainer: Pavel Pletenev +pkgname=cryfs +pkgver=0.10.2 +pkgrel=0 +pkgdesc="Cryptographic filesystem for the cloud" +url="https://github.com/cryfs/cryfs" +# Fails on other arches +arch="x86_64 aarch64" +license="LGPL-3.0-only" +depends="fuse" +makedepends="cmake attr-dev curl-dev fuse-dev linux-headers + boost-dev python3" +source="$pkgname-$pkgver.tar.gz::https://github.com/cryfs/cryfs/archive/$pkgver.tar.gz + 0001-fix-for-python3.patch" + +prepare() { + default_prepare + echo "$pkgver" > VERSION +} + +build() { + if [ "$CBUILD" != "$CHOST" ]; then + CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux" + fi + export GIT_CEILING_DIRECTORIES="$srcdir" + cmake -B build \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DBUILD_TESTING=ON \ + -DBoost_USE_STATIC_LIBS=OFF \ + $CMAKE_CROSSOPTS . + make -C build -j1 +} + +check() { + ./build/test/gitversion/gitversion-test + ./build/test/cpp-utils/cpp-utils-test + ./build/test/parallelaccessstore/parallelaccessstore-test + ./build/test/blockstore/blockstore-test + ./build/test/blobstore/blobstore-test + ./build/test/cryfs/cryfs-test +} + +package() { + make -C build PREFIX=/usr DESTDIR="$pkgdir" install +} + +sha512sums="e9bd890eacbd60cef402fdfb3389eaf394c8e762a550563d720ede9badbea0fabebe14879f8d26e8e621ff635800d6901c67f99a52101d7c0c63499942694306 cryfs-0.10.2.tar.gz +d299466c8cfaa0f1f75565756d95a12cd7fa94615f0292f31ad0494dc8a0aae35c22fbab023d7e183b95e877c58553a0c8f8ab1f7444df1f9d1b292c063edfb0 0001-fix-for-python3.patch"