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.
72 lines
1.5 KiB
72 lines
1.5 KiB
5 years ago
|
# Copyright 2016-2019 Gentoo Authors
|
||
8 years ago
|
# Distributed under the terms of the GNU General Public License v2
|
||
|
|
||
5 years ago
|
EAPI=7
|
||
8 years ago
|
|
||
|
if [[ ${PV} == 9999 ]]; then
|
||
|
ECLASS="git-r3"
|
||
5 years ago
|
EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/${PN}.git"
|
||
8 years ago
|
else
|
||
5 years ago
|
SRC_URI="https://gitweb.gentoo.org/proj/${PN}.git/snapshot/${P}.tar.gz"
|
||
8 years ago
|
KEYWORDS="~amd64"
|
||
|
fi
|
||
|
|
||
|
inherit java-pkg-2 java-pkg-simple prefix ${ECLASS}
|
||
|
|
||
|
DESCRIPTION="Java team tool for semi-automatic creation of ebuilds from pom.xml"
|
||
|
HOMEPAGE="https://github.com/gentoo/java-ebuilder"
|
||
|
|
||
|
LICENSE="GPL-2"
|
||
|
SLOT="0"
|
||
|
|
||
|
DEPEND=">=virtual/jdk-1.8"
|
||
8 years ago
|
RDEPEND=">=virtual/jre-1.8
|
||
|
sys-process/parallel
|
||
|
>=dev-java/maven-bin-3"
|
||
8 years ago
|
|
||
|
S="${WORKDIR}/${P}"
|
||
|
|
||
|
JAVA_SRC_DIR="src/main/java"
|
||
|
JAVA_ADDRES_DIRS="src/main/resources"
|
||
|
|
||
|
MAIN_CLASS="org.gentoo.java.ebuilder.Main"
|
||
|
|
||
5 years ago
|
src_prepare() {
|
||
|
default
|
||
|
|
||
8 years ago
|
local base_dir="target/classes/"
|
||
5 years ago
|
|
||
|
[[ ! -d "${base_dir}" ]] && mkdir -p "${base_dir}META-INF"
|
||
8 years ago
|
echo "Manifest-Version: 1.0
|
||
|
Main-Class: ${MAIN_CLASS}" \
|
||
|
>> "${base_dir}META-INF/MANIFEST.MF"
|
||
|
|
||
8 years ago
|
hprefixify scripts/{{tree,meta}.sh,movl} java-ebuilder.conf
|
||
5 years ago
|
}
|
||
|
|
||
|
src_compile() {
|
||
|
java-pkg-simple_src_compile
|
||
|
|
||
|
jar uf ${JAVA_JAR_FILENAME} -C ${JAVA_ADDRES_DIRS} usage.txt || die "Failed to add resources"
|
||
8 years ago
|
}
|
||
|
|
||
|
src_install() {
|
||
|
java-pkg-simple_src_install
|
||
|
java-pkg_dolauncher ${PN} --main ${MAIN_CLASS}
|
||
|
|
||
|
insinto /var/lib/${PN}
|
||
|
doins -r maven
|
||
8 years ago
|
dodir /var/lib/${PN}/{poms,cache}
|
||
5 years ago
|
keepdir /var/lib/${PN}/{poms,cache}
|
||
8 years ago
|
|
||
|
dodoc README maven.conf
|
||
|
|
||
|
exeinto /usr/lib/${PN}
|
||
|
doexe scripts/{tree,meta}.sh
|
||
|
|
||
|
dobin scripts/movl
|
||
8 years ago
|
|
||
|
insinto /etc
|
||
|
doins java-ebuilder.conf
|
||
8 years ago
|
}
|