There is a simple molecule, tetraethyldiamine, which is also known as putrescin. It gets this descriptive name because it smells like rotting flesh. It is produced by the degradation of proteins in a dead animal. Putrescin and other simple amines and sulfur-containing molecules could stay trapped in the rock until released with excavation. Just because something's been dead for millions of years doesn't mean it can't smell like anything.
Actually, you *assume* that something's been dead for 'millions of years' such that it still smells like a cadaver even after fossilization.
There is obviously no way to test this since an experiment can't last for 'millions of years'.
The fact that putrescin is still present is evidence that these fossils *aren't* 'millions of years old', not evidence that there is some unknown condition that would preserve putrescin for 'millions of years'.