I separated the class-files in my model into different folders (lib/model and lib/tecdoc). If I use the admin generator for a class inside lib/tecdoc it fails.
The class cannot be found, because the getModelDirs of the sfLoader-class does not give me the tecdoc subfolder. And thats why loadMapBuilderClasses in sfPropelCrudGenerator fails.
An easy solution would be to allow a configuration setting to let the user define the directories which are evaluated by the generator class.
// Check if there are extended directories set and add them to the array
// of directories the `sfFinder` will look later on
if (is_array (sfConfig::get ('sf_lib_dir_extend')))
{
$dirs = array_merge ($dirs, sfConfig::get ('sf_lib_dir_extend'));
}
So I define this setting in my backend settings.yml like
lib_dir_extend: [%SF_LIB_DIR%/tecdoc]
Now everything works as expected.