Detroit automakers ink deals for self-driving cars