build: Separate building programs linking against libav* from building av*

This will allow cleaner integration of building example programs.
build: Integrate multilibrary examples into the build system

This includes moving libavformat/output-example to doc/examples/output.