Conrad Kramer
03/04/2022, 6:59 AMJoakim Forslund
03/04/2022, 7:05 AMConrad Kramer
03/04/2022, 7:27 AMlibcurl
is not compiled as a part of the build, but rather the system libcurl
is linked from KotlinJoakim Forslund
03/04/2022, 7:28 AMConrad Kramer
03/04/2022, 7:30 AMYou need to have thelibrary binaries on your system to make the sample work.curl
libcurl
as a part of the Gradle buildJoakim Forslund
03/04/2022, 7:30 AMConrad Kramer
03/04/2022, 7:36 AMdef
file, curl/curl.h
is put into the headers
field. If I have hello.c
and hello.h
, can I put a .c
file into the headers
field?Joakim Forslund
03/04/2022, 7:46 AMdef
file would contain
package = hello
headers = hello.h
headerFilter = hello.h
---
One way is to put your .c
code under the ---
in the def file.c
file intact, you simply pass the folder where the c files is located to compilerOptsConrad Kramer
03/04/2022, 8:07 AM---
, but I am unable to get it to work any other wayCXError_ASTReadError
if I put the .c
file in the argumentscpp-library
plugin to do the compile, and then cinterop
just for the headers.a
) or b) link a system libraryJoakim Forslund
03/04/2022, 8:12 AM.c
and the .h
file in the same folder i.e nativeInterop/cinterop/c
.
Keep the same def fileConrad Kramer
03/04/2022, 8:13 AM.c
file in the headers
arrayJoakim Forslund
03/04/2022, 8:14 AMConrad Kramer
03/04/2022, 8:27 AMcinterop
on Android, I assume I need to use androidNativeArm64
and not just android
?Joakim Forslund
03/04/2022, 8:29 AMConrad Kramer
03/04/2022, 10:30 PMstatic
(they are from an external library), I either get “symbol multiply defined” if I include the c
file or “symbol not found” if I do not