[arch-commits] Commit in qtile/trunk (PKGBUILD qtile.install)
David Runge
dvzrv at archlinux.org
Wed Feb 17 18:56:42 UTC 2021
Date: Wednesday, February 17, 2021 @ 18:56:42
Author: dvzrv
Revision: 862620
upgpkg: qtile 0.17.0-1: Upgrade to 0.17.0.
Add librsvg to depends (its absence has been responsible for most of the
failing tests in https://github.com/qtile/qtile/issues/1352).
Add libnotify to depends.
Update other makedepends/checkdepends according to upstream changes.
Remove upstreamed patch.
Install application to test location in check(), so that tests against the executable work.
Minor cleanups.
Added:
qtile/trunk/qtile.install
Modified:
qtile/trunk/PKGBUILD
---------------+
PKGBUILD | 73 +++++++++++++++++++++++++++-----------------------------
qtile.install | 7 +++++
2 files changed, 43 insertions(+), 37 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2021-02-17 18:55:30 UTC (rev 862619)
+++ PKGBUILD 2021-02-17 18:56:42 UTC (rev 862620)
@@ -1,16 +1,20 @@
# Maintainer: David Runge <dvzrv at archlinux.org>
pkgname=qtile
-pkgver=0.16.1
-pkgrel=2
+pkgver=0.17.0
+pkgrel=1
pkgdesc="A full-featured, pure-Python tiling window manager"
arch=('x86_64')
url="http://www.qtile.org"
license=('MIT')
-depends=('gdk-pixbuf2' 'pango' 'python-cffi' 'python-xcffib' 'python-cairocffi'
-'python-dbus' 'python-gobject' 'python-setuptools')
+depends=('gdk-pixbuf2' 'glibc' 'libnotify' 'librsvg' 'pango' 'python-cairocffi'
+'python-cffi' 'python-xcffib' 'python-dbus' 'python-gobject'
+'python-setuptools')
makedepends=('jupyter_console' 'libpulse' 'python-ipykernel' 'python-iwlib'
-'python-keyring' 'python-psutil' 'python-pytest' 'python-setuptools-scm' 'python-xdg')
+'python-keyring' 'python-psutil' 'python-pytest' 'python-setuptools-scm'
+'python-xdg')
+checkdepends=('imagemagick' 'python-psutil' 'python-pytest' 'python-xvfbwrapper' 'xorg-xcalc'
+'xorg-xclock' 'xorg-xeyes' 'xorg-server-xephyr' 'xorg-xrandr' 'xterm')
optdepends=('alsa-utils: volume widget'
'canto-daemon: canto widget'
'cmus: cmus widget'
@@ -23,23 +27,13 @@
'python-mpd2: mpd2widget widget'
'python-psutil: graph, net and memory widget'
'python-setproctitle: change process name to qtile'
- 'python-xdg: launchbar widget')
-checkdepends=('imagemagick' 'python-pytest' 'python-xvfbwrapper' 'xorg-xcalc'
-'xorg-xclock' 'xorg-xeyes' 'xorg-server-xephyr' 'xorg-xrandr' 'xterm')
-source=("https://files.pythonhosted.org/packages/source/${pkgname::1}/${pkgname}/${pkgname}-${pkgver}.tar.gz"
- "${pkgname}-0.16.1-xcffib_version_detection.patch::https://github.com/qtile/qtile/pull/1963/commits/7e37f56327dbee7343b5d5a31902a91468674cb0.patch")
-sha512sums=('aea42f7f6799a88b586167a57f5b5ab6f1c5bb663dec352d15eb47ce0d37fb23c31d1631cab8178c71be5ae714ec12c35a350377383dba1749a98cd45c22515b'
- 'f5745d53e6bfb10f6b4209431679e515a76a212e45ab5b30aa3c28200e1f9896a696d5d9ca6037a46fa2cb430a46d788bfa69e49aa238ad2e76685b071735748')
-b2sums=('1f75f5dbcab6180dcf778e28108e70b6dd01105fa275aadf4a53d96ab84f3b759cb8553bcf3de2011b0990d61adc9269663afa32b83d1aa9c052b00ef9e89358'
- 'af1fc26a550b3a293161e765c8ef1a77dbe92105b6b06f15a2c3da5eefa0f895214ee91bd7120e0ce1ed44a050d05b70c7b053363f2fde4a42542e7675c7c599')
+ 'python-xdg: launchbar widget'
+)
+install="${pkgname}.install"
+source=("https://files.pythonhosted.org/packages/source/${pkgname::1}/${pkgname}/${pkgname}-${pkgver}.tar.gz")
+sha512sums=('bfe51aabef2d48693c5bb7525cf67b1bb99cf3af5a653cd81d523e5adaa4767a43e7a87db14f9b85fae3a9e414af41a2e66736556eb1552d099755ba6f39caeb')
+b2sums=('f2290ab823b31cd8ed512f076018a8df19bbfedbb7d5c6932eee7cd46c341a08af04ed0d99f4391d1b3ccc07eb33015bbf0050c1c5d749bace4fb6dcfcb71ac9')
-prepare() {
- cd "${pkgname}-${pkgver}"
- # fix broken xcffib version detection:
- # https://github.com/qtile/qtile/issues/1962
- patch -Np1 -i "../${pkgname}-0.16.1-xcffib_version_detection.patch"
-}
-
build() {
cd "${pkgname}-${pkgver}"
python setup.py build
@@ -46,8 +40,23 @@
}
check() {
+ local _python_version="$(python -c 'import sys; print(".".join(map(str, sys.version_info[:2])))')"
+ local _test_dir='test_dir'
+
cd "${pkgname}-${pkgver}"
- export PYTTHONPATH="build/lib/:${PYTHONPATH}"
+
+ # install into test location
+ mkdir -vp "${_test_dir}"
+ python setup.py install --skip-build \
+ --optimize=1 \
+ --root="${_test_dir}"
+ # create dummy dir for executable and symlink the test executable to it for
+ # testing
+ mkdir -vp bin
+ ln -svf "../${_test_dir}/usr/bin/${pkgname}" "bin/${pkgname}"
+
+ export PYTHONPATH="${PWD}/${_test_dir}/usr/lib/python${_python_version}/site-packages/:${PYTHONPATH}"
+ export PATH="${PWD}/test_dir/usr/bin:${PATH}"
export LC_TYPE=en_US.UTF-8
echo "building pango"
python3 ./libqtile/pango_ffi_build.py
@@ -55,25 +64,15 @@
python3 ./libqtile/backend/x11/xcursors_ffi_build.py
echo "building pulseaudio volume control"
python3 ./libqtile/widget/pulseaudio_ffi.py
- # some tests are failing:
- # https://github.com/qtile/qtile/issues/1352
- pytest -v -k "not test_images_good \
- and not test_qtile_cmd \
- and not test_svg_scaling \
- and not test_pattern_rotate \
- and not test_pattern \
- and not test_from_path \
- and not test_init \
- and not test_get_cairo_surface"
+ echo "running pytest"
+ pytest -v
}
package() {
cd "${pkgname}-${pkgver}"
- # install
python setup.py install --skip-build \
--optimize=1 \
- --root="${pkgdir}" \
- --prefix=/usr
+ --root="${pkgdir}"
# license
install -vDm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}/"
# config
@@ -83,6 +82,6 @@
install -vDm 644 "resources/${pkgname}.desktop" \
-t "${pkgdir}/usr/share/xsessions/"
# docs
- install -t "${pkgdir}/usr/share/doc/${pkgname}/" \
- -vDm 644 {CHANGELOG,README.rst}
+ install -vDm 644 {CHANGELOG,README.rst} \
+ -t "${pkgdir}/usr/share/doc/${pkgname}/"
}
Added: qtile.install
===================================================================
--- qtile.install (rev 0)
+++ qtile.install 2021-02-17 18:56:42 UTC (rev 862620)
@@ -0,0 +1,7 @@
+# arg 1: the new package version
+# arg 2: the old package version
+post_upgrade() {
+ if [ "$(vercmp "$2" 0.17.0)" -le 0 ]; then
+ printf "WARNING: Major config and functionality changes. A restart (not reload) of qtile is required.\n"
+ fi
+}
More information about the arch-commits
mailing list