Blame delve.spec

1881006
# Run tests in check section
1881006
%bcond_without check
1881006
c3ae28e
# https://github.com/go-delve/delve
c3ae28e
%global goipath         github.com/go-delve/delve
c3ae28e
Version:                1.2.0
1881006
1881006
%global common_description %{expand:
1881006
Delve is a debugger for the Go programming language. The goal of the project 
1881006
is to provide a simple, full featured debugging tool for Go. Delve should be 
1881006
easy to invoke and easy to use. Chances are if you're using a debugger, things 
1881006
aren't going your way. With that in mind, Delve should stay out of your way as 
1881006
much as possible.}
1881006
1881006
%gometa
1881006
1881006
Name:           delve
1881006
Release:        1%{?dist}
1881006
Summary:        A debugger for the Go programming language
1881006
# Detected licences
1881006
# - Expat License at 'LICENSE'
1881006
License:        MIT
1881006
URL:            %{gourl}
1881006
Source0:        %{gosource}
8ec5618
8ec5618
# Currently Delve only supports x86_64
8ec5618
ExcludeArch:    ppc64le
8ec5618
ExcludeArch:    s390x
8ec5618
ExcludeArch:    aarch64
8ec5618
ExcludeArch:    i686
baf961b
ExcludeArch:    armv7hl
1881006
6a24acf
Patch1: ./disable-default-compression-dwz-test.patch
6a24acf
Patch2: ./integration-test-symlinks.patch
43d2ad2
Patch3: ./clean-empty-doc.patch
6a24acf
1881006
BuildRequires: golang(github.com/cosiner/argv)
1881006
BuildRequires: golang(github.com/mattn/go-isatty)
1881006
BuildRequires: golang(github.com/peterh/liner)
1881006
BuildRequires: golang(github.com/pkg/profile)
1881006
BuildRequires: golang(github.com/sirupsen/logrus)
1881006
BuildRequires: golang(github.com/spf13/cobra)
1881006
BuildRequires: golang(golang.org/x/arch/x86/x86asm)
1881006
BuildRequires: golang(golang.org/x/sys/unix)
1881006
BuildRequires: golang(golang.org/x/sys/windows)
1881006
BuildRequires: golang(gopkg.in/yaml.v2)
1881006
1881006
%description
1881006
%{common_description}
1881006
1881006
1881006
%package -n %{goname}-devel
1881006
Summary:       %{summary}
1881006
BuildArch:     noarch
1881006
1881006
%description -n %{goname}-devel
1881006
%{common_description}
1881006
1881006
This package contains library source intended for
1881006
building other packages which use import path with
1881006
%{goipath} prefix.
1881006
1881006
1881006
%prep
da74eae
%forgeautosetup -p1
1881006
1881006
rm -rf vendor/
1881006
1881006
1881006
%build
1881006
%gobuildroot
1881006
%gobuild -o _bin/dlv %{goipath}/cmd/dlv
1881006
1881006
1881006
%install
1881006
%goinstall
1881006
install -Dpm 0755 _bin/dlv %{buildroot}%{_bindir}/dlv
1881006
1881006
1881006
%if %{with check}
1881006
%check
866ba58
export GO111MODULE=off
866ba58
export GOPATH=%{buildroot}/%{gopath}:%{gopath}
866ba58
866ba58
delvepath=%{buildroot}/%{gopath}/src/%{goipath}
866ba58
cp -r _fixtures $delvepath
866ba58
cp -r pkg/dwarf/line/_testdata $delvepath/pkg/dwarf/line
866ba58
pushd $delvepath
866ba58
for d in $(go list ./... | grep -v cmd | grep -v scripts); do
866ba58
    %gotest ${d}
866ba58
done
866ba58
rm -rf $delvepath/_fixtures
866ba58
rm -rf $delvepath/pkg/dwarf/line/_testdata
866ba58
popd
1881006
%endif
1881006
1881006
1881006
%files
1881006
%license LICENSE
1881006
%doc CONTRIBUTING.md CHANGELOG.md
1881006
%doc Documentation/*
1881006
%{_bindir}/dlv
1881006
1881006
1881006
%files -n %{goname}-devel -f devel.file-list
1881006
%license LICENSE
1881006
1881006
1881006
%changelog
c3ae28e
* Fri Nov 2 2018 Derek Parker <deparker@redhat.com> - 1.2.0-1
1881006
- First package for Fedora