When the iPhone debuted in 2007, developers who wanted to build apps for Apple’s smartphone had just one option—make a Web app that users would access through the phone’s built-in Safari browser.