Step 1: Make sure you have the national Pokedex.
Step 2: Open the menu, select Pokenav, and select Match Call.
Step 3: Find a gym leader with a Poke ball-like icon next to his/her name. If there are none, then try biking around for a while (not sure exactly how long) and repeating step 2.
Step 4: Go the the gym and talk to the gym leader.