diff options
author | Pierre Schmitz | 2024-05-09 13:31:40 +0200 |
---|---|---|
committer | Pierre Schmitz | 2024-05-09 15:15:49 +0200 |
commit | 8f9b7f2b0410528127418d274708ccc23f19920c (patch) | |
tree | dcc5b0f503e143a59934eca1d2c3167c5d7b23f5 /PKGBUILD | |
download | aur-8f9b7f2b0410528127418d274708ccc23f19920c.tar.gz |
Initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..c5430722b47c --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,40 @@ +# Maintainer: Pierre Schmitz <pierre@archlinux.de> + +pkgname=proton-mail-export +pkgver=1.0.1 +pkgrel=1 +pkgdesc='Allows to export emails as eml files' +arch=('x86_64') +url='https://proton.me/support/proton-mail-export-tool' +license=('GPL-3.0-only') +depends=('gcc-libs' 'glibc') +makedepends=('git' 'cmake' 'clang' 'go' 'zip' 'unzip') +options=('!debug') +source=("git+https://github.com/ProtonMail/${pkgname}.git#tag=v${pkgver}") +sha256sums=('SKIP') + +prepare() { + cd "$pkgname" + git submodule update --init --recursive + # see https://github.com/ProtonMail/proton-mail-export/issues/4 + sed 's/^\s*execPath = etcpp::getExecutableDir();$/execPath = std::filesystem::current_path();/g' -i cli/bin/main.cpp +} + +build() { + cmake -B build -S "$pkgname" \ + -DCMAKE_BUILD_TYPE='None' \ + -DCMAKE_INSTALL_PREFIX='/usr' \ + -Wno-dev + cmake --build build +} + +check() { + ctest --test-dir build --output-on-failure +} + +package() { + DESTDIR="$pkgdir" cmake --install build + install -d -m 755 "$pkgdir/usr/lib" + mv "$pkgdir"/usr/bin/*.so "$pkgdir/usr/lib" + rm -rf "$pkgdir/usr/meta" +} |