Former Barcelona and Real Madrid striker Javier Saviola has joined Olympiacos, the Greek club have confirmed.