Problem with reaver on Ubuntu 18.04 [duplicate]

So I was following up with this link https://www.learn2crack.com/2013/07/learn-to-hack-wifi-password-with-ubuntu.html
I'm stuck with the 7th step. I'm pasting the output of the 6th step just in case if the error is somewhere over there.

root@Sphinx-PC:~/reaver-1.4/src# ./configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for pcap_open_live in -lpcap... no
error: pcap library not found!
root@Sphinx-PC:~/reaver-1.4/src# make
make: *** No targets specified and no makefile found.  Stop.
root@Sphinx-PC:~/reaver-1.4/src# make
make: *** No targets specified and no makefile found.  Stop.
root@Sphinx-PC:~/reaver-1.4/src# make install
make: *** No rule to make target 'install'.  Stop.
root@Sphinx-PC:~/reaver-1.4/src#"

enter image description here


Solution 1:

At first ensure that you have enabled all repositories in your system:

sudo add-apt-repository main
sudo add-apt-repository universe
sudo add-apt-repository multiverse
sudo apt-get update

You do not need to compile reaver by yourself since it is packaged with version 1.4-2build1. Use:

sudo apt-get install reaver

If you still need to compile it (with custom ./configure options or just for new experience) - you should enable Source code repositories in Software & Updates (software-properties-gtk) and install its build-dependencies with

sudo apt-get build-dep reaver

and then continue with ./configure.