Source

mirage2iso / INSTALL

Full commit
* mirage2iso install guide *


1. PREREQUISITES

 * C99-capable C toolkit,
 * libmirage < 1.2,
 * pkg-config.


2. CONFIGURATION

If you don't have pkg-config or libmirage < 1.2 installed, expect
standard compilation failure with some less or more readable output.

You can either let mirage2iso's Makefile shortly determine few
capabilites of your system by calling:
	$ make configure
or directly provide correct defines as CPPFLAGS to make. You can use
following defines to disable particular features:
	-DNO_GETOPT_LONG (GNU extension)
		disable use of getopt_long() in favor of internal parser
	-DNO_SYSEXITS (BSD)
		disable use of <sysexits.h> header in favor of hardcoded values
	-DNO_MMAPIO (POSIX)
		disable use of ftruncate() and mmap() to get mmaped I/O

You can use -DNO_GNU, -DNO_BSD and -DNO_POSIX too, to disable all
functions which require given standard. Note that disabling POSIX
implies disabling BSD&GNU extensions too, and diabling BSD implies
disabling GNU.


3. COMPILATION

It's all just plain make. It uses following variables either provided
in command-line or gathered from environment:
	CC, CFLAGS, LDFLAGS

If your environment is set right, you may compile it by calling:
	$ make

If you didn't use 'make configure', you should use CPPFLAGS to define
compile options like:
	$ make CPPFLAGS='-DNO_POSIX'
to compile on non-POSIX systems. Note that if you want to use
'configure' results, you have to either leave CPPFLAGS undefined
or specify '-DUSE_CONFIG' within.


4. INSTALLATION

The Makefile provides 'install' target with following variables
for fine-tuning installation location:
	DESTDIR, PREFIX, BINDIR

mirage2iso doesn't internally depend on any of these paths (it is 100%
location-independent) you may set them to anything. But the preferred
solution is to use PREFIX as system-wide install prefix (like '/usr')
and DESTDIR for fake root installs.

To install mirage2iso into /usr/local tree just call:
	# make install
But when creating packages you should probably instead use:
	# make PREFIX=/usr DESTDIR="${D}" install
where "${D}" is the fake root dir.


* (c) 2009 Michał Górny, released under 3-clause BSD license *