You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
git clone https://github.com/CRC32EX/AndroidWebServer
cd AndroidWebServer
ndk-build
2. Error
$ ndk-build
[arm64-v8a] Executable : AndroidWebServer
./obj/local/arm64-v8a/objs/AndroidWebServer/__/main.o: In function `main':
C:\Users\user01\Desktop\AndroidTest/jni/../main.cpp:17: undefined reference to `mg_mgr_init(mg_mgr*)'
C:\Users\user01\Desktop\AndroidTest/jni/../main.cpp:20: undefined reference to `mg_http_listen(mg_mgr*, char const*, void (*)(mg_connection*, int, void*, void*), void*)'
C:\Users\user01\Desktop\AndroidTest/jni/../main.cpp:24: undefined reference to `mg_mgr_poll(mg_mgr*, int)'
./obj/local/arm64-v8a/objs/AndroidWebServer/__/main.o: In function `fn(mg_connection*, int, void*, void*)':
C:\Users\user01\Desktop\AndroidTest/jni/../main.cpp:7: undefined reference to `mg_http_match_uri(mg_http_message const*, char const*)'
C:\Users\user01\Desktop\AndroidTest/jni/../main.cpp:8: undefined reference to `mg_http_reply(mg_connection*, int, char const*, char const*, ...)'
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [C:/Android/ndk/21.1.6352462/build//../build/core/build-binary.mk:738: obj/local/arm64-v8a/AndroidWebServer] Error 1
Possible solution
I can compile with C code only. But I want use mongoose with C++.
main.cpp -> main.c
Environment
Windows 10 64bit 20H2
mongoose 7.3
Android NDK
$ ndk-build --version
GNU Make 4.2.1
Built for x86_64-w64-mingw32
Copyright (C) 1988-2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
The text was updated successfully, but these errors were encountered:
Steps to reproduce this issue
1. clone & build my project
2. Error
Possible solution
But I want use mongoose with C++.
Environment
The text was updated successfully, but these errors were encountered: