add compat-layer for 2.5.* and 3.0
add missing compat-class for versions lower than 3.0