nng: Build failed on MinGW (msys2-x86_64)
I’m trying to build with CMake and I get the error below.
# git branch
* (HEAD detached at v1.0.1)
master
# cmake --version
cmake version 3.12.2
# uname -a
MINGW64_NT-6.1 XXXXXXXXXX 2.11.1(0.329/5/3) 2018-09-10 14:19 x86_64 Msys
# cmake .. -DCMAKE_SYSTEM_NAME=Windows
-- The C compiler identification is GNU 8.2.0
-- Check for working C compiler: /mingw64/bin/cc.exe
-- Check for working C compiler: /mingw64/bin/cc.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Could NOT find UnixCommands (missing: TAR)
-- Check if the system is big endian
-- Searching 16 bit integer
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of unsigned short
-- Check size of unsigned short - done
-- Using unsigned short
-- Check if the system is big endian - little endian
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - found
-- Found Threads: TRUE
-- Looking for InitializeConditionVariable
-- Looking for InitializeConditionVariable - found
-- Looking for snprintf
-- Looking for snprintf - found
-- Looking for strlcat
-- Looking for strlcat - not found
-- Looking for strlcpy
-- Looking for strlcpy - not found
-- Looking for strnlen
-- Looking for strnlen - found
-- Looking for strcasecmp
-- Looking for strcasecmp - found
-- Looking for strncasecmp
-- Looking for strncasecmp - found
-- Building static libs
-- Configuring done
-- Generating done
-- Build files have been written to: /c/Data/MingGW/projects/research/nng/build
# cmake --build .
Scanning dependencies of target nng
[ 1%] Building C object src/CMakeFiles/nng.dir/nng.c.obj
In file included from C:/Data/MingGW/projects/research/nng/src/nng.c:12:
C:/Data/MingGW/projects/research/nng/src/core/nng_impl.h:13:10: fatal error: nng.h: No such file or directory
#include "nng.h"
^~~~~~~
compilation terminated.
make[2]: *** [src/CMakeFiles/nng.dir/build.make:64: src/CMakeFiles/nng.dir/nng.c.obj] Error 1
make[1]: *** [CMakeFiles/Makefile2:182: src/CMakeFiles/nng.dir/all] Error 2
make: *** [Makefile:152: all] Error 2
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 19 (8 by maintainers)
@codypiersall For me the req/rep demo worked fine with just
-lnng -lws2_32
. Did not try the other demos yet.