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.
50 lines
1.1 KiB
50 lines
1.1 KiB
3 years ago
|
# Copyright 1999-2021 Gentoo Authors
|
||
7 years ago
|
# Distributed under the terms of the GNU General Public License v2
|
||
|
|
||
3 years ago
|
EAPI=7
|
||
7 years ago
|
|
||
|
JAVA_PKG_IUSE="doc source"
|
||
|
|
||
|
inherit java-pkg-2 java-pkg-simple
|
||
|
|
||
|
DESCRIPTION="A parser generator for many languages"
|
||
5 years ago
|
HOMEPAGE="https://www.antlr2.org/"
|
||
|
SRC_URI="https://www.antlr2.org/download/${P}.tar.gz"
|
||
3 years ago
|
|
||
7 years ago
|
LICENSE="public-domain"
|
||
|
SLOT="0"
|
||
3 years ago
|
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
|
||
7 years ago
|
IUSE="examples"
|
||
|
|
||
3 years ago
|
RDEPEND=">=virtual/jre-1.8:*"
|
||
|
DEPEND=">=virtual/jdk-1.8:*"
|
||
7 years ago
|
|
||
|
S="${WORKDIR}/${P}"
|
||
|
|
||
|
JAVA_SRC_DIR="${S}/${PN}"
|
||
|
|
||
|
DOCS=( CHANGES.txt README.txt )
|
||
|
|
||
|
src_prepare() {
|
||
|
default
|
||
|
java-pkg_clean
|
||
|
|
||
|
# Delete build files from examples.
|
||
|
find examples \( -name Makefile.in -o -name shiplist \) -delete || die
|
||
|
}
|
||
|
|
||
|
# Avoid configure script.
|
||
|
src_configure() { :; }
|
||
|
|
||
|
src_install() {
|
||
|
java-pkg-simple_src_install
|
||
|
java-pkg_dolauncher antlr --main antlr.Tool
|
||
|
|
||
|
use doc && java-pkg_dohtml -r doc/*
|
||
|
use examples && java-pkg_doexamples examples/java
|
||
|
use source && java-pkg_dosrc antlr
|
||
|
|
||
3 years ago
|
# https://bugs.gentoo.org/789582
|
||
7 years ago
|
einstalldocs
|
||
|
}
|