summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJelle van der Waa2022-09-01 21:30:44 +0200
committerJelle van der Waa2022-09-01 21:30:44 +0200
commite01d4f613368012b4e9d6f57f63985bf756999ed (patch)
tree0b82ca6b727fdd8709b3b122ff1938a0f0e0cfc2
parent7b93cfdc42fc2e18e55d490776d494565859c925 (diff)
downloadaur-e01d4f613368012b4e9d6f57f63985bf756999ed.tar.gz
import from community
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD56
-rw-r--r--protobuf-3.18.patch15
3 files changed, 58 insertions, 34 deletions
diff --git a/.SRCINFO b/.SRCINFO
index c82540b0484d..600109a22a73 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,18 +1,19 @@
-# Generated by mksrcinfo v8
-# Thu Feb 23 11:52:51 UTC 2017
pkgbase = arcus
pkgdesc = Communication library between internal components for Ultimaker software
- pkgver = 2.4.0
- pkgrel = 1
+ pkgver = 5.0.0
+ pkgrel = 2
url = https://github.com/Ultimaker/libArcus
- arch = any
- license = GPLv3
+ arch = x86_64
+ license = LGPL
makedepends = cmake
+ makedepends = git
+ makedepends = ninja
depends = python
depends = protobuf
- depends = python-sip
- source = https://github.com/Ultimaker/libArcus/archive/2.4.0.tar.gz
- md5sums = d726e90657760488da79480be333e0c7
+ options = debug
+ source = arcus-5.0.0.tar.gz::https://github.com/Ultimaker/libArcus/archive/5.0.0.tar.gz
+ source = protobuf-3.18.patch
+ sha512sums = ffa22847693b4368966e02667ab44e0ce8da82210936da7364ee405acb38286e0e3a05aadbdf56f2a2fcafa8a28b1e4fa294609e1181a68a56dc0ad591e5556f
+ sha512sums = 5aa03da6a8db4fd3145c61bca587aac6c622536dc8211ca19be2c37ce33bf8a53508a95aa35d40d7972c7f0fea3e66ee0c506eda932be35751238f4d7f7e0d61
pkgname = arcus
-
diff --git a/PKGBUILD b/PKGBUILD
index dd234d99c7be..170e5cb07f33 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,39 +1,47 @@
-# Maintainer: Grey Christoforo <first name [at] last name [dot] net>
+# Maintainer: Jelle van der Waa <jelle@archlinux.org>
+# Maintainer: Maxime Gauduin <alucryd@archlinux.org>
+# Contributor: Grey Christoforo <first name [at] last name [dot] net>
+# upstreamed renamed to libarcus
pkgname=arcus
-pkgver=2.4.0
-pkgrel=1
+pkgver=5.0.0
+pkgrel=2
pkgdesc="Communication library between internal components for Ultimaker software"
url="https://github.com/Ultimaker/libArcus"
arch=('x86_64')
-arch=('any')
-license=('GPLv3')
+license=('LGPL')
+makedepends=('cmake' 'git' 'ninja')
+depends=('python' 'protobuf')
+options=('debug')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/Ultimaker/libArcus/archive/${pkgver}.tar.gz"
+ protobuf-3.18.patch)
+sha512sums=('ffa22847693b4368966e02667ab44e0ce8da82210936da7364ee405acb38286e0e3a05aadbdf56f2a2fcafa8a28b1e4fa294609e1181a68a56dc0ad591e5556f'
+ '5aa03da6a8db4fd3145c61bca587aac6c622536dc8211ca19be2c37ce33bf8a53508a95aa35d40d7972c7f0fea3e66ee0c506eda932be35751238f4d7f7e0d61')
-makedepends=('cmake')
-depends=('python' 'protobuf' 'python-sip')
-source=(https://github.com/Ultimaker/libArcus/archive/${pkgver}.tar.gz)
-md5sums=('d726e90657760488da79480be333e0c7')
+prepare() {
+ export _sitelib="$(python -c 'import site; print(site.getsitepackages()[0])')"
+
+ python -m venv --system-site-packages .venv
+ source .venv/bin/activate
+ python -m pip install sip==6.5.1
-build() {
cd libArcus-${pkgver}
- mkdir -p build
- cd build
-
- cmake .. \
- -DCMAKE_INSTALL_PREFIX=/usr \
- -DCMAKE_BUILD_TYPE=Release \
- -DBUILD_EXAMPLES=OFF
-
- make
+ patch -Np1 -i ../protobuf-3.18.patch
+}
+
+build() {
+ cmake -S libArcus-${pkgver} -B build -G Ninja \
+ -DCMAKE_BUILD_TYPE=None \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_INSTALL_LIBDIR=/usr/lib/ \
+ -DPython_SITELIB_LOCAL="${_sitelib}"
+
+ cmake --build build
}
package() {
- cd libArcus-${pkgver}/build
- make DESTDIR="${pkgdir}" install
+ DESTDIR="${pkgdir}" cmake --install build
- mv "${pkgdir}"/usr/lib64/* "${pkgdir}"/usr/lib/.
- rm -rf "${pkgdir}/usr/lib64"
-
install -Dm644 "${srcdir}/libArcus-${pkgver}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
diff --git a/protobuf-3.18.patch b/protobuf-3.18.patch
new file mode 100644
index 000000000000..633d38bb443f
--- /dev/null
+++ b/protobuf-3.18.patch
@@ -0,0 +1,15 @@
+# https://github.com/coryan/vcpkg/blob/master/ports/arcus/0001-fix-protobuf-deprecated.patch
+
+diff --git a/src/Socket_p.h b/src/Socket_p.h
+index 9c3c084..9ccabda 100644
+--- a/src/Socket_p.h
++++ b/src/Socket_p.h
+@@ -548,7 +548,7 @@ namespace Arcus
+
+ google::protobuf::io::ArrayInputStream array(wire_message->data, wire_message->size);
+ google::protobuf::io::CodedInputStream stream(&array);
+- stream.SetTotalBytesLimit(message_size_maximum, message_size_warning);
++ stream.SetTotalBytesLimit(message_size_maximum);
+ if(!message->ParseFromCodedStream(&stream))
+ {
+ error(ErrorCode::ParseFailedError, "Failed to parse message:" + std::string(wire_message->data));