I am using the following code to test google RE2 library
int main()
{
int r = RE2::FullMatch("hello", "h.*o");
cout <<" match = " << r << endl;
return 0;
}
I am going to use the following command -
g++ -lre2 -o retest retest.cc
It compiles fine, but when I try to run a check with. / retest, it throws the following error -
error while loading shared libraries: libre2.so.0: cannot open shared object file: No such file or directory
I checked and the libre2.so.0 library exists in the user / local / lib directory and in the re2 / obj / so directory. So why this error occurs, I forget to add some details?
source
share