Browse Source

[www-apps/gitea] version bump, might not build.

master
Robert Förster 1 year ago
parent
commit
c2737817ca
  1. 2
      www-apps/gitea/Manifest
  2. 112
      www-apps/gitea/gitea-1.12.0.ebuild

2
www-apps/gitea/Manifest

@ -1 +1 @@
DIST gitea-src-1.12.0-rc1.tar.gz 134807484 BLAKE2B ba988ada498d03336ef19bc0a2abdfcfbd695cc2404b0a9ae418f9f70fc7b5c7e430ee1476ff61ed72f0a67483ac344c7f5175429e9936968a56ec7f14f6be9a SHA512 855b0840320a3f95f106079efba6913c9b101cef86c230d5b4adf38d833767f9449bfe7a5578fe98f696e9c9eae053b86ddc0442e1feb94804718ad1e7ef39aa
DIST gitea-1.12.0.tar.gz 135098075 BLAKE2B 95762a13a2875ac08e60b73e40c3d65000f4ceb39b99429ea2c6b97859108bcbe1de7e258bd7d7da0d38d86e995c0bc44c81f56cad636d46cd37ae56d7289e97 SHA512 c5997c982088134e889811417dce8a03cb8febc921fbfe2f08dbdafd4168795bd59cda52c8e52a2503dffc54fc2ebfc13153c66ec71efe54c0326873ee248dcb

112
www-apps/gitea/gitea-1.12.0_rc1.ebuild → www-apps/gitea/gitea-1.12.0.ebuild

@ -2,71 +2,42 @@
# Distributed under the terms of the GNU General Public License v2
EAPI=7
if [[ ${PV} != 9999* ]] ; then
SCM="golang-vcs-snapshot"
else
SCM="git-r3"
fi
inherit fcaps golang-base tmpfiles systemd ${SCM}
unset SCM
MY_PV=${PV/_/-}
EGO_PN="code.gitea.io/gitea"
inherit fcaps go-module tmpfiles systemd
MY_PV="${PV/_rc/-rc}"
DESCRIPTION="A painless self-hosted Git service"
HOMEPAGE="https://gitea.io"
if [[ ${PV} != 9999* ]] ; then
SRC_URI="https://github.com/go-gitea/gitea/releases/download/v${MY_PV}/gitea-src-${MY_PV}.tar.gz"
SRC_URI="https://github.com/go-gitea/gitea/releases/download/v${MY_PV}/gitea-src-${MY_PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~arm ~arm64"
S="${WORKDIR}"
else
EGIT_REPO_URI="https://github.com/go-gitea/gitea"
EGIT_CHECKOUT_DIR="${WORKDIR}/${P}/src/${EGO_PN}"
has test ${FEATURES} && EGIT_MIN_CLONE_TYPE="mirror"
inherit git-r3
S="${WORKDIR}/${P}"
fi
LICENSE="Apache-2.0 BSD BSD-2 ISC MIT MPL-2.0"
SLOT="0"
IUSE="+acct build-client pam sqlite"
IUSE="+acct pam sqlite"
BDEPEND="dev-lang/go
build-client? ( >=net-libs/nodejs-10[npm] )"
DEPEND="pam? ( sys-libs/pam )"
RDEPEND="${DEPEND}
BDEPEND=">=net-libs/nodejs-10[npm]"
COMMON_DEPEND="
acct? (
acct-group/git
acct-user/git[gitea]
)
acct-user/git[gitea] )
pam? ( sys-libs/pam )"
DEPEND="${COMMON_DEPEND}"
RDEPEND="${COMMON_DEPEND}
dev-vcs/git"
DOCS=( custom/conf/app.ini.sample CONTRIBUTING.md README.md )
FILECAPS=( cap_net_bind_service+ep usr/bin/gitea )
S="${WORKDIR}/${P}/src/${EGO_PN}"
PATCHES=( "${FILESDIR}/gitea-logflags.patch" )
gitea_make() {
local gitea_tags=(
bindata
$(usev pam)
$(usex sqlite 'sqlite sqlite_unlock_notify' '')
)
local gitea_settings=(
"-X code.gitea.io/gitea/modules/setting.CustomConf=${EPREFIX}/etc/gitea/app.ini"
"-X code.gitea.io/gitea/modules/setting.CustomPath=${EPREFIX}/var/lib/gitea/custom"
"-X code.gitea.io/gitea/modules/setting.AppWorkPath=${EPREFIX}/var/lib/gitea"
)
local makeenv=(
TAGS="${gitea_tags[@]}"
LDFLAGS="-extldflags \"${LDFLAGS}\" ${gitea_settings[@]}"
GOPATH="${WORKDIR}/${P}:$(get_golibdir_gopath)"
)
[[ ${PV} != 9999* ]] && makeenv+=("DRONE_TAG=${MY_PV}")
env "${makeenv[@]}" emake -j1 "$@"
}
DOCS=(
custom/conf/app.ini.sample CONTRIBUTING.md README.md
)
FILECAPS=(
cap_net_bind_service+ep usr/bin/gitea
)
src_prepare() {
default
@ -90,31 +61,34 @@ src_prepare() {
sed -i -e "s#^DB_TYPE = .*#DB_TYPE = sqlite3#" custom/conf/app.ini.sample || die
fi
# Remove already build assets (like frontend part)
use build-client && gitea_make clean-all
}
einfo "Remove tests which are known to fail with network-sandbox enabled."
rm ./modules/migrations/github_test.go || die
src_compile() {
if use build-client ; then
gitea_make build
else
gitea_make backend
fi
einfo "Remove tests which depend on gitea git-repo."
rm ./modules/git/blob_test.go || die
rm ./modules/git/repo_test.go || die
}
src_test() {
if has network-sandbox ${FEATURES}; then
einfo "Remove tests which are known to fail with network-sandbox enabled."
rm ./modules/migrations/github_test.go || die
fi
if [[ ${PV} != 9999* ]] ; then
einfo "Remove tests which depend on gitea git-repo."
rm ./modules/git/blob_test.go || die
rm ./modules/git/repo_test.go || die
fi
src_compile() {
local gitea_tags=(
bindata
$(usev pam)
$(usex sqlite 'sqlite sqlite_unlock_notify' '')
)
local gitea_settings=(
"-X code.gitea.io/gitea/modules/setting.CustomConf=${EPREFIX}/etc/gitea/app.ini"
"-X code.gitea.io/gitea/modules/setting.CustomPath=${EPREFIX}/var/lib/gitea/custom"
"-X code.gitea.io/gitea/modules/setting.AppWorkPath=${EPREFIX}/var/lib/gitea"
)
local makeenv=(
TAGS="${gitea_tags[@]}"
LDFLAGS="-extldflags \"${LDFLAGS}\" ${gitea_settings[@]}"
)
[[ ${PV} != 9999* ]] && makeenv+=("DRONE_TAG=${MY_PV}")
default
# -j1 as Makefile doesn't handle dependancy correctly, and is not
# useful as golang compiler don't use this info.
env "${makeenv[@]}" emake -j1 build
}
src_install() {
Loading…
Cancel
Save