diff options
author | Cirk2 | 2022-09-13 10:34:10 +0200 |
---|---|---|
committer | Cirk2 | 2022-09-13 10:38:52 +0200 |
commit | 3d9c3748a071e3e9ca57d46abf6ff808a3d1f12f (patch) | |
tree | 0fd8dc4cb239dedb889090d7fdb76686e06137c2 | |
parent | e13bce4bad2434225e0dccb7d41eb72b1a26637e (diff) | |
download | aur-3d9c3748a071e3e9ca57d46abf6ff808a3d1f12f.tar.gz |
update packaging structure
-rw-r--r-- | .SRCINFO | 12 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | PKGBUILD | 58 |
3 files changed, 47 insertions, 24 deletions
@@ -1,6 +1,6 @@ pkgbase = sdbus-cpp-git pkgdesc = sdbus-c++ is a high-level C++ D-Bus library for Linux designed to provide expressive, easy-to-use API in modern C++ - pkgver = 0.8.3.33.r261.d20210622.e16ffb1 + pkgver = 1.2.0.4.r317.d20220905.74d849d pkgrel = 1 epoch = 2 url = https://github.com/Kistler-Group/sdbus-cpp @@ -14,13 +14,13 @@ pkgbase = sdbus-cpp-git makedepends = doxygen depends = systemd-libs depends = expat - provides = sdbus-cpp=0.8.3.33.r261.d20210622.e16ffb1 - provides = sdbus-cpp-git=0.8.3.33.r261.d20210622.e16ffb1 - provides = sdbus-cpp-=0.8.3.33.r261.d20210622.e16ffb1 + provides = sdbus-cpp-git=1.2.0.4.r317.d20220905.74d849d + provides = sdbus-cpp-git-git=1.2.0.4.r317.d20220905.74d849d + provides = sdbus-cpp-git-=1.2.0.4.r317.d20220905.74d849d conflicts = sdbus-cpp - conflicts = sdbus-cpp-git - conflicts = sdbus-cpp- source = sdbus-cpp-git::git+https://github.com/Kistler-Group/sdbus-cpp.git sha256sums = SKIP pkgname = sdbus-cpp-git + +pkgname = sdbus-cpp-doc-git diff --git a/.gitignore b/.gitignore index 9c4ee24aedf7..f917310f9224 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,4 @@ src/ # End of https://www.gitignore.io/api/archlinuxpackages sdbus-cpp-git +sdbus-cpp @@ -1,8 +1,9 @@ # Maintainer: Cirk2 <privat+aur at cirk2 dot de> -pkgname=sdbus-cpp-git -_pkgname=sdbus-cpp -pkgver=0.8.3.33.r261.d20210622.e16ffb1 +pkgbase=sdbus-cpp-git +_pkgbase=sdbus-cpp +pkgname=(${_pkgbase}-git ${_pkgbase}-doc-git) +pkgver=1.2.0.4.r317.d20220905.74d849d pkgrel=1 epoch=2 pkgdesc="sdbus-c++ is a high-level C++ D-Bus library for Linux designed to provide expressive, easy-to-use API in modern C++" @@ -12,20 +13,18 @@ license=('LGPL2.1' 'custom:sdbus-c++ LGPL Exception 1.0') depends=('systemd-libs' 'expat') makedepends=('systemd' 'git' 'cmake' 'doxygen') provides=( - "${_pkgname}=${pkgver}" - "${_pkgname}-git=${pkgver}" - "${_pkgname}-${_pkgvariant}=${pkgver}" + "${pkgbase}=${pkgver}" + "${pkgbase}-git=${pkgver}" + "${pkgbase}-${_pkgvariant}=${pkgver}" ) conflicts=( - "${_pkgname}" - "${_pkgname}-git" - "${_pkgname}-${_pkgvariant}" + "${_pkgbase}" ) -source=("${pkgname}::git+https://github.com/Kistler-Group/sdbus-cpp.git") +source=("${pkgbase}::git+https://github.com/Kistler-Group/sdbus-cpp.git") sha256sums=('SKIP') pkgver() { - cd "${pkgname}" + cd "${pkgbase}" _ver="$(git describe --tags | sed 's|^v||' | awk -F'-' '{print $1}')" _subver="$(git describe --tags | awk -F'-' '{print $2}')" _rev="$(git rev-list --count HEAD)" @@ -39,17 +38,40 @@ pkgver() { } build() { - cmake "$srcdir/${pkgname}" \ + + cmake -B build -S "$srcdir/${pkgbase}" \ -DCMAKE_INSTALL_PREFIX=/ \ - -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_BUILD_TYPE='Release' \ -DBUILD_CODE_GEN=ON \ -DBUILD_DOXYGEN_DOC=ON - make - make doc + + cmake --build build + cmake --build build --target doc + + # Install so we can split the packaging up later + DESTDIR="$srcdir/fakeinstall" cmake --install build + + # Remove references to $srcdir + find "$srcdir/fakeinstall/usr/share/doc" -name \*.html -print -exec sed \ + -e "s|${srcdir}/sdbus-cpp/include|/usr/include|g" \ + -e "s|${srcdir}/sdbus-cpp||" \ + -i {} \; } -package() { - make DESTDIR="$pkgdir" install - install -Dm644 "$srcdir/${pkgname}/COPYING-LGPL-Exception" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" +package_sdbus-cpp-git() { + local dir + install -Dm644 "$srcdir/${pkgbase}/COPYING-LGPL-Exception" "$pkgdir/usr/share/licenses/$pkgbase/LICENSE" + + for dir in lib include bin ; do + install -dm755 "$pkgdir/usr/$dir" + cp -dr --no-preserve=owner "$srcdir/fakeinstall/usr/$dir/"* "$pkgdir/usr/$dir" + done } +package_sdbus-cpp-doc-git() { + local dir + for dir in share/doc ; do + install -dm755 "$pkgdir/usr/$dir" + cp -dr --no-preserve=owner "$srcdir/fakeinstall/usr/$dir/"* "$pkgdir/usr/$dir" + done +} |