nowsecure / r2frida

Radare2 and Frida better together.
MIT License
1.18k stars 121 forks source link

Can't find OpenSSL includes on macOS High Sierra #77

Closed tanis2000 closed 6 years ago

tanis2000 commented 6 years ago

It looks like the install process can't find the OpenSSL includes on macOS High Sierra. Here's the log:

$ r2pm install r2frida
syntax error: error in error handling
syntax error: error in error handling
syntax error: error in error handling
Already up-to-date.
Install Done For r2frida
[ "`readlink ext/frida`" = frida-macos-10.6.13 ] || \
        (cd ext && rm -f frida ; ln -fs frida-macos-10.6.13 frida)
make io_frida.dylib
cc -c -fPIC -I/usr/local/Cellar/radare2/2.0.1/include/libr -DWITH_CYLANG=0 -Iext/frida src/io_frida.c -o src/io_frida.o
In file included from src/io_frida.c:3:
In file included from /usr/local/Cellar/radare2/2.0.1/include/libr/r_core.h:6:
/usr/local/Cellar/radare2/2.0.1/include/libr/r_socket.h:28:10: fatal error: 'openssl/ssl.h' file not found
#include <openssl/ssl.h>
         ^~~~~~~~~~~~~~~
1 error generated.
make[1]: *** [src/io_frida.o] Error 1
make: *** [all] Error 2
ERROR: Build failed
trufae commented 6 years ago

This seems to be an issue with the pkgconfig files of r2. Usually few people builds r2 with openssl as dependency, so the .pc files doesnt add the CFLAGS/LDFLAGS for that. Not sure if r2frida will work with last r2 release. so ideally i would recommend to install r2 from git, but ill fill an issue in r2 to track and solve this.

Thanks

tanis2000 commented 6 years ago

I'm using the r2 that can be downloaded through Homebrew... it's version 2.0.1 and it looks like the latest release at the time I'm writing this. I'll have a go with the git version of r2 and see if anything changes. Cheers!

tanis2000 commented 6 years ago

Just confirming that using r2 from git does solve the issue.

trufae commented 6 years ago

Should be fixed in here https://github.com/radare/radare2/commit/75066808c779d1541a0ccf42f46b8e60863f8ec3

so r2-2.1 will work fine if installed from brew with r2frida

thanks for reporting!