diff --git a/antlr-build.xml b/antlr-build.xml
index eadf11b..d280255 100644
--- a/antlr-build.xml
+++ b/antlr-build.xml
@@ -60,7 +60,8 @@
version="true"
packagenames="${packagenames}"
splitindex="true"
- use="true">
+ use="true"
+ additionalparam="-Xdoclint:none">
diff --git a/antlr.spec b/antlr.spec
index 4235258..504cc89 100644
--- a/antlr.spec
+++ b/antlr.spec
@@ -1,35 +1,34 @@
%global debug_package %{nil}
# since we have only a static library
-Summary: ANother Tool for Language Recognition
-Name: antlr
-Version: 2.7.7
-Release: 37%{?dist}
-Epoch: 0
-License: Public Domain
-URL: http://www.antlr.org/
-Group: Development/Tools
-Source0: http://www.antlr2.org/download/antlr-%{version}.tar.gz
-Source1: %{name}-build.xml
-Source2: %{name}-script
-Source3: http://repo2.maven.org/maven2/%{name}/%{name}/%{version}/%{name}-%{version}.pom
-Patch1: %{name}-%{version}-newgcc.patch
+Summary: ANother Tool for Language Recognition
+Name: antlr
+Version: 2.7.7
+Release: 39%{?dist}
+Epoch: 0
+License: Public Domain
+URL: http://www.antlr.org/
+Source0: http://www.antlr2.org/download/antlr-%{version}.tar.gz
+Source1: %{name}-build.xml
+Source2: %{name}-script
+Source3: http://repo2.maven.org/maven2/antlr/antlr/%{version}/%{name}-%{version}.pom
+Patch1: %{name}-%{version}-newgcc.patch
# see BZ#848662
-Patch2: antlr-examples-license.patch
+Patch2: antlr-examples-license.patch
-%ifarch %ix86 x86_64 ia64 armv4l sparcv9 alpha s390x ppc ppc64
+%ifarch %{mono_arches}
%if ! 0%{?rhel} >= 6
-BuildRequires: mono-core
-BuildRequires: mono-winforms
+BuildRequires: mono-core
+BuildRequires: mono-winforms
%endif
%endif
-BuildRequires: ant
-BuildRequires: java-javadoc
-BuildRequires: jpackage-utils
-BuildRequires: java-devel >= 1:1.7.0
-
-Requires: jpackage-utils
-Requires: java-headless >= 1:1.7.0
+BuildRequires: ant
+BuildRequires: java-devel >= 1:1.7.0
+BuildRequires: java-javadoc
+BuildRequires: javapackages-local
+BuildRequires: doxygen
+BuildRequires: python2-devel
+BuildRequires: python-setuptools
%description
ANTLR, ANother Tool for Language Recognition, (formerly PCCTS) is a
@@ -38,64 +37,53 @@ compilers, and translators from grammatical descriptions containing
C++ or Java actions [You can use PCCTS 1.xx to generate C-based
parsers].
-%package tool
-Group: Development/Tools
-Summary: ANother Tool for Language Recognition
-Provides: %{name} = %{version}-%{release}
-Obsoletes: %{name} < %{version}-%{release}
-Requires: jpackage-utils
-Requires: java-headless >= 1:1.7.0
-BuildArch: noarch
+%package tool
+Summary: ANother Tool for Language Recognition
+Provides: %{name} = %{version}-%{release}
+Obsoletes: %{name} < %{version}-%{release}
+BuildArch: noarch
-%description tool
+%description tool
ANTLR, ANother Tool for Language Recognition, (formerly PCCTS) is a
language tool that provides a framework for constructing recognizers,
compilers, and translators from grammatical descriptions containing
C++ or Java actions [You can use PCCTS 1.xx to generate C-based
parsers].
-%package manual
-Group: Development/Tools
-Summary: Manual for %{name}
-BuildArch: noarch
+%package manual
+Summary: Manual for %{name}
+BuildArch: noarch
-%description manual
+%description manual
Documentation for %{name}.
-%package javadoc
-Group: Documentation
-Summary: Javadoc for %{name}
-BuildArch: noarch
+%package javadoc
+Summary: Javadoc for %{name}
+BuildArch: noarch
-%description javadoc
+%description javadoc
Javadoc for %{name}.
-%package C++
-Group: Development/Libraries
-Summary: C++ bindings for antlr2 generated parsers
-Provides: antlr-static = %{version}-%{release}
+%package C++
+Summary: C++ bindings for antlr2 generated parsers
+Provides: antlr-static = %{version}-%{release}
-%description C++
+%description C++
This package provides a static C++ library for parsers generated by ANTLR2.
-%package C++-doc
-Group: Documentation
-Summary: Documentation for C++ bindings for antlr2 generated parsers
-BuildRequires: doxygen
-BuildArch: noarch
+%package C++-doc
+Summary: Documentation for C++ bindings for antlr2 generated parsers
+BuildArch: noarch
-%description C++-doc
+%description C++-doc
This package contains the documentation for the C++ bindings for parsers
generated by ANTLR2.
-%package python
-Group: Development/Libraries
-Summary: Python runtime support for ANTLR-generated parsers
-BuildRequires: python2-devel
-BuildRequires: python-setuptools
-BuildArch: noarch
+%package python
+Summary: Python runtime support for ANTLR-generated parsers
+BuildArch: noarch
-%description python
+%description python
Python runtime support for ANTLR-generated parsers
%prep
@@ -108,13 +96,18 @@ cp -p %{SOURCE1} build.xml
# CRLF->LF
sed -i 's/\r//' LICENSE.txt
+# set jar location
+%mvn_file %{name}:%{name} %{name}
+
%build
ant -Dj2se.apidoc=%{_javadocdir}/java
-cp work/lib/antlr.jar . # make expects to find it here
+# make expects to find it here
+cp work/lib/antlr.jar .
export CLASSPATH=.
%configure --without-examples
make CXXFLAGS="${CXXFLAGS} -fPIC" DEBUG=1 verbose=1
-rm antlr.jar # no longer needed
+# no longer needed
+rm antlr.jar
# fix doc permissions and remove Makefiles
rm doc/{Makefile,Makefile.in}
@@ -122,8 +115,8 @@ chmod 0644 doc/*
# generate doxygen docs for C++ bindings
pushd lib/cpp
- doxygen doxygen.cfg
- find gen_doc -type f -exec chmod 0644 {} \;
+ doxygen doxygen.cfg
+ find gen_doc -type f -exec chmod 0644 {} \;
popd
# build python
@@ -132,67 +125,65 @@ cd lib/python
cd ../../
%install
+# jars, POM and depmap
+%mvn_artifact %{SOURCE3} work/lib/%{name}.jar
+%mvn_alias %{name}:%{name} %{name}:%{name}all
+%mvn_install -J work/api
+
mkdir -p $RPM_BUILD_ROOT{%{_includedir}/%{name},%{_libdir},%{_bindir}}
-
-# jars
-mkdir -p $RPM_BUILD_ROOT%{_javadir}
-cp -p work/lib/%{name}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
-
# script
install -p -m 755 %{SOURCE2} $RPM_BUILD_ROOT%{_bindir}/antlr
# C++ lib and headers, antlr-config
-
install -p -m 644 lib/cpp/antlr/*.hpp $RPM_BUILD_ROOT%{_includedir}/%{name}
install -p -m 644 lib/cpp/src/libantlr.a $RPM_BUILD_ROOT%{_libdir}
install -p -m 755 scripts/antlr-config $RPM_BUILD_ROOT%{_bindir}
-# javadoc
-mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{name}
-cp -pr work/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
-
# python
cd lib/python
%{__python} setup.py install -O1 --skip-build --root %{buildroot}
cd ../..
-# POM and depmap
-install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir}
-install -p -m 644 %{SOURCE3} $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom
-%add_maven_depmap -a antlr:antlrall
%files tool -f .mfiles
-%doc LICENSE.txt
-%{_javadir}/%{name}.jar
+%license LICENSE.txt
%{_bindir}/antlr
# this is actually a development package for the C++ target
# as we ship only a static library, it doesn't make sense
# to have a separate -devel package for the headers
%files C++
-%doc LICENSE.txt
+%license LICENSE.txt
%{_includedir}/%{name}
%{_libdir}/libantlr.a
%{_bindir}/antlr-config
%files C++-doc
-%doc LICENSE.txt
+%license LICENSE.txt
%doc lib/cpp/gen_doc/html/
%files manual
-%doc LICENSE.txt
+%license LICENSE.txt
%doc doc/*
-%files javadoc
-%doc LICENSE.txt
-%doc %{_javadocdir}/%{name}
+%files javadoc -f .mfiles-javadoc
+%license LICENSE.txt
%files python
-%doc LICENSE.txt
+%license LICENSE.txt
%{python_sitelib}/antlr/*
%{python_sitelib}/antlr-*
%changelog
+* Fri Oct 02 2015 gil cattaneo 0:2.7.7-39
+- adapt to current guideline
+- remove some rpmlint problems
+- disable javadoc doclint
+- introduce license macro
+
+* Fri Aug 21 2015 Marcin Juszkiewicz - 0:2.7.7-38
+- use %%{mono_archs} instead of hardcoding list (rhbz#1255726)
+
* Tue Jun 16 2015 Fedora Release Engineering - 0:2.7.7-37
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild