The package rpms/golang-github-oschwald-geoip2-golang.git has added or updated
architecture specific content in its
spec file (ExclusiveArch/ExcludeArch or %ifarch/%ifnarch) in commit(s):
https://src.fedoraproject.org/cgit/rpms/golang-github-oschwald-geoip2-gol....
Change:
-ExclusiveArch: %{?go_arches:%{go_arches}}%{!?go_arches:%{ix86} x86_64 aarch64 %{arm}}
Thanks.
Full change:
============
commit 19b1f2cae78b057823e0ea19c016aac4d7a73ea9
Author: Fabio Valentini <decathorpe(a)gmail.com>
Date: Sun Sep 2 18:45:40 2018 +0200
update to spec 3.0 and enable tests
diff --git a/.gitignore b/.gitignore
index be91bc2..e9b7d57 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,5 @@
/oschwald-geoip2-golang-5b1dc16.tar.gz
/oschwald-geoip2-golang-b1581f4.tar.gz
/oschwald-geoip2-golang-1.2.1.tar.gz
+/geoip2-golang-v1.2.1.tar.gz
+/MaxMind-DB-f6ed981c23b0eb33d7c07568e2177236252afda6.tar.gz
diff --git a/golang-github-oschwald-geoip2-golang.spec
b/golang-github-oschwald-geoip2-golang.spec
index 28bb0d2..38bd841 100644
--- a/golang-github-oschwald-geoip2-golang.spec
+++ b/golang-github-oschwald-geoip2-golang.spec
@@ -1,179 +1,74 @@
-# Generate devel rpm
-%global with_devel 1
-# Build project from bundled dependencies
-%global with_bundled 0
-# Build with debug info rpm
-%global with_debug 0
-# Run tests in check section
-%global with_check 1
-# Generate unit-test rpm
-%global with_unit_test 0
-
-# Tests require the test-data directory, which is a git submodule - and
-# not available in the downloaded tarballs.
-
-%if 0%{?with_debug}
-%global _dwz_low_mem_die_limit 0
-%else
-%global debug_package %{nil}
-%endif
-
-%global provider github
-%global provider_tld com
-%global project oschwald
-%global repo geoip2-golang
#
https://github.com/oschwald/geoip2-golang
-%global provider_prefix %{provider}.%{provider_tld}/%{project}/%{repo}
-%global import_path %{provider_prefix}
-%global commit 7118115686e16b77967cdbf55d1b944fe14ad312
-%global shortcommit %(c=%{commit}; echo ${c:0:7})
-%global commitdate 20170423
+%global goipath
github.com/oschwald/geoip2-golang
+%global tag v1.2.1
-# commit 7118115686e16b77967cdbf55d1b944fe14ad312 == version 1.2.1
-
-
-Name: golang-%{provider}-%{project}-%{repo}
+Name: golang-github-oschwald-geoip2-golang
Version: 1.2.1
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: GeoIP2 lookup library for Go
-License: ISC
-URL: https://%{provider_prefix}
-Source0:
https://%{provider_prefix}/archive/v%{version}/%{project}-%{repo}-%{version}.tar.gz
-# e.g. el6 has ppc64 arch without gcc-go, so EA tag is required
-ExclusiveArch: %{?go_arches:%{go_arches}}%{!?go_arches:%{ix86} x86_64 aarch64 %{arm}}
-# If go_compiler is not set to 1, there is no virtual provide. Use golang instead.
-BuildRequires: %{?go_compiler:compiler(go-compiler)}%{!?go_compiler:golang}
+# Code: ISC; Test data: CC-BY-SA 3.0
+License: ISC and CC-BY-SA
+
+%gometa
+
+URL: %{gourl}
+Source0: %{gosource}
+
+# test data for the non-exported git submodule
+%global dataurl
https://github.com/maxmind/MaxMind-DB
+%global dataref f6ed981c23b0eb33d7c07568e2177236252afda6
+Source1: %{dataurl}/archive/%{dataref}/MaxMind-DB-%{dataref}.tar.gz
+
%description
%{summary}
-%if 0%{?with_devel}
%package devel
Summary: %{summary}
BuildArch: noarch
-%if 0%{?with_check} && ! 0%{?with_bundled}
BuildRequires:
golang(github.com/oschwald/maxminddb-golang)
-%endif
-
-Requires:
golang(github.com/oschwald/maxminddb-golang)
-
-Provides: golang(%{import_path}) = %{version}-%{release}
+BuildRequires:
golang(github.com/stretchr/testify)
%description devel
%{summary}
This package contains library source intended for
building other packages which use import path with
-%{import_path} prefix.
-%endif
-
-
-%if 0%{?with_unit_test} && 0%{?with_devel}
-%package unit-test-devel
-Summary: Unit tests for %{name} package
-
-# test subpackage tests code from devel subpackage
-Requires: %{name}-devel = %{version}-%{release}
-
-%if 0%{?with_check} && ! 0%{?with_bundled}
-BuildRequires:
golang(github.com/stretchr/testify/assert)
-%endif
-
-Requires:
golang(github.com/stretchr/testify/assert)
-
-%description unit-test-devel
-%{summary}
-
-This package contains unit tests for project
-providing packages with %{import_path} prefix.
-%endif
+%{goipath} prefix.
%prep
-%setup -q -n %{repo}-%{version}
+%gosetup -q
+# extract test data to the right location
+pushd test-data
+tar -xzf %{SOURCE1}
+mv MaxMind-DB-%{dataref}/* ./
+rm -r MaxMind-DB-%{dataref}
+popd
-%build
%install
-# source codes for building projects
-%if 0%{?with_devel}
-install -d -p %{buildroot}/%{gopath}/src/%{import_path}/
-echo "%%dir %%{gopath}/src/%%{import_path}/." >> devel.file-list
-
-# find all *.go but no *_test.go files and generate devel.file-list
-for file in $(find . \( -iname "*.go" -or -iname "*.s" \) \! -iname
"*_test.go") ; do
- dirprefix=$(dirname $file)
- install -d -p %{buildroot}/%{gopath}/src/%{import_path}/$dirprefix
- cp -pav $file %{buildroot}/%{gopath}/src/%{import_path}/$file
- echo "%%{gopath}/src/%%{import_path}/$file" >> devel.file-list
-
- while [ "$dirprefix" != "." ]; do
- echo "%%dir %%{gopath}/src/%%{import_path}/$dirprefix" >>
devel.file-list
- dirprefix=$(dirname $dirprefix)
- done
-done
-%endif
-
-# testing files for this project
-%if 0%{?with_unit_test} && 0%{?with_devel}
-install -d -p %{buildroot}/%{gopath}/src/%{import_path}/
-
-# find all *_test.go files and generate unit-test-devel.file-list
-for file in $(find . -iname "*_test.go") ; do
- dirprefix=$(dirname $file)
- install -d -p %{buildroot}/%{gopath}/src/%{import_path}/$dirprefix
- cp -pav $file %{buildroot}/%{gopath}/src/%{import_path}/$file
- echo "%%{gopath}/src/%%{import_path}/$file" >>
unit-test-devel.file-list
-
- while [ "$dirprefix" != "." ]; do
- echo "%%dir %%{gopath}/src/%%{import_path}/$dirprefix" >>
devel.file-list
- dirprefix=$(dirname $dirprefix)
- done
-done
-%endif
-
-%if 0%{?with_devel}
-sort -u -o devel.file-list devel.file-list
-%endif
+%goinstall
%check
-%if 0%{?with_check} && 0%{?with_unit_test} && 0%{?with_devel}
-export GOPATH=%{buildroot}/%{gopath}:%{gopath}
-
-%if ! 0%{?gotest:1}
-%global gotest go test
-%endif
-
-%gotest %{import_path}
-%endif
-
+%gochecks
-#define license tag if not already defined
-%{!?_licensedir:%global license %doc}
-
-%if 0%{?with_devel}
%files devel -f devel.file-list
%license LICENSE
%doc README.md
-%dir %{gopath}/src/%{provider}.%{provider_tld}/%{project}
-%endif
-
-
-%if 0%{?with_unit_test} && 0%{?with_devel}
-%files unit-test-devel -f unit-test-devel.file-list
-%license LICENSE
-%doc README.md
-%endif
%changelog
+* Sun Sep 02 2018 Fabio Valentini <decathorpe(a)gmail.com> - 1.2.1-3
+- Update to spec 3.0 and enable tests.
+
* Fri Jul 13 2018 Fedora Release Engineering <releng(a)fedoraproject.org> - 1.2.1-2
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
diff --git a/sources b/sources
index 9097252..0c66b28 100644
--- a/sources
+++ b/sources
@@ -1 +1,2 @@
-SHA512 (oschwald-geoip2-golang-1.2.1.tar.gz) =
2fe8592d5b39da7afe82c2dd100ed0dde8b436f67e5ed8337627e7a79237af97c86cf2dba025f010e18c0eb68510ac4e19de761ee45692e45e3085dc0454a4a1
+SHA512 (geoip2-golang-v1.2.1.tar.gz) =
2fe8592d5b39da7afe82c2dd100ed0dde8b436f67e5ed8337627e7a79237af97c86cf2dba025f010e18c0eb68510ac4e19de761ee45692e45e3085dc0454a4a1
+SHA512 (MaxMind-DB-f6ed981c23b0eb33d7c07568e2177236252afda6.tar.gz) =
f7b9d370c330980d9419c7bea486b258aef3fa8ab49f83b860ef73036fc577c402e2f631090c5d1d23f2a8e34f927030a8fc6dc15edcd8002136673685aecb12