# # spec file for package rokon # # Copyright (c) 2024 Brycen Granville # # 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. # Generated by go2rpm 1.14.0 # Please submit bugfixes or comments via https://github.com/BrycensRanch/Rokon/issues as I am the developer %bcond check 0 # https://github.com/BrycensRanch/Rokon %global goipath github.com/brycensranch/rokon %global forgeurl https://github.com/BrycensRanch/Rokon %global commit 8f2cc32ddbf55ed796754b88f6ec44a54c544290 %gometa -L -f Name: rokon Version: 1.0.0 %if 0%{?fedora} Release: %autorelease -p %else Release: 14%{?dist} %endif Summary: Control your Roku device with your desktop! # Generated by go-vendor-tools License: AGPL-3.0-only AND BSD-3-Clause AND CC-BY-SA-4.0 AND ISC AND MIT AND MPL-2.0 URL: https://github.com/BrycensRanch/Rokon Source0: https://github.com/BrycensRanch/Rokon/archive/%{commit}.tar.gz # Generated by go-vendor-tools Source1: %{archivename}-vendor.tar.bz2 Source2: go-vendor-tools.toml BuildRequires: go BuildRequires: go-vendor-tools BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: gtk4-devel BuildRequires: gobject-introspection-devel Requires: gtk4 %description Rokon is a GTK4 application that control your Roku. Whether that be with your keyboard, mouse, or controller. %prep ls %goprep -A %setup -q -a1 %{forgesetupargs} %autopatch -p1 %generate_buildrequires %go_vendor_license_buildrequires -c %{S:2} %build # Setup the correct compilation flags for the environment # Not all distributions do this automatically %if 0%{?fedora} # Fedora specific behavior (no-op or something else) # Do nothing, since Fedora 33 the build flags are already set %else %set_build_flags %endif # Rokon's Makefile still respects any CFLAGS LDFLAGS CXXFLAGS passed to it. It is compliant. # https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/PK5PEKWE65UC5XQ6LTLSMATVPIISQKQS/ # Do not compress the DWARF debug information, it causes the build to fail! # As of Go 1.11, debug information is compressed by default. We're disabling that. %if 0%{?mageia} # Fixes RPM build errors: # error: Empty %files file /builddir/build/BUILD/Rokon-master/debugsourcefiles.list # Empty %files file /builddir/build/BUILD/Rokon-master/debugsourcefiles.list %define _debugsource_template %{nil} %endif %define rpmRelease %{?dist} %make_build \ PACKAGED=true \ BUILDTAGS="rpm_crashtraceback" \ PACKAGEFORMAT=rpm \ EXTRALDFLAGS="-compressdwarf=false -X main.rpmRelease=%{rpmRelease}" \ EXTRAGOFLAGS="-mod=vendor -buildmode=pie -trimpath" %install %go_vendor_license_install -c %{S:2} %if 0%{?suse_version} %make_install NODOCUMENTATION="1" PREFIX=%{_prefix} %else %make_install NODOCUMENTATION="0" PREFIX=%{_prefix} %endif %check %go_vendor_license_check -c %{S:2} %if %{with check} %gocheck %endif %files -f %{go_vendor_license_filelist} %{_bindir}/%{name} %{_datadir}/applications/io.github.brycensranch.Rokon.desktop %{_datadir}/icons/hicolor/48x48/apps/io.github.brycensranch.Rokon.png %{_datadir}/icons/hicolor/128x128/apps/io.github.brycensranch.Rokon.png %{_datadir}/dbus-1/services/io.github.brycensranch.Rokon.service %{_datadir}/icons/hicolor/256x256/apps/io.github.brycensranch.Rokon.png %{_datadir}/icons/hicolor/scalable/apps/io.github.brycensranch.Rokon.svg %{_datadir}/metainfo/io.github.brycensranch.Rokon.metainfo.xml %license vendor/modules.txt %doc *.md %if 0%{?fedora} %changelog %autochangelog %else %changelog * Tue Sep 3 2024 Brycen 1.0.0-6 - Removed sysinfo package decreasing binary size and portability and startup time - Added metainfo file for appstream -Added icons to package - Added desktop entry - Added license file to package - Added documentation to package * Mon Sep 2 2024 Brycen 1.0.0-3 - Initial package %endif