summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorlf-2018-10-18 23:05:17 -0600
committerlf-2018-10-18 23:09:49 -0600
commit72cd601eb7933e8db1f8bcf0b4519ecbe60ed9eb (patch)
tree4e6a33343d3f047127e8ee29f8d648731c523ac1
downloadaur-72cd601eb7933e8db1f8bcf0b4519ecbe60ed9eb.tar.gz
Initial commit
-rw-r--r--.SRCINFO32
-rw-r--r--.gitignore4
-rw-r--r--PKGBUILD65
-rw-r--r--klipper.service10
-rw-r--r--sysusers.conf4
-rw-r--r--tmpfiles.conf2
6 files changed, 117 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..fd12c74e4e6
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,32 @@
+pkgbase = klipper-git
+ pkgdesc = 3D printer firmware with motion planning on the host
+ pkgver = r1475.4068d88
+ pkgrel = 1
+ url = https://github.com/KevinOConnor/klipper
+ arch = x86_64
+ arch = i686
+ arch = armv7h
+ license = GPLv3
+ makedepends = git
+ depends = python2-cffi
+ depends = python2-pyserial
+ depends = python2-greenlet
+ depends = ncurses
+ depends = libusb
+ depends = avrdude
+ depends = avr-gcc
+ depends = avr-binutils
+ depends = avr-libc
+ provides = klipper
+ conflicts = klipper
+ source = git+https://github.com/KevinOConnor/klipper#branch=master
+ source = klipper.service
+ source = sysusers.conf
+ source = tmpfiles.conf
+ md5sums = SKIP
+ md5sums = 5ea11719eef9fa6c740d19e1c2fa3932
+ md5sums = c291da9e1750f3ef9ff2f34d6162c5bc
+ md5sums = 18f0e2664394a5042ff21737e1796db7
+
+pkgname = klipper-git
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000000..73b5f1b8afe
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+*.pkg.tar.xz
+src/
+pkg/
+klipper/
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..c65190edc22
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,65 @@
+# Maintainer: lf <packages at lfcode dot ca>
+pkgname=klipper-git
+pkgver=r1475.4068d88
+pkgrel=1
+pkgdesc="3D printer firmware with motion planning on the host"
+arch=('x86_64' 'i686' 'armv7h')
+url="https://github.com/KevinOConnor/klipper"
+license=('GPLv3')
+groups=()
+depends=(
+ python2-cffi
+ python2-pyserial
+ python2-greenlet
+ ncurses
+ libusb
+ avrdude
+ avr-gcc
+ avr-binutils
+ avr-libc
+)
+makedepends=('git')
+provides=("${pkgname%-git}")
+conflicts=("${pkgname%-git}")
+replaces=()
+backup=()
+options=()
+install=
+source=('git+https://github.com/KevinOConnor/klipper#branch=master' 'klipper.service' 'sysusers.conf' 'tmpfiles.conf')
+noextract=()
+md5sums=('SKIP'
+ '5ea11719eef9fa6c740d19e1c2fa3932'
+ 'c291da9e1750f3ef9ff2f34d6162c5bc'
+ '18f0e2664394a5042ff21737e1796db7')
+
+pkgver() {
+ cd "$srcdir/${pkgname%-git}"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "$srcdir/${pkgname%-git}"
+ make clean
+ git clean -fx
+}
+
+build() {
+ cd "$srcdir/${pkgname%-git}"
+ echo 'Building C module...'
+ python2 klippy/chelper/__init__.py
+ echo 'Done'
+ python2 -m compileall klippy
+}
+
+check() {
+ cd "$srcdir/${pkgname%-git}"
+}
+
+package() {
+ cd "$srcdir/${pkgname%-git}"
+ install -Dm644 "$srcdir/klipper.service" "$pkgdir/usr/lib/systemd/system/klipper.service"
+ install -Dm644 "$srcdir/sysusers.conf" "$pkgdir/usr/lib/sysusers.d/klipper.conf"
+ install -Dm644 "$srcdir/tmpfiles.conf" "$pkgdir/usr/lib/tmpfiles.d/klipper.conf"
+ install -dm755 "$pkgdir/var/lib/klipper"
+ GLOBIGNORE=.git cp -r * "$pkgdir/var/lib/klipper"
+}
diff --git a/klipper.service b/klipper.service
new file mode 100644
index 00000000000..718eff3aa7e
--- /dev/null
+++ b/klipper.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=3D printer firmware with motion planning on the host
+
+[Service]
+ExecStart=/usr/bin/python2 /var/lib/klipper/klippy/klippy.py /etc/klipper.cfg -l /var/log/klipper/klippy.log
+Type=simple
+User=klipper
+
+[Install]
+WantedBy=multi-user.target
diff --git a/sysusers.conf b/sysusers.conf
new file mode 100644
index 00000000000..82c797364f3
--- /dev/null
+++ b/sysusers.conf
@@ -0,0 +1,4 @@
+u klipper - "Klipper 3D Print Server User" /var/lib/klipper
+m octoprint uucp
+m octoprint network
+m octoprint tty
diff --git a/tmpfiles.conf b/tmpfiles.conf
new file mode 100644
index 00000000000..1a2377f6240
--- /dev/null
+++ b/tmpfiles.conf
@@ -0,0 +1,2 @@
+d /var/log/klipper 0755 klipper klipper - -
+f /etc/klipper.cfg 0644 klipper klipper - -