To call your friend's mobile from a BT landline, simply use exactly the same number that you normally do. (If you didn't know that your friend was in France, the only clue you'd get when you phoned is the different ringing tone that you'll hear from the French system).
As far as BT's charging system is concerned, it simply recognises that you've called an O2 mobile (the location is irrelevant), so you'll pay exactly the same amount as if your friend was just down the road from you.
It's your friend who will get billed for the international roaming charge. Receiving your call will cost him/her 18p per minute. (That charge applies to both monthly and pay-as-you-go tariffs).
The 'dial the normal number' rule will always work, wherever your friend might travel to. (That, of course, assumes that your friend is in a country where his/her phone will actually work). But the amount your friend will pay to receive your call can cost a great deal more outside of the EU. For example your friend would have to pay 99p per minute to receive your call if he/she was on a PAYG tariff and anywhere outside of the EU. If he/she was on a monthly tariff, and on holiday in Morocco, the charge would be £1.41 per minute.
Chris