blob: cffca1b66401e0961c7bf8803a3bd041aebfc422 (
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
# Maintainer: Yurii Kolesnykov <root@yurikoles.com>
# Contributor: Daan De Meyer <daan.j.demeyer@gmail.com>
# Contributor: Joshua Smith <smolsheep@opensuse.org>
#
# Pull Requests are welcome here: https://github.com/yurikoles-aur/libzypp
#
pkgbase=libzypp
pkgname=(libzypp libzypp-doc)
pkgver=17.35.14
pkgrel=1
pkgdesc="ZYpp Package Management library"
arch=('x86_64')
url=https://en.opensuse.org/Portal:Libzypp
license=('GPL-2.0-or-later')
makedepends=(
'boost-libs'
'gpgme'
'libproxy'
'libsigc++'
'libsolv'
'libsystemd'
'libxml2'
'protobuf'
'yaml-cpp'
'asciidoc'
'boost'
'cmake'
'dejagnu'
'doxygen'
'expat'
'git'
'gnupg'
'graphviz'
'cppcheck'
'zchunk'
)
source=("${pkgname}-${pkgver}.tgz::https://github.com/openSUSE/${pkgname}/archive/${pkgver}.tar.gz")
sha256sums=('f808d6e75c21974539348f0f4e326e78ffe1bc1662175085cfee750fb57b5a75')
build() {
cmake -B build \
-S "${pkgname}-${pkgver}" \
-D CMAKE_BUILD_TYPE=None \
-D CMAKE_C_FLAGS_RELEASE='-DNDEBUG' \
-D CMAKE_INSTALL_PREFIX=/usr \
-D CMAKE_INSTALL_DOCDIR=share/doc \
-D CMAKE_INSTALL_LIBEXECDIR=lib \
-D LIB=lib \
-D CMAKE_SKIP_RPATH=ON \
-D DISABLE_MEDIABACKEND_TESTS=ON \
-D ENABLE_BUILD_DOCS=ON \
-D ENABLE_BUILD_TRANS=ON \
-D ENABLE_BUILD_TESTS=ON \
-D ENABLE_ZSTD_COMPRESSION=ON \
-D ENABLE_ZCHUNK_COMPRESSION=ON \
-D ENABLE_CLANG_TIDY=ON \
-D ENABLE_CPPCHECK=ON \
-D DISABLE_MEDIABACKEND_TESTS=ON
cmake --build build
}
#
# See: disabled due to failure
# TODO: verify disabled test in new updates
check() {
# mkdir -p "${HOME}"/.gnupg
ctest --test-dir build -E RpmPkgSigCheck_test
}
package_libzypp() {
depends=(
'boost-libs'
'gpgme'
'libproxy'
'libsigc++'
'libsolv'
'libsystemd'
'libxml2'
'protobuf'
'yaml-cpp'
'zchunk'
)
DESTDIR="${pkgdir}" cmake --install build
# cmake fix (see GH#28)
mkdir -p "${pkgdir}"/usr/lib/cmake/Zypp
mv "${pkgdir}"/usr/share/cmake/Modules/* "${pkgdir}"/usr/lib/cmake/Zypp/
rm -rf "${pkgdir}"/usr/share/{cmake,doc}
}
package_libzypp-doc() {
arch=('any')
DESTDIR="${pkgdir}" cmake --install build/doc
mv "${pkgdir}"/usr/share/doc/packages/libzypp/libzypp "${pkgdir}"/usr/share/doc/libzypp
rm -rf "${pkgdir}"/usr/share/{doc/packages,man}
}
|