Animals like cows, pigs, chickens, horses... used to spawn only on grass (and maybe other "natural blocks" like dirt). Some other animals have different conditions (e.g. desert rabbits spawn on sand).
In 1.8.0.11 Beta however, animals spawn on any blocks, e.g. on top of buildings made of stone bricks, which is a bug I think.
To reproduce, the simplest is to create a flat world in creative/peaceful, then make a large platform of stone bricks:
/fill 0 ~ 0 -150 ~ -150 stonebrick
/fill 0 ~ 0 -150 ~ 150 stonebrick
/fill 0 ~ 0 150 ~ -150 stonebrick
/fill 0 ~ 0 150 ~ 150 stonebrick
Then kill all animals
/kill @e[type=!player]
You will see new animals (pigs, cows, chickens...) spawn immediately, on the stonebrick platform
Linked issues
Comments 3
We are now in 1.9 Sheeps, Cows, Chickens and pigs are spawning on Cobblestone, Stone Granite, Etc... Needs to be just grass/dirt.
Forward-resolving as duplicate of MCPE-39727, in favor of being updated more often.
In current beta 1.10.0.4, this seems to be fixed for pigs, cows, sheep. However the bug is still there for other animals like horses and llamas.