diff options
author | Joachim Nilsson <troglobit@gmail.com> | 2019-09-28 13:30:55 +0200 |
---|---|---|
committer | Joachim Nilsson <troglobit@gmail.com> | 2019-09-28 13:30:55 +0200 |
commit | dda691d94726f23f8fdac581198d9b0eec2d8db0 (patch) | |
tree | f58eb8b247c6d05d2f1d4fc0241b4648efc2d820 /doc/libnet-config.Pod | |
parent | 39d3f28a12cdbd817294262025d84a30815f8887 (diff) | |
parent | 5e93c69e3b6966bf2ff7af3d32122d23fea01450 (diff) | |
download | libnet-dda691d94726f23f8fdac581198d9b0eec2d8db0.tar.gz |
Merge branch 'master' of https://github.com/sgeto/libnet into sgeto-master
Conflicts:
.gitignore
.travis.yml
BUILD-FROM-GIT.txt
Makefile.am
Makefile.am.common
Prepare
acinclude.m4
autogen.sh
configure.ac
doc/html/Makefile.am
doc/html/closed.png
doc/html/globals_func.html
doc/html/tab_s.png
doc/libnet.doxygen.conf
doc/man/Makefile.am
doc/man/man3/Makefile.am
doc/man/man3/libnet-functions.h.3
doc/man/man3/libnet-macros.h.3
include/libnet.h
include/libnet/Makefile.am
libnet/acinclude.m4
libnet/libnet-config.in
libnet/m4/acinclude.m4
lua/Makefile
lua/msvcbuild.bat
sample/Makefile.am
scripts/Push
src/libnet_link_win32.c
win32/Makefile.am
Diffstat (limited to 'doc/libnet-config.Pod')
-rw-r--r-- | doc/libnet-config.Pod | 92 |
1 files changed, 92 insertions, 0 deletions
diff --git a/doc/libnet-config.Pod b/doc/libnet-config.Pod new file mode 100644 index 0000000..91ca1e7 --- /dev/null +++ b/doc/libnet-config.Pod @@ -0,0 +1,92 @@ +=pod + +=encoding utf8 + +=head1 NAME + +libnet-config - script to get information about, and for linking against libnet + +=head1 SYNOPSIS + +B<libnet-config [--help] | [--version] | [--prefix] | [--libs --cflags --defines]> + +=head1 DESCRIPTION + +libnet-config tells the application programmer what flags to use to compile and +link programs against an installed L<libnet> library. + +An alternative (and perhaps more convenient) method of retrieving the various +configuration information needed to compile programs that use libnet is to use +the L<pkg-config(1)> program. Pkg-config support was added in version 1.2. + +Both methods write to standard output the flags that should be used to compile +and link programs that use libnet. + +=head1 OPTIONS + +=over 8 + +=item B<--help> + +Print a usage message and exit. This is the default behavior when no options are +specified. + +=item B<--version> + +Print version information and exit. + +=item B<--libs> + +Print the linker flags (LDFLAGS) that are necessary to link a programs with +libnet. + +=item B<--cflags> + +Print the compiler options (CFLAGS) to use when compiling files that use libnet. +Currently that is only the include path to the libnet include files. + +=item B<--defines> + +Print the pre-processor definitions libnet was compiler with. + +=item B<--prefix> + +Print the prefix used when libnet was installed. The prefix can be set during +the build process with "configure --prefix". + +=back + +=head1 EXAMPLES + +To print all linker options needed when linking with libnet, use + +B<C<libnet-config --libs>> + +To build the singe-file C program 'prog' against the libnet library, use + +B<C<gcc $(libnet-config --cflags --defines --libs) progr.c -o progr>> + +The same in a Makefile: + +B<CFLAGS+=$(shell libnet-config --cflags --defines )> + +B<LDFLAGS+=$(shell libnet-config --libs)> + +B<all: prog> + +To build a dynamically loadable libnet module, use + +B<C<gcc $(libnet-config --cflags --defines --libs) -shared -fPIC progr.cpp -o progr.so>> + +Note that libnet-config can also be called from 'configure' scripts. + +=head1 SEE ALSO + +L<libnet(3)>, L<pkg-config(1)> + +=head1 AUTHORS + +This manual page was written by Ali Abdulkadir <autostart.ini@gmail.com> + +=cut + |