The caulk will adhere fine without a prime first but, like they mentioned above me, you will see cracking in the painted surface if you paint before the caulk has had enough time to fully dry. The outer surface, the paint, will dry first and as the interior of the caulk bead sets it will shrink. The shrinking will force the paint to fold and crack.
They may both be a latex, or acrylic, but they are not the same formulation.