Allow an OBS to run off of shared infrastructure

Allow an OBS to run off of shared infrastructure, such as a GFS or NFS volume, or even just multiple disks (/srv/obs/build/ can be large volumes of cheap storage, /srv/obs/sources/ can be expensive and redundant, /srv/obs/jobs/ can be fast, /srv/obs/repos/ can be redundant and replicated, etc.).

  1) Replace the use of rename() with move().

     rename() usually does not work across filesystem boundaries. move() on
     the other hand does, and is more platform independent.

  2) Replace the use of flock() with fcntl().

     Some versions of flock() cannot lock over the network. fcntl() is
     more robust in this regard.

  3) Catch failures of link() with copy() before issuing die().

     Linking is a privilege, not a right, and does not work across
     filesystem boundaries.