#### Linux From Scratch - Version 9.0-systemd

### Chapter 6. Installing Basic System Software

- Prev

  Iana-Etc-2.30

- Next

  Flex-2.6.4

- Up
- Home

# 6.31. Bison-3.4.1

The Bison package contains a parser generator.

Approximate build time: 0.3 SBU
Required disk space: 39 MB

## 6.31.1. Installation of Bison

First, fix a build problem with the current version:

    sed -i '6855 s/mv/cp/' Makefile.in

Prepare Bison for compilation:

    ./configure --prefix=/usr --docdir=/usr/share/doc/bison-3.4.1

Compile the package, but work around a race condition in the current version:

    make -j1

There is a circular dependency between bison and flex with regard to the checks. If desired, after installing flex in the next section, the bison package can be rebuilt and the bison checks can be run with make check.

Install the package:

    make install

## 6.31.2. Contents of Bison

Installed programs: bison and yacc
Installed library: liby.a
Installed directory: /usr/share/bison

### Short Descriptions

bison | Generates, from a series of rules, a program for analyzing the structure of text files; Bison is a replacement for Yacc (Yet Another Compiler Compiler)
yacc | A wrapper for bison, meant for programs that still call yacc instead of bison; it calls bison with the `-y` option
`liby` | The Yacc library containing implementations of Yacc-compatible `yyerror` and `main` functions; this library is normally not very useful, but POSIX requires it

- Prev

  Iana-Etc-2.30

- Next

  Flex-2.6.4

- Up
- Home