Yes, Spain does get pikemen, and good ones too. I expect the Holy Roman Empire might have better, but nobody else does. Swiss pikes are in the game, but only as mercenaries after a certain date. To train Tercio pikemen, a city has to get to huge unit size, and then build a Military Academy (4800 florins and 4 turns, IIRC). The academy is well worth building anyway; park a general there for a while and he'll pick up the Academy Trained trait later superceded by the Officer Training trait. These are worth +1 and +2 to command, respectively. There are no building prerequisites for the Military Academy either, just the huge size requirement. It can later be upgraded to a Royal Officer's Academy, for 9600 florins. This allows the building of Gendarmes and increases the pool of pikemen from 4 to 6 units max.

The gunpowder infantry are also trained in cities. Once gunpowder is developed, you get two new barracks buildings. The highest level barracks buildable prior to the discovery (Militia Barracks) enables the recruiting of handgunners once gunpowder is developed. Following the militia barracks, you build an Army Barracks (6 turns and 12,000 florins) to allow recruitment of Arquebusiers, and then upgrade that to a Royal Barracks (8 turns and 15,000 florins) to be able to recruit musketeers.