MacOSX compilation problem
Hello, i have problem during OSX compilation process:
otclient/src/framework/util/crypt.cpp:270:13: error: use of undeclared identifier 'n' mpz_mul(n, p, q); ^ 1 error generated. make[2]: *** [CMakeFiles/otclient.dir/src/framework/util/crypt.cpp.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [CMakeFiles/otclient.dir/all] Error 2
I'm using https://github.com/edubart/otclient/wiki/Compiling-on-Mac-OS-X ofc I got M1 Macbook.
ofc: gmp 6.2.1_1 is already installed and up-to-date
Same on Intel MacBook.
Can you try changing https://github.com/edubart/otclient/blob/e73f6df221d9353749e044d4bdf85b5e2598d1a1/src/framework/util/crypt.cpp#L270
- mpz_mul(n, p, q);
+ mpz_mul(m_n, m_p, m_q);
GMP seems to not be working at all anyway. Just install openssl: brew install [email protected] 🙄
Tried already, any improvement
Tried already, any improvement
There are a few ways you can get cmake to find openssl on macOS, some of that, but not all, include:
- Trying to force link with brew
- Manually telling cmake where to look at by setting correct definitions with
-D - Symlinking openssl on your own
Use brew install [email protected] and next this command : export PATH="/usr/local/opt/[email protected]/bin:$PATH" with this changes in code : mpz_mul(m_n, m_p, m_q);
Use brew install [email protected] and next this command : export PATH="/usr/local/opt/[email protected]/bin:$PATH" with this changes in code : mpz_mul(m_n, m_p, m_q);
When you are using OpenSSL that part of code is not used. Anyway, it does not fix anything, as GMP integration seems to be broken.
any ideas?
Can you try changing
https://github.com/edubart/otclient/blob/e73f6df221d9353749e044d4bdf85b5e2598d1a1/src/framework/util/crypt.cpp#L270
- mpz_mul(n, p, q); + mpz_mul(m_n, m_p, m_q);
this did it for me. thanks!