pcre: split the module into a ffi part and a main part for easier maintanability