Apple, Qualcomm reach settlement over royalty lawsuits