Fixed package loop to use arbitrary package, could be improved but atm not a major focus.