I am thinking of implementing a regular expression parser in the C library that I am developing. Now the question is: is there any open source code that I could use verbatim or with minimal modifications? My expectations regarding the code:
- it needs to be written in C (not C ++)
- it must be compiled under gcc, mingw, M $ VC
- it should not depend on third-party or OS-specific headers / libraries (i.e. everything needed to compile it should be easily accessible with the basic installation of gcc, mingw, M $ VC
- it would be nice if he used Perl compatible regex syntax (like PCRE in PHP).
- ideally, the code should be as compact as possible
Are there any ready-made solutions that you could recommend? I looked at PCRE for C, and it looks like it has everything that is available in PHP (which rules), but the size (1.4MB DL) is a little intimidating. Do you think this is a solid bet? Or are there other options worth considering?
[EDIT]
The library I'm developing is an open source BSD license.
c regex parsing recommendation-engine
mingos
source share