antlr: Use official sources (#4662)

The tarball used until now is not available anymore.
This commit is contained in:
Michael Kuhn 2017-07-02 15:05:09 +02:00 committed by Adam J. Stewart
parent 51ee9a1a6b
commit a88e93852d
2 changed files with 21 additions and 15 deletions

View file

@ -0,0 +1,15 @@
Description: Adds missing includes to fix FTBFS.
Index: antlr-2.7.7/lib/cpp/antlr/CharScanner.hpp
===================================================================
--- antlr-2.7.7.orig/lib/cpp/antlr/CharScanner.hpp 2006-11-01 22:37:17.000000000 +0100
+++ antlr-2.7.7/lib/cpp/antlr/CharScanner.hpp 2009-01-15 20:47:53.000000000 +0100
@@ -17,6 +17,8 @@
#else
#include <cctype>
#endif
+#include <cstdio>
+#include <cstring>
#if ( _MSC_VER == 1200 )
// VC6 seems to need this

View file

@ -32,22 +32,13 @@ class Antlr(AutotoolsPackage):
frameworks. From a grammar, ANTLR generates a parser that can build and
walk parse trees."""
homepage = "http://www.antlr.org"
url = "https://github.com/antlr/antlr/tarball/v2.7.7"
homepage = "http://www.antlr2.org/"
url = "http://www.antlr2.org/download/antlr-2.7.7.tar.gz"
# Notes from http://nco.sourceforge.net/#bld
# The first steps to build (i.e., compile, for the most part) NCO from
# source code are to install the pre-requisites: ANTLR version 2.7.7
# (like this one not version 3.x or 4.x!) (required for ncap2)... ANTLR
# binaries from major distributions are pre-built with the source patch
# necessary to allow NCO to link to ANTLR... The ANTLR source file
# CharScanner.hpp must include this line: #include <cstring> or else
# ncap2 will not compile (this tarball is already patched).
version('2.7.7', '914865e853fe8e1e61a9f23d045cb4ab',
# Patched version as described above
url='http://dust.ess.uci.edu/tmp/antlr-2.7.7.tar.gz')
# Unpatched version
# url='http://dust.ess.uci.edu/nco/antlr-2.7.7.tar.gz')
version('2.7.7', '01cc9a2a454dd33dcd8c856ec89af090')
# Fixes build with recent versions of GCC
patch('gcc.patch')
variant('cxx', default=True, description='Enable ANTLR for C++')
variant('java', default=False, description='Enable ANTLR for Java')