Package Details: antlr2 2.7.7-13

Git Clone URL: https://aur.archlinux.org/antlr2.git (read-only, click to copy)
Package Base: antlr2
Description: Language recognition tool providing a framework to build grammatical parsers
Upstream URL: https://www.antlr2.org/
Licenses: custom
Provides: antlr
Submitter: arojas
Maintainer: dawie
Last Packager: dawie
Votes: 0
Popularity: 0.000000
First Submitted: 2022-04-01 16:27 (UTC)
Last Updated: 2024-06-25 11:30 (UTC)

Dependencies (3)

Required by (6)

Sources (3)

Latest Comments

mo0zi commented on 2026-10-28 15:08 (UTC)

I got

   -> Extracting antlr-2.7.7.tar.gz with bsdtar                                                                                                                                                  
  bsdtar: Error opening archive: Unrecognized archive format                                                                                                                                      
  ==> ERROR: Failed to extract antlr-2.7.7.tar.gz

which was caused by a regression in libarchive 3.8.10; makepkg extracts with bsdtar, and since that version bsdtar no longer recognizes this old 2006 tar file.

Workaround: let GNU tar do the extraction. Build in a copy so the yay cache stays clean:

cp -r ~/.cache/yay/antlr2 ~/antlr2-build && cd ~/antlr2-build && rm -rf src pkg
sed -i 's/^md5sums=/noextract=("antlr-${pkgver}.tar.gz")\nmd5sums=/' PKGBUILD
sed -i 's/^prepare() {/prepare() {\n  tar -xzf antlr-${pkgver}.tar.gz/' PKGBUILD
makepkg -si

noextract stops bsdtar from extracting the tarball, and prepare() then unpacks it with GNU tar before applying the patch. Afterwards: rm -rf ~/antlr2-build.

hansc commented on 2022-07-26 10:48 (UTC)

I couldn't get this package to build due to the following error:

make[1]: Entering directory '/home/hans/appdata/builds/antlr2/src/antlr-2.7.7/lib/cpp/src'
install C++ core files .. 
install /home/hans/appdata/builds/antlr2/src/antlr-2.7.7/lib/cpp/src/libantlr.a
make[1]: Leaving directory '/home/hans/appdata/builds/antlr2/src/antlr-2.7.7/lib/cpp/src'
install: cannot stat '../../antlr/antlr.jar': No such file or directory

I fixed it by replacing

install -Dm644 ../../antlr/antlr.jar "${pkgdir}"/usr/share/java/antlr2.jar

in the PKGBUILD with

install -Dm644 "${srcdir}"/antlr-${pkgver}/antlr.jar "${pkgdir}"/usr/share/java/antlr2.jar