Reorg a bit, introduce a control struct
condense some globals, more tidying up
handle RootDir and DBPath from pacman config
add --config option to point at another pacman.conf