-
Notifications
You must be signed in to change notification settings - Fork 8
AutoconfAutomake
Tom Mitchell edited this page Jun 11, 2015
·
1 revision
The Portal software uses GNU Autoconf and GNU Automake for portability and configuration. There are a number of files involved, and a number of things to know.
To Do:
- What does autoconf do?
- What does automake do?
- Note: adding new files for installation
- Note: removing files
configure.ac
Makefile.am
<subdir>/Makefile.am
Autoconf turns the configure.ac
file into a configure
script that is used to learn about the local environment and generate Makefiles.
The Makefile
s are generated from the Makefile.am
files by the configure script using automake.
- After cloning via git, or copying files to a host for installation, the first step is to generate the
configure
script fromconfigure.ac
. The easiest thing to do is runautoreconf
to create it even if it already exists:autoreconf --install
- Next, run the
configure
script. We generally pass additional arguments to specify the destination of files. The--prefix
and--sysconfdir
arguments in this command arerequired
for the software to operate. The--bindir
and--sbindir
arguments are suggested:./configure --prefix=/usr --sysconfdir=/etc --bindir=/usr/local/bin --sbindir=/usr/local/sbin
- Next, run
make
- Finally, run
make install
to install the software on the target host. You will almost certainly have to run this with elevated privileges.