Sorry, I didn't see the question until a while after it was posted.
I use cork roadbed beneath the track. In this case, I attached it to the pink foam with a mixture of a bit of two-part epoxy with mostly Titebond II Carpenters Wood Glue (available at HD). I mark the track center line onto the foam as accurately as possible and then use weights to hold the cork in position for a day or so until the glue dries. The bond between the cork and the pink foam is very strong. I also use Atlas O track screws. It seems that the cork holds them quite well without any type of glue.
MELGAR