ProblemLNK2001 unresolved external symbol _sscanf UMMU

gattispilot

Error LNK2001 unresolved external symbol _sscanf alphabuggy1 D:\orbiter100830\Orbitersdk\samples\MBATEST buggy D:\orbiter100830\Orbitersdk\samples\MBATEST buggy\UMmuSDK.lib(UMmuSDK.obj) 1

Severity Code Description Project Path File Line Suppression State
Error LNK1120 1 unresolved externals alphabuggy1 D:\orbiter100830\Modules D:\orbiter100830\Modules\alphabuggy1.dll 1

I am stumped. I am trying to recompile my MBA stuff. But for some reason this project give this error.

kuddel

Donator
Donator
It's all said in the error message: You are missing the library that has the symbol _sscanf.

Newer Visual Studio (>VS 2015) do not include these legacy features anymore on default, so you have to add legacy_stdio_definitions.lib to your linker files.

You could also add: #pragma comment (lib, "legacy_stdio_definitions.lib") into one of the source files to have it added by the linker as well.

Source: https://stackoverflow.com/questions...mbol-sprintf-and-sscanf-in-visual-studio-2015

gattispilot

Thanks. But I wonder why some compile using the same Ummu sdk? Yes this is VS2019.
I did this and now it works:
Code:
#define ORBITER_MODULE
#include "orbitersdk.h"
#include "ALPHABUGGYUMMUFUEL.h"
#include "OrbiterSoundSDK40.h"
#pragma comment (lib, "legacy_stdio_definitions.lib")

kuddel

Donator
Donator
When the symbol is not needed it does not have to be linked.