The Waltham drugmaker is laying off 140 people — 35% of its workforce — eliminating one of its drug programs and scaling back the European commercialization of another drug.