Download location (HTTP): Download location (FTP): ftp://cs.nyu.edu/pub/gnat/3.14p/gnat-3.14p-i686-pc-linux-gnu-bin.tar.gz Version used: 3.14p Package size: 10.5 MB Estimated Disk space required: 40 MB |
The gnat package contains a precompiled Ada compiler. This package is used to satisfy the circular dependency when you recompile gcc to include ada.
You may skip installation of gnat if you do not want to recompile gcc with ada support.
gnat depends on: tcsh-6.12 |
Install gnat by running the following commands:
./doconfig |
The above script will ask you how and where you would like to install gnat. To avoid conflicts with the system gcc, the package will be installed in a separate directory, that can later be removed from the system.
In response to the questions asked by the doconfig script, enter 3 in response to the first question and /opt/gnat in response to the second question.
To finish the install, run
./doinstall |
The gnat compiler can be invoked by executing the gcc binary installed by the above script. To avoid conflicts with the system gcc, we will rename the gcc command.
cd /opt/gnat/bin && mv gcc gnatgcc && cd real && mv gcc gnatgcc |
Download location (HTTP): http://mirrors.rcn.net/pub/sourceware/gcc/releases/gcc-3.2.1/gcc-3.2.1.tar.bz2 Download location (FTP): ftp://mirrors.rcn.net/pub/sourceware/gcc/releases/gcc-3.2.1/gcc-3.2.1.tar.bz2 Version used: 3.2.1 Package size: 20.1 MB Estimated Disk space required: 591 MB |
The gcc package contains GNU compilers. This is useful for compiling programs written in Ada, C, C++, Fortran, Java and Objective C.
Install gcc by running the following commands:
PATH_HOLD=$PATH && export PATH=$PATH:/opt/gnat/bin && cd gcc/ada && touch treeprs.ads [es]info.h nmake.ad[bs] && cd ../.. && mkdir ../gcc-build && cd ../gcc-build && ../gcc-3.2.1/configure --prefix=/usr --enable-shared \ --enable-languages=c,c++,objc,f77,ada,java --enable-threads=posix \ --enable-__cxa_atexit --enable-clocale=gnu && make bootstrap && make -C gcc gnatlib_and_tools && make install-no-fixedincludes && ln -sf g77 /usr/bin/f77 && export PATH=$PATH_HOLD |
You may remove the gnat installation:
rm -rf /opt/gnat |
PATH_HOLD=$PATH : This command stores your current path before it's modified so that it can be restored after installation.
export PATH=$PATH:/opt/gnat/bin : This command allows the build to find gnat's Ada compiler to build Ada.
touch treeprs.ads [es]info.h nmake.ad[bs] : This command creates necessary files for the Ada build. This step may be skipped if you don't want to compile the ada frontend.
--enable-languages=c,c++,objc,f77,ada,java : This command builds all available languages in the gcc package. You may modify this command to remove unwanted languages.
--enable-shared --enable-threads=posix --enable-__cxa_atexit : These commands are required to build the C++ libraries to published standards.
--enable-clocale=gnu : This command is a failsafe for incomplete locale data.
make gnatlib_and tools : This command completes the Ada build process. Skip this step if you have not enabled ADA as one of the languages.
The gcc package contains c++, c++filt, cpp, g++, g77, gcc, gccbug, gcov, glob, gnat, gnatbind, gnatbl, gnatchop, gnatfind, gnatkr, gnatlink, gnatls, gnatmake, gnatprep, gnatpsta, gnatpsys, gnatxref and gcc libraries.
The programs and libraries whose descriptions are missing here have been described in the LFS gcc-3.2.1 page.
g77 is the Fortran compiler invoked by gcc.
add2line converts the ASCII form of the 2-line orbital elements in a file to binary form and appends them to the orbdata files.
gcov is a test coverage program.
gdb is the GNAT debugger.
gnatbind is used to bind compiled objects.
gnatbl is the Ada linker.
gnatchop is useful for renaming files to meet the standard Ada default file naming conventions.
gnatelim is used to detect and eliminate unused subprograms in an Ada partition.
gnatfind is the GNAT definition/use finder.
gnatgcc is the compiler.
gnathtml.pl converts Ada source files to html for viewing in Web browsers.
gnatkr is used to determine the crunched name for a given file, when crunched to a specified maximum length.
gnatlink is used to link programs and build an executable file.
gnatls is the compiled unit browser.
gnatmake is an automatic make facility.
gnatmem is the GNAT utility that monitors dynamic allocation and deallocation activity in a program.
gnatprep is the GNAT external preprocessor.
gnatpsta determines the values of all the relevant parameters in Standard and outputs to stdout.
gnatpsys determines the values of all the relevant parameters in System and outputs to stdout.
gnatstub is a generator of body stubs.
gnatxref is the GNAT cross-referencer.
gvd is the GNU Visual Debugger.