The warm-up game is scheduled to take place on January 14 at the Estadio Olímpico de Sevilla.
Ahead of that game, the Black Stars will face off with Portuguese lower side Olhanense on Wednesday as the four-time African champions train in Spain for the continental showpiece.
The game will be staged at the Algarve Stadium in Portugal meaning the team will be travelling just across the border for the friendly before coach Avram Grant names his final 23-man squad for the Nations Cup.
The Ghana FA has hinted that talks are underway for another friendly against Dutch top-flight side Cambuur Leeuwarden.
The Black Stars have been drawn in a tough group to face Senegal, Algeria and South Africa.