Set mtime for remote repo from a remote server.

Some proxies including nginx expect exact match for If-Modified-
Since HTTP header that means that mtime MUST be the same as it
is returned by HTTP server. Luckily libfetch parses HTTP Date
header returned by HTTP server, hence use mtime returned from
server instead of playing with 'magic' numbers, such as adding
one minute to mtime.

Begin to split pkg_update function, since it is overloaded with
code.