Table of Contents
In this article, I will take you through the steps to install autoconf on Ubuntu 20.04 LTS. According to GNU Official website, Autoconf is an extensible package of M4 macros that produce shell scripts to automatically configure software source code packages. These scripts can adapt the packages to many kinds of UNIX-like systems without manual user intervention. Autoconf creates a configuration script for a package from a template file that lists the operating system features that the package can use, in the form of M4 macro calls.
How to Install Autoconf on Ubuntu 20.04 LTS
Also Read: How to Install and Use Docker on Ubuntu 20.04 LTS [Step by Step]
Step 1: Prerequisites
a) You should have a running Ubuntu 20.04 LTS
Server.
b) You should have sudo
or root
access to run privileged command.
c) You should have apt
or apt-get
utility available in your System.
Step 2: Update Your Server
First you need to update your Server using apt update
or apt-get update
command as shown below. If needed, you can also run apt upgrade
or apt-get upgrade
to install the latest security patches and upgrade all the installed packages to the latest version.
root@cyberithub:~# apt update
Hit:1 http://in.archive.ubuntu.com/ubuntu focal InRelease
Hit:2 http://in.archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:3 http://in.archive.ubuntu.com/ubuntu focal-backports InRelease
Hit:4 https://download.docker.com/linux/ubuntu focal InRelease
Ign:5 http://ppa.launchpad.net/bitcoin/bitcoin/ubuntu focal InRelease
Hit:6 https://dl.google.com/linux/chrome/deb stable InRelease
Hit:7 http://security.ubuntu.com/ubuntu focal-security InRelease
Ign:8 https://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.0 InRelease
Hit:9 https://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.0 Release
Hit:10 https://artifacts.elastic.co/packages/oss-7.x/apt stable InRelease
Step 3: Install Autoconf
To install autoconf and all its dependencies, you need to use apt-get install autoconf
command as shown below.
root@cyberithub:~# apt-get install autoconf
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
automake autotools-dev libsigsegv2 m4
Suggested packages:
autoconf-archive gnu-standards autoconf-doc libtool gettext m4-doc
The following NEW packages will be installed:
autoconf automake autotools-dev libsigsegv2 m4
0 upgraded, 5 newly installed, 0 to remove and 43 not upgraded.
Need to get 1,096 kB of archives.
After this operation, 4,050 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://in.archive.ubuntu.com/ubuntu focal/main amd64 libsigsegv2 amd64 2.12-2 [13.9 kB]
Get:2 http://in.archive.ubuntu.com/ubuntu focal/main amd64 m4 amd64 1.4.18-4 [199 kB]
Get:3 http://in.archive.ubuntu.com/ubuntu focal/main amd64 autoconf all 2.69-11.1 [321 kB]
Get:4 http://in.archive.ubuntu.com/ubuntu focal/main amd64 autotools-dev all 20180224.1 [39.6 kB]
Get:5 http://in.archive.ubuntu.com/ubuntu focal/main amd64 automake all 1:1.16.1-4ubuntu6 [522 kB]
Fetched 1,096 kB in 1s (837 kB/s)
Selecting previously unselected package libsigsegv2:amd64.
(Reading database ... 213396 files and directories currently installed.)
Preparing to unpack .../libsigsegv2_2.12-2_amd64.deb ...
Unpacking libsigsegv2:amd64 (2.12-2) ...
Step 4: Verify Installation
After successful installation, you can verify the list of installed files by using dpkg -L autoconf
command as shown below.
root@cyberithub:~# dpkg -L autoconf
/.
/etc
/etc/emacs
/etc/emacs/site-start.d
/etc/emacs/site-start.d/50autoconf.el
/usr
/usr/bin
/usr/bin/autoconf
/usr/bin/autoheader
/usr/bin/autom4te
/usr/bin/autoreconf
/usr/bin/autoscan
/usr/bin/autoupdate
/usr/bin/ifnames
/usr/share
/usr/share/autoconf
/usr/share/autoconf/Autom4te
/usr/share/autoconf/Autom4te/C4che.pm
/usr/share/autoconf/Autom4te/ChannelDefs.pm
Step 5: Check Autoconf Version
Then check the currently installed version by using autoconf --version
command as shown below.
root@cyberithub:~# autoconf --version
autoconf (GNU Autoconf) 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+/Autoconf: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>, <http://gnu.org/licenses/exceptions.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by David J. MacKenzie and Akim Demaille.
Step 6: Check all the available options
You can check all the options available with autoconf command using autoconf --help
command as shown below.
root@cyberithub:~# autoconf --help
Usage: /usr/bin/autoconf [OPTION]... [TEMPLATE-FILE]
Generate a configuration script from a TEMPLATE-FILE if given, or
`configure.ac' if present, or else `configure.in'. Output is sent
to the standard output if TEMPLATE-FILE is given, else into
`configure'.
Operation modes:
-h, --help print this help, then exit
-V, --version print version number, then exit
-v, --verbose verbosely report processing
-d, --debug don't remove temporary files
-f, --force consider all files obsolete
-o, --output=FILE save output in FILE (stdout is the default)
-W, --warnings=CATEGORY report the warnings falling in CATEGORY [syntax]
Step 7: Uninstall Autoconf
In case you want to remove autoconf package from your System then all you need to run is apt-get remove autoconf
command.
root@cyberithub:~# apt-get remove autoconf
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
ibverbs-providers icu-devtools libboost-atomic-dev libboost-atomic1.71-dev libboost-atomic1.71.0 libboost-chrono-dev libboost-chrono1.71-dev
libboost-chrono1.71.0 libboost-container-dev libboost-container1.71-dev libboost-container1.71.0 libboost-context-dev libboost-context1.71-dev
libboost-context1.71.0 libboost-coroutine-dev libboost-coroutine1.71-dev libboost-coroutine1.71.0 libboost-date-time-dev libboost-date-time1.71-dev
libboost-dev libboost-exception-dev libboost-exception1.71-dev libboost-fiber-dev libboost-fiber1.71-dev libboost-fiber1.71.0 libboost-filesystem-dev
libboost-filesystem1.71-dev libboost-graph-dev libboost-graph-parallel-dev libboost-graph-parallel1.71-dev libboost-graph-parallel1.71.0