%global goipath github.com/go-musicfox/go-musicfox Version: 4.6.0 %gometa -f Name: go-musicfox Release: %autorelease Summary: Command-line Netease Cloud Music written in Go License: MIT URL: %{gourl} Source0: %{gosource} BuildRequires: golang flac-devel alsa-lib-devel Requires: flac-libs alsa-lib %description Command-line Netease Cloud Music written in Go. %global _enable_debug_package 0 %global debug_package %{nil} %prep %goprep -k %build export LDFLAGS="-X %{goipath}/internal/types.AppVersion=%{version}" %gobuild -o %{gobuilddir}/bin/musicfox %{goipath}/cmd %install install -d %{buildroot}%{_bindir} install -Dm755 %{gobuilddir}/bin/musicfox %{buildroot}%{_bindir}/musicfox %files %license LICENSE %doc README.md CHANGELOG.md %{_bindir}/musicfox %changelog %autochangelog