如何解决fopen64,freopen64,tmpfile64未声明错误?

时间:2018-11-13 09:19:24

标签: android qt dcmtk

我已编译DCMTK源代码以生成库(用于android平台),并将这些库添加到我的QT项目中。构建我的qt项目时,出现以下错误:

C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:310: error: '::fopen64' has not been declared
file_ = :: fopen64(filename, modes);
^
C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:425: error: '::freopen64' has not been declared
file_ = :: freopen64(filename, modes, file_);
^
C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:444: error: '::tmpfile64' has not been declared
file_ = :: tmpfile64();
^
C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:790: error: '::fseeko64' has not been declared
result = :: fseeko64(file_, off, whence);
^
C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:823: error: '::ftello64' has not been declared
result = :: ftello64(file_);
^
C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:847: error: '::fgetpos64' has not been declared
result = :: fgetpos64(file_, pos);
^
C:\Ashish\QTPROJECT\test\include\dcmtk\ofstd\offile.h:867: error: '::fsetpos64' has not been declared
result = :: fsetpos64(file_, pos);

我该如何解决?

1 个答案:

答案 0 :(得分:0)

解决了此问题。 问题是我使用的库是在调试中编译的,所以解决方案是在创建库时,我应该使用release而不是debug,然后将这些库添加到项目中,这样的错误就不会发生。