Some proposals for descriptions of packages

Gueven Bay guevenbay at web.de
Thu Sep 2 13:47:42 PDT 2004


Hello again,
I promised to write some proposals for descriptions of the installed software.
Here it is. For one: I apologize for this long text. Then: I know that I didn't
write descriptions for all packages but I first want to know what your opinion
is and how you want to have the descriptions. I am already on the work for the
other descriptions.


PART I
------------

Binutils

Binutils is a package of programs which can assemble, link and manipulate binary
and object files. With these programs you are able to create and
manipulate libraries, your compilers are able to create executables and your
system can read and control its most important files. Let's have a quick look at
the included programs:
ld -- With this your system is able to read, combine and write object files in
many different formats -- the most important for you today is the "ELF" format.
To accomplish this ld combines a number of object and archive files, relocates
their data and ties up symbol references. You will use ld massively because ld
is the last step in the compiling process.
as -- With this you can take the output of the C compiler and assemble it for
the use with the linker ld. It is possible to give the assembler some arguments
as this is done automatically of the C compiler. Read through the output of
your compiling processes and if you read  something like "-Wa,-alh,-L" in the
gcc invoking commands you see that the assembler gets the arguments "alh" and
"L".
nm -- This little program lists for you the symbols which are "integrated" in
the object files if they were not "strip"ped. Just do this to see nm working:
#echo 'main(){}' > dummy.c
#cc dummy.c
#nm
objdump -- With this you get a wide variety of information about object files.
So you can analyze the contents of them.
size -- The object files are assembled from various sections such as "text",
"data" and "bss". You can get the sizes of each of this sections of an object
file with this program.
ar -- You can create archives of one or more files with this. For example the
Debian packages -- the .deb files -- are archives created with ar.
strings -- In non-text files there are also "printable" strings -- for
example the symbols mentioned above -- and to list them use this program.
ranlib -- To make an archive "ready" for the linker you have to create an index
in it that references the symbols of each file in the archive. To create this
index just use ranlib or ar with the option "-s" .
objcopy -- If you want to copy object files from one _into_ another -- speak as
copying the contents from one to another -- and want maybe to change the format
of the object file you will use objcopy.
addr2line -- This translates program addresses into file names and line numbers.
Given an executable and an address, it uses the debugging information in the
executable to figure out which file name and line number are associated with a
given address.
readelf -- With this you can get various information about object files in the
ELF format. The information can be the symbols, the various headers, the
sections and many more.
strip -- With this you "delete" the symbols from object files. How this works
and what it can accomplish you will see in Chapter 5 "Stripping" and Chapter 6
"Stripping again".
c++filt -- With this it is possible to get "user-level" names of functions
written in C++ or Java from encoded -- mangled -- names so that the linker can
keep them from clashing if they are overloaded functions.

As you see the binutils package is very low-level but very important stuff.
You can see the binutils package as the bones of a GNU/Linux system.


GCC

"Gcc" refers to a collection of tools with which you can compile your sources to
binaries and executables. First there is gcc -- the gcc-core package -- . This
is a so-called "front-end". A front-end is nothing more than a service or a
process that calls other services or processes in a controlled and configurable
fashion. So you can call gcc with many, many options that control the other
called processes and the input/output of gcc. The mathematical theory that there
are more possible combinations of gcc options than atoms in the universe is an
exercise for the reader ;-) The compilation process was divided into four parts:
pre-processing, compilation, assembly and linking.
Pre-processing is done with "cccp" or "cpp". The compilation is done via "gcc"
for C sources or "g++" for C++ sources -- while "g++" is only a script to call
"gcc" with the right options to handle C++ sources-- and assembly and linking is
done with the tools from the binutils package.
So you realize part for part how the GNU world keeps turning.
cccp/cpp -> gcc/g++ -> as -> ld
The gcc-core package contains only the "front-end" with the included C compiler
and runtime libraries. We will add the g++-package in Chapter 6.

We told you that the binutils package is something like the bones of a GNU/Linux
system. The gcc package is something like the "come to life" enchantment or
breath.


GLIBC

To accomplish higher level functionality in C programs such as
input, output, mathematics, networking and other things worldwide standards
-- with names as ISO C, POSIX, SVID -- were created which define and specify
thousands of functions and their interfaces about input, output, networking and
so on. The GNU C Library -- GNU libc or glibc -- is one of the implementations
of the worldwide standards and as such the thing you use if you want to program
in C.  Every "#include <stdio.h>" will be impossible without glibc.

So we can say that glibc is the blood of the GNU/Linux system.


TCL

Tcl was developed of John Ousterhout in the late eighties. Tcl is an easy to
learn but powerful scripting language. Its interpreter is a collection of C
functions so that you can easily integrate Tcl scripts in C programs and write
in C extensions for Tcl.

EXPECT

I want to quote the description of "expect" from the Debian distribution.
 "Expect is a program that "talks" to other interactive programs
 according to a script.  Following the script, Expect knows what
 can be expected from a program and what the correct response
 should be.  An interpreted language provides branching and high-
 level control structures to direct the dialogue.  In addition,
 the user can take control and interact directly when desired,
 afterward returning control to the script."
Expect uses Tcl to accomplish its goals.

DEJAGNU

Dejagnu is an expect script and it is an abstraction layer for portable tests of
programs with the same output format. As such a script dejagnu builds a
framework for tests.

GAWK

As in the Unix world everything is a file and most files are plain text the user
gets very powerful text processing tools. Awk is one of them. Gawk is the
implementation of the GNU project.
Awk builds a programming language and was specified in the standard POSIX
1003.2. You write scripts which contain pattern-action pairs and awk processes
these scripts and looks in the given files for the patterns and executes the
actions.
In the most cases awk is combined with another tool called "sed". This pair of
tools makes you able to write controlling, manipulating and monitoring scripts
for Unix/Linux systems.

COREUTILS

With awk you have a powerful tool to manipulate the contents of a file and with
the coreutils package you get many tools to manipulate files.
Coreutils is the sum of the fileutils, the shellutils and the textutils.
Fileutils is a collection of little utilities with which you can change the
permissions on the files, list the files in a directory, create new directories,
list free disk space and many other things.
Shellutils control, manipulate and monitor your shell environment and interface.
With textutils you can process text files. For example concatenate two or more
text files to one file.

BZIP2

This package contains the utilities to compress and decompress files following
the Burrows-Wheeler block sorting text compression algorithm.
It is widely used to compress source archives as you can see from your downloads
for this book. You should use it too because it is not only free but also patent
free.

GZIP

I think the most used compression utility in the GNU world. It can also
decompress files which were compressed with "compress".

DIFFUTILS

As you work day for day with files and on the GNU/Linux systems with text files
one of the most important information is how your text files have changed over
time. With the utilities of the diffutils package you can get these
informations.
How important these utilities are you can see in the fact that "patch" relies on
"diff".

FINDUTILS
[Your description in the book is already good enough.]

MAKE

With make you write scripts in which you specify actions that will be triggered
if some files are changed. Many people describe "make" as an automation tool for
compiling but as in the UNIX world everything is a file you can do much, much
more with "make" as long as you can specify some dependencies between the files
and the actions. But "make" is mostly used for compiling :-(

GREP
[Your description is good enough.]

SED

Sed is the short form for "stream editor". While you use this tool everything is
a stream which you can edit. So you can make editing operations as in ed or vi
but you can do it "on the fly".
This is the partner for awk.

GETTEXT

It is a collection of tools which are the heart of internationalization (I18n)
and localization (L10n) on GNU systems.

NCURSES

Ncurses contains the database of terminal definitions and the tools for
manipulating it.
The secret behind terminals is that in the beginnings of the Unix systems the
users sat in front of text terminals which were connected per serial-cable with
the mainframes. For these text terminals the engineers created a little control
language so that the mainframe could say write this character to this location
on the screen. But there were a plethora of terminal control languages such as
VT100, ANSI, XTERM and so on. And today we are still emulating these terminals
to get an interface for our shell. Ncurses makes it possible.

PATCH

A tool with which you can update your copy of a file or tool or source depending
on a special diff output that was created from the owner of the file. Patch was
written by Larry Wall.

TAR

With tar you create, read and update archives that you can also compress with
gzip or bzip.



best regards
Gueven
________________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt neu bei WEB.DE FreeMail: http://freemail.web.de/?mc=021193




More information about the lfs-dev mailing list