Skip to content

Monthly Archives: June 2008

Mandatory locks in Linux

To enable mandatory locking in Linux, the first thing to do is mount the file system with option “mand”. To apply this option to root file system, we need to modify /etc/fstab. For example:
# /etc/fstab: static file system information.
#
#

proc […]

Compiling Stevens’ example codes

To compile the example programs from Stevens’ “Advanced Programming in the UNIX Environment,” under Ubuntu, install the following package:
libc6-dev (will automatically install another package that it depends upon)
The header files are located in /usr/include.
Now, to compile, say Program 1.1, go to files/. Type “make ls1″.
./ls1 /etc
To install man pages for libraries, look for “manpages-dev” package, […]