File pinephone-compass.spec of Package pinephone-compass
#
# spec file for package pinephone-compass
#
# Copyright (c) 2021, Martin Hauke <mardnh@gmx.de>
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: pinephone-compass
Version: 0.3.1
Release: 0
Summary: A simple compass app for the Pine64 Pinephone
License: GPL-3.0-only
URL: https://gitlab.com/lgtrombetta/pinephone-compass
Source0: https://gitlab.com/lgtrombetta/pinephone-compass/-/archive/v%{version}/%{name}-v%{version}.tar.bz2
BuildRequires: cmake
BuildRequires: hicolor-icon-theme
BuildRequires: meson
BuildRequires: pkgconfig
BuildRequires: pkgconfig(glib-2.0)
Requires: python3-matplotlib
Requires: python3-matplotlib-gtk3
Requires: python3-pyxdg
Requires: python3-numpy
Requires: python3-pandas
Requires: typelib-1_0-Gtk-3_0
Requires: typelib-1_0-Handy-1_0
BuildArch: noarch
%description
A simple compass app for the Pine64 Pinephone.
The app fully supports the original LIS3MDL magnetometer chip
(pre-beta Pinephone editions up to Q4 2020) as well as the
new magnetometer chip AF8133J (Pinephone Beta edition).
%prep
%setup -q -n %{name}-v%{version}
# HACK: adjust udev rules installdir
sed -i 's|%{_sysconfdir}/udev/rules.d/|%{_prefix}/lib/udev/rules.d/|' data/meson.build
%build
%meson
%meson_build
%install
%meson_install
%files
%license LICENSE
%doc README.md
%{_bindir}/pinephone-compass
%{_datadir}/appdata/com.gitlab.lgtrombetta.Compass.appdata.xml
%{_datadir}/applications/com.gitlab.lgtrombetta.Compass.desktop
%{_datadir}/glib-2.0/schemas/com.gitlab.lgtrombetta.Compass.gschema.xml
%{_datadir}/icons/hicolor/scalable/apps/com.gitlab.lgtrombetta.Compass.svg
%{_datadir}/icons/hicolor/symbolic/apps/com.gitlab.lgtrombetta.Compass-symbolic.svg
%{_datadir}/pinephone-compass/
%{_udevrulesdir}/90-magn.rules
%changelog