Makefile: Fix libiio.pc file installation

Signed-off-by: Tim Harder <timothy.harder@analog.com>
IIOD: Remove possibility to run with the XML backend

It was used for test purposes only, at the infancy of the daemon.
Removing this feature allows IIOD to run with versions of the libiio
library that don't provide the XML backend.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Makefile: Conditionally build the backends

It is now possible to de-select the local backend by setting the
environment variable WITH_LOCAL_BACKEND=no, and disable the network
backend (and by extension the XML backend) by setting the variable
WITH_NETWORK_BACKEND=no.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
examples/Makefile: Fix build issues when libiio is not yet installed

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Makefile: Generate libiio.pc from a template

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Makefile: Add install-sysroot and uninstall-sysroot targets

Those targets can be used to install the files used by the applications
that want to use libiio.

This does not change the behaviour of the "install" target.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Makefile: Move common targets and variables to one makefile.inc

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Makefile: Strip programs with the toolchain's "strip" program

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Network backend: Allow to compile without pthreads

By passing -DHAVE_PTHREAD=0 to the CPPFLAGS, the network backend can now
be compiled without using the posix threads.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Makefile: Allow to compile without threads

By passing WITH_PTHREAD=no it is now possible to build a version of
libiio that doesn't use pthreads.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>