CyAPI.lib & VS2017

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
sesk_4098801
Level 1
Level 1

Hello!

A  few  years  ago, I wrote an C++ application for Windows - use CY68013, CyAPI-based, and it work good.

And now, after migrating from Visual Studio 2015 to Visual Studio 2017, my application (for CY68013, CyAPI-based) can not build anymore!

I've got the error message:

1>CyAPI.lib(CyAPI.obj) : error LNK2019: unresolved external symbol _sprintf referenced in function "public: void __thiscall CCyUSBDevice::UsbdStatusString(unsigned long,char *)" (?UsbdStatusString@CCyUSBDevice@@QAEXKPAD@Z)

It seems that problem is into CyAPI.lib.

How can I fix it?

Thnx.

0 Likes
1 Solution
SrinathS_16
Moderator
Moderator
Moderator
1000 replies posted 750 replies posted 500 replies posted

Hello,

- Please check if you have added the 'legacy_stdio_definitions.lib' in the "Linker" input properties (See below image.)

pastedImage_0.png

- If you still face the issue, kindly, share the project for me to check. In case you feel the project is confidential, send it over the private message option.

Best regards,

Srinath S

View solution in original post

0 Likes
2 Replies
SrinathS_16
Moderator
Moderator
Moderator
1000 replies posted 750 replies posted 500 replies posted

Hello,

- Please check if you have added the 'legacy_stdio_definitions.lib' in the "Linker" input properties (See below image.)

pastedImage_0.png

- If you still face the issue, kindly, share the project for me to check. In case you feel the project is confidential, send it over the private message option.

Best regards,

Srinath S

0 Likes

Thank you very much!

It helped!

0 Likes