Files show UK, US spy agencies 'links' with Gaddafi regime