I'm getting this error when trying to compile a ba...
# kotlin-native
e
I'm getting this error when trying to compile a basic project that includes the dokany headers:
Copy code
D:\workspace\konan\build\konan\nativelibs\genDokanyInteropStubs\dokanystubs.c:2222:21: error: always_inline function '_cvtsh_ss' requires target feature 'sse4.1', but would be inlined into function 'dokany_kni__cvtsh_ss' that is compiled without support for 'sse4.1'
    return (float) (_cvtsh_ss((unsigned short)__a));
                    ^
Copy code
D:\workspace\konan\build\konan\libs\mingw\dokany.klib-build\natives\cstubs.c:2222:21: error: always_inline function '_cvtsh_ss' requires target feature 'sse4.1', but would be inlined into function 'dokany_kni__cvtsh_ss' that is compiled without support for 'sse4.1'
    return (float) (_cvtsh_ss((unsigned short)__a));
m
Maybe
Copy code
depends = windows
in .def file will help
e
@msink tried that with the same results
m
What you trying to do - is it buildable by MSYS2 clang, without Kotlin? In documentation only FUSE part mentioned as compatible with MSYS2.
o
Please provide us repo where this problem could be reproduced
m
Strange. I just tried this:
Copy code
depends = windows
package = dokan
headers = dokan/dokan.h
headerFilter = dokan/**
compilerOpts = -DUNICODE
linkerOpts = -ldokan1
No errors, no warnings. Are you sure you using 0.3.4?
e
That isn't what my .def looks like 😁 In headers, where does
dokan/
come from (I was just using
dokan.h
)? I also don't know what
linkerOpts
does? Does that tell me runtime to call into the
dokan1.dll
when a function from the header is called? So I'm guessing this issue is just me not knowing the .def options well enough.
@olonho I don't have a repo yet (just messing around for now), but I will try @msink suggestion and update. Very excited about Kotlin native.
m
I do not know anything about dokan, just installed from
Copy code
Dokan_x64-1.0.5.1000.msi
, and have it in
Copy code
C:\Program Files\Dokan\DokanLibrary-1.0.5\include
e
How do you get the interop tool to look there for the header?
I have that too, but it isn't getting found
I figured it out. Had to add
Copy code
includeDirs 'C:\\Program Files\\Dokan\\Dokan Library-1.0.5\\include'
to my build.gradle Thanks