You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
144 lines
4.7 KiB
144 lines
4.7 KiB
2 years ago
|
# This specfile is licensed under:
|
||
|
# SPDX-License-Identifier: MIT
|
||
|
# License text: https://spdx.org/licenses/MIT.html
|
||
|
# SPDX-FileCopyrightText: 2022 Maxwell G <gotmax@e.email>
|
||
|
# SPDX-FileCopyrightText: Fedora Project Authors
|
||
|
|
||
1 year ago
|
%global forgeurl https://pagure.io/go-rpm-macros
|
||
2 years ago
|
|
||
|
Name: go-rpm-macros-epel
|
||
1 year ago
|
Version: 3.3.0.2
|
||
1 year ago
|
%global tag epel9-%{version}
|
||
|
%global distprefix %{nil}
|
||
|
%forgemeta
|
||
|
Release: 1%{?dist}
|
||
2 years ago
|
Summary: Backport of certain Fedora Go RPM macros to EPEL
|
||
|
|
||
|
License: GPL-3.0-or-later
|
||
1 year ago
|
URL: %{forgeurl}
|
||
|
Source0: %{forgesource}
|
||
|
# Downstream README
|
||
|
Source1: README.md
|
||
2 years ago
|
# golist-symlink subpackage license
|
||
1 year ago
|
Source2: https://github.com/spdx/license-list-data/raw/master/text/Unlicense.txt
|
||
2 years ago
|
|
||
1 year ago
|
# Require RHEL's macros. We read macros from go-srpm-macros in the specfile.
|
||
|
BuildRequires: go-srpm-macros
|
||
2 years ago
|
BuildRequires: go-rpm-macros
|
||
|
Requires: go-rpm-macros
|
||
|
|
||
|
Requires: go-srpm-macros-epel = %{version}-%{release}
|
||
1 year ago
|
Requires: go-rpm-macros-golist-symlink = %{version}-%{release}
|
||
2 years ago
|
|
||
|
%description
|
||
|
go-rpm-macros-epel contains backports of certain Go RPM macros from Fedora.
|
||
|
|
||
|
|
||
|
%package -n go-srpm-macros-epel
|
||
|
Summary: Backport of certain Go SRPM macros from Fedora
|
||
|
BuildArch: noarch
|
||
|
# Explicitly Require go-srpm-macros from RHEL even though they are already part
|
||
|
# of the buildroot. We import its Lua.
|
||
|
Requires: go-srpm-macros
|
||
|
# Pull in go-rpm-macros-epel if go-rpm-macros is installed.
|
||
|
Requires: (go-rpm-macros-epel if go-rpm-macros)
|
||
|
|
||
|
%description -n go-srpm-macros-epel
|
||
|
go-srpm-macros-epel contains backports of certain Go SRPM macros from Fedora.
|
||
|
|
||
|
|
||
|
%package -n go-rpm-macros-golist-symlink
|
||
|
Summary: Provides symlink to the bundled golist in go-rpm-macros
|
||
|
# The package just provides a symlink.
|
||
|
License: Unlicense
|
||
|
# Conflict with standard golist in case that gets packaged.
|
||
|
Conflicts: golist
|
||
|
Requires: go-rpm-macros
|
||
|
|
||
|
%description -n go-rpm-macros-golist-symlink
|
||
|
go-rpm-macros-golist-symlink provides a symlink from /usr/bin to
|
||
|
go-rpm-macros's bundled golist, which is installed in
|
||
|
/usr/libexec/go-rpm-macros. This allows the macros that expect to find golist
|
||
|
in $PATH to work properly.
|
||
|
|
||
|
This package is split out and namespaced to allow the upstream golist to be
|
||
|
packaged as golist.
|
||
|
|
||
|
|
||
|
%prep
|
||
1 year ago
|
%autosetup -p1 %{forgesetupargs}
|
||
|
mv README.md README.upstream.md
|
||
|
cp %{S:1} %{S:2} .
|
||
|
%writevars -f rpm/macros.d/macros.zzz-go-srpm-macros-epel golang_arches golang_arches_future gccgo_arches gopath
|
||
2 years ago
|
|
||
|
|
||
|
%install
|
||
|
# Install macros and lua
|
||
1 year ago
|
install -Dpm 0644 rpm/macros.d/macros.* -t %{buildroot}%{_rpmmacrodir}
|
||
|
install -Dpm 0644 rpm/lua/rpm/*.lua -t %{buildroot}%{_rpmluadir}/fedora/rpm
|
||
|
install -Dpm 0644 rpm/lua/srpm/*.lua -t %{buildroot}%{_rpmluadir}/fedora/srpm
|
||
2 years ago
|
|
||
|
|
||
|
# Create symlink for golist-symlink subpackage
|
||
|
mkdir %{buildroot}%{_bindir}
|
||
|
ln -s %{_libexecdir}/go-rpm-macros/golist %{buildroot}%{_bindir}/golist
|
||
|
|
||
|
# Install REAMDE and licenses to a single directory for both subpackages.
|
||
|
install -Dpm 0644 README.md README.upstream.md \
|
||
|
-t %{buildroot}%{_docdir}/go-rpm-macros-epel
|
||
|
install -Dpm 0644 LICENSE.txt \
|
||
|
-t %{buildroot}%{_defaultlicensedir}/go-rpm-macros-epel
|
||
|
|
||
|
%ifarch %{go_arches}
|
||
|
%files
|
||
|
%{_rpmmacrodir}/macros.zzz-go-rpm-macros-epel
|
||
1 year ago
|
%{_rpmluadir}/fedora/rpm/go_epel.lua
|
||
2 years ago
|
%endif
|
||
|
|
||
|
%files -n go-srpm-macros-epel
|
||
|
%license %{_defaultlicensedir}/go-rpm-macros-epel
|
||
|
%doc %{_docdir}/go-rpm-macros-epel
|
||
|
%{_rpmmacrodir}/macros.zzz-go-srpm-macros-epel
|
||
1 year ago
|
%{_rpmluadir}/fedora/srpm/go_epel.lua
|
||
2 years ago
|
|
||
|
%files -n go-rpm-macros-golist-symlink
|
||
|
%doc README.md
|
||
|
%license Unlicense.txt
|
||
|
%{_bindir}/golist
|
||
|
|
||
|
|
||
|
%changelog
|
||
1 year ago
|
* Sat Nov 04 2023 Maxwell G <maxwell@gtmx.me> - 3.3.0.2-1
|
||
|
- Update to 3.3.0.2.
|
||
|
|
||
1 year ago
|
* Sun Oct 29 2023 Maxwell G <maxwell@gtmx.me> - 3.3.0-1
|
||
|
- Update to new source git source
|
||
|
- Remove go_mod_vendor.prov from this package. It's already upstream.
|
||
|
- Add -L flag to %%gometa and %%gorpmname
|
||
1 year ago
|
- Add direct dependency on go-rpm-macros-golist-symlink
|
||
1 year ago
|
|
||
2 years ago
|
* Tue Jul 25 2023 Arkady L. Shane <ashejn@msvsphere.ru> - 1-8
|
||
|
- Rebuilt for MSVSphere 9.2
|
||
|
|
||
|
* Thu Sep 08 2022 Maxwell G <gotmax@e.email> - 1-8
|
||
|
- go-srpm-macros: Explicitly Require go-srpm-macros from RHEL
|
||
|
|
||
|
* Thu Sep 08 2022 Maxwell G <gotmax@e.email> - 1-7
|
||
|
- Install docs into the correct directory
|
||
|
|
||
|
* Wed Sep 07 2022 Maxwell G <gotmax@e.email> - 1-6
|
||
|
- Move go_mod_vendor generator from -srpm-macros to -rpm-macros subpackage
|
||
|
|
||
|
* Sat Sep 03 2022 Maxwell G <gotmax@e.email> - 1-5
|
||
|
- Fix %%goinstall flags definition
|
||
|
- go-srpm-macros-epel: Pull in go-rpm-macros-epel if go-rpm-macros is installed.
|
||
|
|
||
|
* Wed Aug 31 2022 Maxwell G <gotmax@e.email> - 1-4
|
||
|
- Redfine %%goinstallflags
|
||
|
Relates: rhbz#2098400
|
||
|
- Add support for `%%golang_arches_future` and `%%gometa -f`.
|
||
|
Relates: rhbz#2121796
|
||
|
- Add go-rpm-macros-golist-symlink
|
||
|
Relates: rhbz#2100618
|
||
|
|