checks-parser-git done, checks-parser-bin WIP
This commit is contained in:
28
deploy/archlinux/bin/Dockerfile
Normal file
28
deploy/archlinux/bin/Dockerfile
Normal file
@@ -0,0 +1,28 @@
|
||||
FROM archlinux:latest
|
||||
|
||||
ARG pkgname=$name
|
||||
ARG pkgver=$version
|
||||
ARG revision
|
||||
|
||||
RUN mkdir -p /output
|
||||
|
||||
RUN pacman --noconfirm -Syu base base-devel sudo
|
||||
RUN echo "sudo cp ${pkgname}-bin-${pkgver}-$revision-x86_64.pkg.tar.zst /output" > /deploy.sh
|
||||
RUN chmod +x /deploy.sh
|
||||
|
||||
RUN useradd -m builder
|
||||
RUN usermod -a -G wheel builder
|
||||
RUN chown -R builder:builder /output
|
||||
RUN echo "%wheel ALL=(ALL:ALL) NOPASSWD: ALL" > /etc/sudoers
|
||||
USER builder
|
||||
|
||||
WORKDIR /home/builder/checks-parser
|
||||
|
||||
COPY deploy/archlinux/bin/PKGBUILD PKGBUILD
|
||||
RUN sed -i "s|\$pkgname|${pkgname}-bin|g" PKGBUILD
|
||||
RUN sed -i "s|\$pkgver|${pkgver}|g" PKGBUILD
|
||||
RUN sed -i "s|\$pkgrel|$revision|g" PKGBUILD
|
||||
|
||||
RUN makepkg -s --noconfirm
|
||||
#ENTRYPOINT ["bash"]
|
||||
ENTRYPOINT ["bash", "/deploy.sh"]
|
||||
40
deploy/archlinux/bin/PKGBUILD
Normal file
40
deploy/archlinux/bin/PKGBUILD
Normal file
@@ -0,0 +1,40 @@
|
||||
# Maintainer: Leca <leca@foxarmy.org>
|
||||
pkgname=$pkgname
|
||||
pkgver=$pkgver
|
||||
pkgrel=$pkgrel
|
||||
epoch=
|
||||
pkgdesc="Utility for parsing checks(receipts) to csv"
|
||||
arch=('x86_64')
|
||||
url="https://git.foxarmy.org/leca/checks-parser"
|
||||
license=('GPL-3.0-or-later')
|
||||
groups=()
|
||||
depends=('qt5-base' 'opencv' 'zbar' 'nlohmann-json' 'tesseract' 'qrencode' 'boost')
|
||||
makedepends=('cmake' 'make' 'gcc' 'git' 'qt5-tools')
|
||||
checkdepends=()
|
||||
optdepends=('tesseract-data-rus: scan russian checks with OCR')
|
||||
provides=()
|
||||
conflicts=("checks-parser-git")
|
||||
replaces=()
|
||||
backup=()
|
||||
options=()
|
||||
install=
|
||||
changelog=
|
||||
_releasesurl=https://git.foxarmy.org/leca/checks-parser/releases/download/$pkgver
|
||||
source=("checks-parser-bin::https+$releaseurl/checks-parser-git-${pkgver}_nightly-$pkgrel-x86_64.pkg.tar.zst")
|
||||
noextract=()
|
||||
sha256sums=('SKIP')
|
||||
|
||||
build() {
|
||||
cd "$pkgname"
|
||||
mkdir build && cd build
|
||||
cmake -DBUILD_TRANSLATIONS=on ..
|
||||
make -j ${nproc}
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$pkgname"
|
||||
cd build
|
||||
install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
|
||||
##install -Dm755
|
||||
make DESTDIR="$pkgdir/" PREFIX="/usr" install
|
||||
}
|
||||
28
deploy/archlinux/git/Dockerfile
Normal file
28
deploy/archlinux/git/Dockerfile
Normal file
@@ -0,0 +1,28 @@
|
||||
FROM archlinux:latest
|
||||
|
||||
ARG pkgname=$name
|
||||
ARG pkgver=$version
|
||||
ARG revision
|
||||
|
||||
RUN mkdir -p /output
|
||||
|
||||
RUN pacman --noconfirm -Syu base base-devel sudo
|
||||
RUN echo "sudo cp ${pkgname}-git-${pkgver}_nightly-$revision-x86_64.pkg.tar.zst /output" > /deploy.sh
|
||||
RUN chmod +x /deploy.sh
|
||||
|
||||
RUN useradd -m builder
|
||||
RUN usermod -a -G wheel builder
|
||||
RUN chown -R builder:builder /output
|
||||
RUN echo "%wheel ALL=(ALL:ALL) NOPASSWD: ALL" > /etc/sudoers
|
||||
USER builder
|
||||
|
||||
WORKDIR /home/builder/checks-parser
|
||||
|
||||
COPY deploy/archlinux/git/PKGBUILD PKGBUILD
|
||||
RUN sed -i "s|\$pkgname|${pkgname}-git|g" PKGBUILD
|
||||
RUN sed -i "s|\$pkgver|${pkgver}_nightly|g" PKGBUILD
|
||||
RUN sed -i "s|\$pkgrel|$revision|g" PKGBUILD
|
||||
|
||||
RUN makepkg -s --noconfirm
|
||||
#ENTRYPOINT ["bash"]
|
||||
ENTRYPOINT ["bash", "/deploy.sh"]
|
||||
@@ -1,19 +1,19 @@
|
||||
# Maintainer: Leca <leca@foxarmy.org>
|
||||
pkgname=checks-parser-git
|
||||
pkgver=alpha_0.0.4
|
||||
pkgrel=1
|
||||
pkgname=$pkgname
|
||||
pkgver=$pkgver
|
||||
pkgrel=$pkgrel
|
||||
epoch=
|
||||
pkgdesc="Utility for parsing checks(receipts) to csv"
|
||||
arch=('x86_64')
|
||||
url="https://git.foxarmy.org/leca/checks-parser"
|
||||
license=('GPL-3.0-or-later')
|
||||
groups=()
|
||||
depends=('qt5-base' 'opencv' 'zbar' 'nlohmann-json' 'tesseract' 'qrencode')
|
||||
depends=('qt5-base' 'opencv' 'zbar' 'nlohmann-json' 'tesseract' 'qrencode' 'boost')
|
||||
makedepends=('cmake' 'make' 'gcc' 'git' 'qt5-tools')
|
||||
checkdepends=()
|
||||
optdepends=('tesseract-data-rus: scan russian checks with OCR')
|
||||
provides=()
|
||||
conflicts=()
|
||||
conflicts=("checks-parser-bin")
|
||||
replaces=()
|
||||
backup=()
|
||||
options=()
|
||||
@@ -25,7 +25,7 @@ sha256sums=('SKIP')
|
||||
|
||||
build() {
|
||||
cd "$pkgname"
|
||||
cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr .
|
||||
cmake -DBUILD_TRANSLATIONS=on .
|
||||
make -j ${nproc}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user