who wrote to love somebody by the bee gees