Legal uses of lex & yacc

Michael Meissner meissner at osf.org
Wed Feb 21 03:26:17 AEST 1990


In article <90049.104719MCCABE at MTUS5.BITNET> MCCABE at MTUS5.BITNET (Jim
McCabe) writes:

| I've recently become familiar with lex and yacc, and am wondering about
| the legal status of the code generated by these programs.  Is it legal to
| use a yacc-generated compiler (and a lex-generated lexical analyzer)
| for part of a public-domain software package?  For example, if I used lex
| and yacc in a language interpreter I wrote, would it be permissable to
| distribute my program freely over networks and such?  In the Sun lex and
| yacc manuals, they never mention this at all, so I'm worried.  ;)

I don't know about Berkeley Unix, but System V.2 changed the license
agreement such that the output of lex and yacc does not require a UNIX
license, and may be distributed freely.  To actually run lex and yacc,
still requires a UNIX licence.  I believe, but have no direct
knowledge that Berkeley Yacc's output can be used without an AT&T
derived licence.

Bison from the Free Software Foundation (bison is a yacc replacement)
does require that anything using bison, be subject to the same terms
that bison is (the copyleft) -- basically where the full source must
be available (not necessarily free), and that you can't place
redistribution rights on third parties who get either your source or
binaries.

I don't know what the terms for FLEX (the faster lex) are.

--
Michael Meissner	email: meissner at osf.org		phone: 617-621-8861
Open Software Foundation, 11 Cambridge Center, Cambridge, MA

Catproof is an oxymoron, Childproof is nearly so



More information about the Comp.lang.c mailing list