Manjaro snort ERROR! dnet header not found

On Linux Manjaro, I want to install Snort. I attempted to install Snort using the code below but it is not listed on Pacman.

pamac build snort

I experience this error.

ERROR! dnet header not found, go get it from
code.google. com/p/libdnet/ or use the --with-dnet-*
options, if you have it installed in an unusual place
make: *** No targets specified and no makefile found. Stop.
==> ERROR: A failure occurred in build().
Aborting…

My system already has libdnet installed. I may need to download Snort from its official website, but I have no idea where to find the libdnet libraries and includes to pass as a parameter to configure.

Hi @privacycoin, and welcome!

To search where package files are locates, use

$ pamac list --files <packageName>

Where <packageName> is the name of the package’s files you’re looking for.

For example:

$ pamac list --files libdnet
/usr/bin/dnet
/usr/bin/dnet-config
/usr/include/dnet.h
/usr/include/dnet/addr.h
/usr/include/dnet/arp.h
/usr/include/dnet/blob.h
/usr/include/dnet/eth.h
/usr/include/dnet/fw.h
/usr/include/dnet/icmp.h
/usr/include/dnet/intf.h
/usr/include/dnet/ip.h
/usr/include/dnet/ip6.h
/usr/include/dnet/ndisc.h
/usr/include/dnet/os.h
/usr/include/dnet/rand.h
/usr/include/dnet/route.h
/usr/include/dnet/sctp.h
/usr/include/dnet/tcp.h
/usr/include/dnet/tun.h
/usr/include/dnet/udp.h
/usr/lib/libdnet.so
/usr/lib/libdnet.so.1
/usr/lib/libdnet.so.1.0.2
/usr/share/licenses/libdnet/license
/usr/share/man/man3/dnet.3.gz
/usr/share/man/man8/dnet.8.gz

From this we can see the librarie(s) are located in:

/usr/lib/

…as most, if not all other libraries.

Hope this helps!

Edit:

This whole post smells like an XY Problem to me.

I don’t know how you’re trying to install it, but it seems like kind of manually, while it is in the AUR:

$ pamac search snort
[...]
snort                                                                                                                                                                                                                                       3.1.50.0-1  AUR
A lightweight network IDS /IPS with OpenAppID support.

So you should be able to easily install it with:

pamac build snort

Possibly avoiding all that manual things.

Just to confirm, pamac build snort builds correctly on a clean up to date manjaro gnome VM on the stable branch.

Running on arch might need this parameter: snort --daq-dir /usr/lib/daq/ from this post.
The post also has a solution for the header error.

1 Like