Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
195 views
in Technique[技术] by (71.8m points)

c++ - Build Assimp with mingw32

Hello i tried to compile Assimp with mingw32.

But during compilation multiple errors appeard.

The first was:

C:UsersMY_NAMEDownloadsassimp-5.0.1assimp-5.0.1codeSMDSMDLoader.cpp:579:12: error: 'strtok_s' was not declared in this scope; did you mean 'strtok_r'?

I found a solution for the this problem,i changed the source code and it worked but i don't found a solution for the second problem. The second error was:

c:usersMY_NAMEdownloadsassimp-5.0.1assimp-5.0.1contribzipsrczip.h:30:15: error: conflicting declaration 'typedef long int ssize_t' 
30 | typedef long  ssize_t;  /* byte count or error */

here is line 30 from zip.h :

typedef long  ssize_t;  /* byte count or error */

To make it more clear,i decided to show you a block of code. here is a block of code from line 27 to 31 in zip.h

#ifdef _WIN64
typedef long long  ssize_t;  /* byte count or error */
#else
typedef long  ssize_t;  /* byte count or error *
#endif

I'm using mingw32 with gcc (9.2.0)

Can someone explain why the build fail?

question from:https://stackoverflow.com/questions/65642587/build-assimp-with-mingw32

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

As far as I know, this issue is already closed in our current master. Could you please try the latest from Asset-Importer-Lib@github?


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...