Painting Exterior PVC Piping Stains are designed to soak into porous surfaces. Paints leave a film o the surface. Primers are designed specifically to bond and adhere as well as block stains/lettering, etc. Primer + topcoat is better than two coats of paint. Most acrylic latex paints bond well to plastic, to the point where I don't bother with primer.
My suggestion is to check with your local paint store, as there are many new products and technologies, including paint and primer in one, paints designed specifically for plastics, and various epoxies.
Based on my 20 years of mitigation and 12 years in the remodeling business, I will say that spray paint does not hold up well over time, and that a good bonding primer and acrylic latex topcoat is the best way to go.
FYI, there are small, curved paint rollers available that are made for painting round pipe.
A nice thing about the pipe color matching the building color is that the pipe can be painted in place after installation.