Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

will not build on MACOSX #2669

Open
a8underscore opened this issue Apr 26, 2020 · 7 comments
Open

will not build on MACOSX #2669

a8underscore opened this issue Apr 26, 2020 · 7 comments

Comments

@a8underscore
Copy link

a8underscore commented Apr 26, 2020

... are the placeholder for your answers. Please answer each question!

Describe the bug
A clear and concise description of what the bug is.

it wont compile

**Which operating system do you use? **

MACOSX 10.15.4

To Reproduce
I am not sure

Please post all commands and the output.

[ 88%] Building CXX object CMakeFiles/xmr-stak-backend.dir/xmrstak/net/socket.cpp.o
/Users/nikita/Desktop/xmr-stak/xmrstak/net/socket.cpp:221:8: error: no matching
function for call to 'SSL_CTX_new'
ctx = SSL_CTX_new(method);
^~~~~~~~~~~
/usr/local/include/openssl/ssl.h:1438:10: note: candidate function not viable:
1st argument ('const SSL_METHOD *' (aka 'const ssl_method_st *')) would
lose const qualifier
SSL_CTX *SSL_CTX_new(SSL_METHOD *meth);
^
1 error generated.
make[2]: *** [CMakeFiles/xmr-stak-backend.dir/xmrstak/net/socket.cpp.o] Error 1
make[1]: *** [CMakeFiles/xmr-stak-backend.dir/all] Error 2
make: *** [all] Error 2

Additional information.

I also have this issue with XMRIG

run cmake -LA . in the build folder and add the output here

-- Configuring done
-- Generating done
-- Build files have been written to: /Users/nikita/Desktop/xmr-stak
-- Cache values
CMAKE_ADDR2LINE:FILEPATH=CMAKE_ADDR2LINE-NOTFOUND
CMAKE_AR:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/ar
CMAKE_ASM_COMPILER:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/cc
CMAKE_ASM_COMPILER_AR:FILEPATH=CMAKE_ASM_COMPILER_AR-NOTFOUND
CMAKE_ASM_COMPILER_RANLIB:FILEPATH=CMAKE_ASM_COMPILER_RANLIB-NOTFOUND
CMAKE_ASM_FLAGS:STRING=
CMAKE_ASM_FLAGS_DEBUG:STRING=-g
CMAKE_ASM_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
CMAKE_ASM_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
CMAKE_ASM_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
CMAKE_BUILD_TYPE:STRING=Release
CMAKE_COLOR_MAKEFILE:BOOL=ON
CMAKE_CXX_COMPILER:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/c++
CMAKE_CXX_FLAGS:STRING=
CMAKE_CXX_FLAGS_DEBUG:STRING=-g
CMAKE_CXX_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
CMAKE_CXX_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
CMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
CMAKE_C_COMPILER:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/cc
CMAKE_C_FLAGS:STRING=
CMAKE_C_FLAGS_DEBUG:STRING=-g
CMAKE_C_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
CMAKE_C_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
CMAKE_C_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
CMAKE_DLLTOOL:FILEPATH=CMAKE_DLLTOOL-NOTFOUND
CMAKE_EXECUTABLE_FORMAT:STRING=MACHO
CMAKE_EXE_LINKER_FLAGS:STRING=
CMAKE_EXE_LINKER_FLAGS_DEBUG:STRING=
CMAKE_EXE_LINKER_FLAGS_MINSIZEREL:STRING=
CMAKE_EXE_LINKER_FLAGS_RELEASE:STRING=
CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
CMAKE_EXPORT_COMPILE_COMMANDS:BOOL=
CMAKE_INSTALL_NAME_TOOL:FILEPATH=/usr/bin/install_name_tool
CMAKE_INSTALL_PREFIX:PATH=/Users/nikita/Desktop/xmr-stak
CMAKE_LINKER:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/ld
CMAKE_LINK_STATIC:BOOL=OFF
CMAKE_MAKE_PROGRAM:FILEPATH=/usr/bin/make
CMAKE_MODULE_LINKER_FLAGS:STRING=
CMAKE_MODULE_LINKER_FLAGS_DEBUG:STRING=
CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL:STRING=
CMAKE_MODULE_LINKER_FLAGS_RELEASE:STRING=
CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
CMAKE_NM:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/nm
CMAKE_OBJCOPY:FILEPATH=CMAKE_OBJCOPY-NOTFOUND
CMAKE_OBJDUMP:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/objdump
CMAKE_OSX_ARCHITECTURES:STRING=
CMAKE_OSX_DEPLOYMENT_TARGET:STRING=
CMAKE_OSX_SYSROOT:PATH=/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk
CMAKE_RANLIB:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/ranlib
CMAKE_READELF:FILEPATH=CMAKE_READELF-NOTFOUND
CMAKE_SHARED_LINKER_FLAGS:STRING=
CMAKE_SHARED_LINKER_FLAGS_DEBUG:STRING=
CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL:STRING=
CMAKE_SHARED_LINKER_FLAGS_RELEASE:STRING=
CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO:STRING=
CMAKE_SKIP_INSTALL_RPATH:BOOL=NO
CMAKE_SKIP_RPATH:BOOL=NO
CMAKE_STATIC_LINKER_FLAGS:STRING=
CMAKE_STATIC_LINKER_FLAGS_DEBUG:STRING=
CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL:STRING=
CMAKE_STATIC_LINKER_FLAGS_RELEASE:STRING=
CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO:STRING=
CMAKE_STRIP:FILEPATH=/Library/Developer/CommandLineTools/usr/bin/strip
CMAKE_VERBOSE_MAKEFILE:BOOL=FALSE
CPU_ENABLE:BOOL=ON
CUDA_ENABLE:BOOL=OFF
EXECUTABLE_OUTPUT_PATH:STRING=bin
HWLOC:FILEPATH=/usr/local/lib/libhwloc.dylib
HWLOC_ENABLE:BOOL=ON
HWLOC_INCLUDE_DIR:PATH=/usr/local/include
LIBRARY_OUTPUT_PATH:STRING=bin
MHTD:FILEPATH=/usr/local/lib/libmicrohttpd.dylib
MICROHTTPD_ENABLE:BOOL=ON
MTHD_INCLUDE_DIR:PATH=/usr/local/include
OPENSSL_CRYPTO_LIBRARY:FILEPATH=/usr/local/opt/openssl/lib/libcrypto.dylib
OPENSSL_INCLUDE_DIR:PATH=/usr/local/opt/openssl/include
OPENSSL_SSL_LIBRARY:FILEPATH=/usr/local/opt/openssl/lib/libssl.dylib
OpenCL_ENABLE:BOOL=OFF
OpenSSL_ENABLE:BOOL=ON
PKG_CONFIG_EXECUTABLE:FILEPATH=/usr/local/bin/pkg-config
XMR-STAK_COMPILE:STRING=native
pkgcfg_lib__OPENSSL_crypto:FILEPATH=/usr/local/lib/libcrypto.a
pkgcfg_lib__OPENSSL_ssl:FILEPATH=/usr/local/lib/libssl.a
Feel free to add more information.

...
@a8underscore a8underscore changed the title will not build will not build on MACOSX Apr 26, 2020
@a8underscore
Copy link
Author

bump

@mvarie
Copy link

mvarie commented Jun 8, 2020

Confirmed, it doesn't build on macOS 10.15.4, gcc Apple clang version 11.0.3 (clang-1103.0.32.62).

/Users/marcantonio/work/xmr/xmr-stak/xmrstak/backend/cpu/crypto/cryptonight_aesni.h:580:13: note: candidate function not viable: no known conversion from
      'GetOptimalSqrtType_t<N>' (aka 'GetOptimalSqrtType') to 'uint64_t &' (aka 'unsigned long long &') for 1st argument
inline void assign(uint64_t& output, const uint64_t input)
            ^
/Users/marcantonio/work/xmr/xmr-stak/xmrstak/backend/cpu/crypto/cryptonight_aesni.h:585:13: note: candidate function not viable: no known conversion from
      'GetOptimalSqrtType_t<N>' (aka 'GetOptimalSqrtType') to 'uint64_t &' (aka 'unsigned long long &') for 1st argument
inline void assign(uint64_t& output, const __m128i& input)
            ^
/Users/marcantonio/work/xmr/xmr-stak/xmrstak/backend/cpu/crypto/cryptonight_aesni.h:1005:16: error: use of undeclared identifier 'keccak'
                REPEAT_2(11, CN_INIT, monero_const, conc_var, l0, ax0, bx0, idx0, ptr0, bx1, sqrt_result, division_result_xmm, cn_r_data);
                             ^
/Users/marcantonio/work/xmr/xmr-stak/xmrstak/backend/cpu/crypto/cryptonight_aesni.h:1005:16: warning: use of function template name with no prior declaration in function
      call with explicit template arguments is a C++2a extension [-Wc++2a-extensions]
fatal error: too many errors emitted, stopping now [-ferror-limit=]
6 warnings and 20 errors generated.
make[2]: *** [CMakeFiles/xmr-stak-backend.dir/xmrstak/backend/cpu/crypto/CryptonightR_gen.cpp.o] Error 1
make[1]: *** [CMakeFiles/xmr-stak-backend.dir/all] Error 2
make: *** [all] Error 2

@krrkrr
Copy link

krrkrr commented Sep 8, 2020

it doesn't build on any version of macOS X, from High Sierra to Catalina...

here's my error:

/etc/ix105/xmr-stak-1.0.5-rx/./xmrstak/backend/cryptonight.hpp:44:13: warning: result of comparison of constant 1000 with expression of type 'xmrstak_algo_id' is always true
      [-Wtautological-constant-out-of-range-compare]
        if(algo_id < start_derived_algo_id)
           ~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
[ 65%] Building CXX object CMakeFiles/xmr-stak-rx-backend.dir/xmrstak/backend/globalStates.cpp.o
[ 68%] Building CXX object CMakeFiles/xmr-stak-rx-backend.dir/xmrstak/http/httpd.cpp.o
In file included from /etc/ix105/xmr-stak-1.0.5-rx/xmrstak/http/httpd.cpp:28:
In file included from /etc/ix105/xmr-stak-1.0.5-rx/./xmrstak/jconf.hpp:4:
In file included from /etc/ix105/xmr-stak-1.0.5-rx/./xmrstak/misc/coinDescription.hpp:3:
/etc/ix105/xmr-stak-1.0.5-rx/./xmrstak/backend/cryptonight.hpp:44:13: warning: result of comparison of constant 1000 with expression of type 'xmrstak_algo_id' is always true
      [-Wtautological-constant-out-of-range-compare]
        if(algo_id < start_derived_algo_id)
           ~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~
/etc/ix105/xmr-stak-1.0.5-rx/xmrstak/http/httpd.cpp:160:6: error: no matching function for call to 'MHD_start_daemon'
        d = MHD_start_daemon(MHD_USE_THREAD_PER_CONNECTION,
            ^~~~~~~~~~~~~~~~
/usr/local/include/microhttpd.h:2425:1: note: candidate function not viable: no known conversion from 'int (*)(void *, MHD_Connection *, const char *, const char *, const char *, const char
      *, size_t *, void **)' (aka 'int (*)(void *, MHD_Connection *, const char *, const char *, const char *, const char *, unsigned long *, void **)') to 'MHD_AccessHandlerCallback' (aka
      'MHD_Result (*)(void *, MHD_Connection *, const char *, const char *, const char *, const char *, unsigned long *, void **)') for 5th argument
MHD_start_daemon (unsigned int flags,
^
1 warning and 1 error generated.
make[2]: *** [CMakeFiles/xmr-stak-rx-backend.dir/xmrstak/http/httpd.cpp.o] Error 1
make[1]: *** [CMakeFiles/xmr-stak-rx-backend.dir/all] Error 2
make: *** [all] Error 2

It does the same error with 1.0.4 ... except it stopped at 63% and not at 68% ....

@Gutigno
Copy link

Gutigno commented Nov 10, 2020

same for me, please someone have a solution?

@floydnoel
Copy link

Only solution I've found, but it worked for me: http://downloads.fabulouspanda.com/xmrstak/

@antt001
Copy link

antt001 commented Apr 10, 2021

to work around MHD_start_daemon error, you can disable microhttpd using : -DMICROHTTPD_ENABLE=OFF

@barracuda156
Copy link

Anyone has a fix for error: no matching function for call to 'MHD_start_daemon'? I get this error when building Akumuli with Clang: macports/macports-ports#15631 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants