Martinez, who missed a penalty at the end of the first half, was less forgiving after the break and bundled the ball home from close range on 56 minutes.
Yacine Brahimi made the most of a simple chance to wrap up the points with 17 minutes remaining when Athletic keeper Gorka Iraizoz failed to control a back pass.
Porto lead Group H with 10 points from four games while Shakhtar Donetsk, who beat BATE Borisov 5-0 are two points behind.
Athletic qualified for the Champions League group stage for the first time in 16 years, but a sorry run of results means they have just one point and are now eliminated.
“As a group we played well together and doing that it gives you the chance to win big things. We worked hard, we knew it would be difficult and we would be under pressure,鈥?a bullish Martinez told reporters.
鈥淵ou can鈥檛 put limits on this side but we know where we are aiming at which is the final, God willing.鈥?/p>
His optimism was shared by Porto coach Julen Lopetegui.
鈥淲e are a young team working hard and I am very happy with the way things are going,鈥?he told reporters.
“This is just the first stage for us though and the best moments are still to come.”
There was only disappointment for the Athletic players.
“It was a difficult game for us and we tried our best but it wasn’t possible,” Bilbao striker Guillermo Fernandez told reporters.
“We could not turn the game around and it is a blow for us.
“It was hard as we were pressed back and could not create very much. We did more in the second half but it did not work out.”
Athletic were missing the injured Aritz Aduriz and Iker Muniain was only fit to start as a substitute, while the quality of Porto鈥檚 attack meant that they could afford to leave Ricardo Quaresma on the bench.
Martinez was inches away from giving them the lead early on when he nipped in at the near post to meet a Danilo cross and shot just wide.
A Maicon free kick from distance was turned away by Iraizoz and from the resulting corner Martinez headed the wrong side of the post.
Porto had a golden chance to go ahead three minutes before the break when Mikel Balenziaga upended Danilo in the box but Martinez failed to find the back of the net with his spot kick.
After the restart Brahimi made a good run down the left and laid the ball on a plate for Martinez to score from two metres out.
An embarrassing mistake then followed when Iraizoz gave the ball to Brahimi to score, summing up a poor night for Bilbao.
(Reporting by Tim Hanlon in Barcelona; editing by Toby Davis)