mjwybrow / dunnart

Constraint-based diagram editor
http://www.dunnart.org/
Other
139 stars 20 forks source link

Build failure on windows with mingw32 '::strcpy_s' has not been declared. #11

Closed niclas-k closed 10 years ago

niclas-k commented 11 years ago

Hi I'm trying to build dunnart on windows 7 with Qt 5.1.1 (mingw32). During the build of libcola it fails with the following error:

In file included from c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/string.h:176:0, from c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/guiddef.h:139, from c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/winnt.h:461, from c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/windef.h:139, from c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/windows.h:69, from ....\dunnart/libcola/cola_log.h:165, from ....\dunnart\libcola\colafd.cpp:46: c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h: In function 'errno_t cola::strcpy_s(char (&)[_size], const char)': c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h:28:3: error: '::strcpy_s' has not been declared c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h:28:3: note: suggested alternative: c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h:28:3: note: 'cola::strcpy_s' c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h: In function 'errno_t cola::strcat_s(char (&)[_size], const char)': c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h:33:3: error: '::strcat_s' has not been declared c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h:33:3: note: suggested alternative: c:\qt\qt5.0.1\tools\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.2/../../../../i686-w64-mingw32/include/sec_api/string_s.h:33:3: note: 'cola::strcat_s' ....\dunnart\libcola\colafd.cpp: In member function 'void cola::ConstrainedFDLayout::outputInstanceToSVG(std::string)': ....\dunnart\libcola\colafd.cpp:1224:82: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat] ....\dunnart\libcola\colafd.cpp:1224:82: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'size_t {aka unsigned int}' [-Wformat]

What am I doing wrong?