File ergodox-wally.spec of Package ergodox-wally
#
# spec file for package ergodox-wally
#
# Copyright (c) 2020 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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 http://bugs.opensuse.org/
#
%define pkg_name wally
Name: ergodox-wally
Version: 0
Release: 0
Summary: The EZ Flash(ing tool)
License: MIT
Url: https://ergodox-ez.com/pages/wally
Source: %{pkg_name}-%{version}.tar.xz
# go mod vendor && ( rm -f ../vendor.tar.xz && tar cfvJ ../vendor.tar.xz vendor/ )
# Source1: vendor.tar.xz
# cd ui/
# yarn install --pure-lockfile --ignore-engines
# ./node_modules/.bin/webpack
# cd ..
# tar cvfJ ../webpack.tar.xz ui/build
# Source2: webpack.tar.xz
BuildRequires: golang(API)
BuildRequires: golang-github-jteeuwen-go-bindata
BuildRequires: pkgconfig(udev)
BuildRequires: pkgconfig(gtk+-3.0)
BuildRequires: pkgconfig(webkit2gtk-4.0)
BuildRequires: pkgconfig(libusb-1.0)
Recommends: ergodox-wally-cli
Requires: ergodox-wally-udev-rules
%description
ZSA keyboards can do a lot — and all of that intelligence lives right on the
board. You customize the firmware online, download a file, and flash it.
%package udev-rules
Summary: The EZ Flash(ing tool) - udev rules
BuildArch: noarch
Recommends: ergodox-wally-cli
Recommends: ergodox-wally
%description udev-rules
ZSA keyboards can do a lot — and all of that intelligence lives right on the
board. You customize the firmware online, download a file, and flash it.
This package holds the udev rules to grant access to the devices for configuration.
%prep
%autosetup -p1 -n %{pkg_name}-%{version}
# -a 1 -a 2
%build
# go-bindata -prefix "frontend/build" -o assets.go frontend/build/index.dist.js
# go build -mod=vendor -buildmode=pie -tags dist -o dist/linux64/wally
# go build -mod=vendor -buildmode=pie -o dist/linux64/wally-cli cli/main.go
%install
# install -D -m 0755 dist/linux64/wally %{buildroot}%{_sbindir}/wally
for rules_file in 50-oryx-legacy.rules 50-wally.rules 50-oryx.rules ; do
install -D -m 0644 dist/linux64/${rules_file} %{buildroot}%{_udevrulesdir}/${rules_file}
done
%files udev-rules
%{_udevrulesdir}/50-wally.rules
%{_udevrulesdir}/50-oryx.rules
%{_udevrulesdir}/50-oryx-legacy.rules
%doc README.md
%changelog