aboutsummaryrefslogtreecommitdiffstats
path: root/testing/nomacs/APKBUILD
blob: 79af81c856257633896d97312f691f72ba9e32e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# Maintainer: Alex Raschi <raschi.alex@gmail.com>
pkgname=nomacs
pkgver=3.10.2
pkgrel=0
pkgdesc="Small and fast Qt image viewer"
url="https://nomacs.org/"
arch="all"
license="GPL-3.0-or-later"
depends="qt5-qtimageformats"
makedepends="cmake
	qt5-qtbase-dev
	qt5-qttools-dev
	qt5-qtsvg-dev
	exiv2-dev
	libraw-dev
	opencv
	opencv-dev
	tiff-dev
	quazip-dev
	libwebp-dev
	lcov
	libzip-dev"
subpackages="$pkgname-doc $pkgname-lang"
options="!check" # no test suite
source="$pkgname-$pkgver.tar.gz::https://github.com/nomacs/$pkgname/archive/$pkgver.tar.gz"
builddir="$srcdir/$pkgname-$pkgver/ImageLounge"

build() {
	cd "$builddir"
	if [ "$CBUILD" != "$CHOST" ]; then
		CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
	fi
	cmake \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DBUILD_SHARED_LIBS=True \
		-DCMAKE_BUILD_TYPE=Release \
		-DCMAKE_CXX_FLAGS="$CXXFLAGS" \
		-DCMAKE_C_FLAGS="$CFLAGS" \
		-DENABLE_QT_DEBUG=False \
		-DENABLE_TRANSLATIONS=True \
		-DENABLE_PLUGINS=False \
		-DUSE_SYSTEM_QUAZIP=True \
		${CMAKE_CROSSOPTS}
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

lang() {
	pkgdesc="Languages for package $pkgname"
	depends=""
	local langdir="usr/share/$pkgname/translations"

	mkdir -p "$subpkgdir"/"$langdir"
	mv "$pkgdir"/"$langdir"/* "$subpkgdir"/"$langdir"/
}

sha512sums="977dbe24e09b00001dd8a33b18c1dbbb3a59106715746b07892f289918205818664fd7b4213028d4288009bcf14a0195759ac1eafca076f81ee72a1e2ae027dd  nomacs-3.10.2.tar.gz"