refactored getLibprocessFrom a little bit.