File gitea-base.spec of Package gitea-base
#
# spec file for package gitea
#
# Copyright (c) 2022 SUSE LLC
#
# 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.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define shortname gitea
Name: gitea-base
Version: 1.20.5
Release: 0
Summary: A community managed lightweight code hosting service based on Git
License: MIT
Group: Development/Tools/Version Control
URL: https://gitea.io
Source: %{shortname}-%{version}.tar.gz
Source1: vendor.tar.gz
BuildRequires: golang(API) >= 1.20
Conflicts: gitea
%description
Gitea is a painless self-hosted Git service. It is similar to GitHub, Bitbucket,
and GitLab. Gitea is a fork of Gogs. See the Gitea Announcement blog post to
read about the justification for a fork. The goal of this project is to provide
the easiest, fastest, and most painless way of setting up a self-hosted Git
service. With Go, this can be done platform-independently across all platforms
which Go supports, including Linux, macOS, and Windows, on x86, amd64, ARM and
PowerPC architectures.
https://gitea.io
gitea-base provides only the gitea back end binary in Go. This package is an
incomplete alternative to devel:tools:scm/gitea, useful to test that Go OBS
tooling can build this important application, and for narrow cases such as
containers where only the backend binary may be desired. devel:tools:scm/gitea
provides a complete server install with front end and back end behind a
configured web server and should be preferred for production deployments.
devel:tools:scm/gitea and gitea-base should not be installed together.
%prep
%autosetup -a 1 -n %{shortname}-%{version}
%build
%ifnarch ppc64
export GOFLAGS="-buildmode=pie"
%endif
go build \
-tags sqlite,sqlite_unlock_notify
%install
install -D -m 0755 %{shortname} "%{buildroot}/%{_bindir}/%{shortname}"
%files
%doc README.md
%license LICENSE
%{_bindir}/%{shortname}
%changelog