When linking static sfml libraries i get annoying LNK:4099 warning about missing PDB files. I tried using #pragma warning(disable:4099) works every 10 or so cleans/rebuilds. And I also tried to use #pragma comment(linker, "/ignore:4009") which also doesn't work - ever. How can I fix this? I tried placing #pragma in both *.cpp and *.h in case something funny was happening - but no difference. Is this specific warning for VS or is it present in all compilers?
#pragma warning doesn't work
All error numbers reported by compilers and linkers are unique to those compilers and linkers, so while another linker may report a similar warning (likely not specifically about PDB files since those are specific to Visual Studio®) it would have a different number.
As for warning 4099, it cannot be ignored without patching link.exe with a hex editor.
http://bitsquid.blogspot.jp/2011/12/code-share-patch-linkexe-to-ignore.html
If you want to do it manually, you can look at that code and easily see that all it does is search for 3 unsigned shorts in a row: 4088, 4099, and 4105, and replaces them with 4088, 65535, and 4105, effectively removing 4099 from the exclusion list. This can easily be done via any hex editor. I use MHS.
L. Spiro
This probably doesn't help the OP, but why are the .PDB files missing? Aren't they included in the SFML release?
If not, try asking the developers why the files are missing - they need to realize that shipping .PDB files doesn't hurt their product at all.
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.