Update on my current predicament - it's working!
Although getting it to work felt very scrappy. First of all, AK47's extra #pragma comments DID fix those external symbol errors, but I was still getting that mysterious "cannot open file 'PhysXLoader.lib', despite the folder it was in definitely being pointed at in the Directories thing. To find it, I just changed:
Code: Select all
#pragma comment(lib, "PhysXLoader.lib")
to:
Code: Select all
#pragma comment(lib, "C:\\Program Files (x86)\\NVIDIA Corporation\\NVIDIA PhysX SDK\\v2.8.1\\SDKs\\lib\\Win32\\PhysXLoader.lib")
So then it managed to find the .lib. Finally! However it then threw some LNK2005 errors, which
some Google-ingrevealed meant there was an inconsistency between some setting of the ".lib and .dll projects"? Whatever, I changed Project Properties -> C/C++ -> Code Generation -> Runtime Library from /MDd to /MTd, and that got rid of those errors.
It then compiled with 4 linking warnings:
Code: Select all
1>Linking...
1>IrrPhysx.lib(IrrPhysx.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
1>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
1>LIBCMTD.lib(crt0init.obj) : warning LNK4098: defaultlib 'libcmt.lib' conflicts with use of other libs; use /NODEFAULTLIB:library
1>Generating code
1>Finished generating code
1>Embedding manifest...
1>Microsoft (R) Windows (R) Resource Compiler Version 6.1.6723.1
1>Copyright (C) Microsoft Corporation. All rights reserved.
1>IrrPhysx.lib(IrrPhysx.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
1>LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
1>LIBCMTD.lib(crt0init.obj) : warning LNK4098: defaultlib 'libcmt.lib' conflicts with use of other libs; use /NODEFAULTLIB:library
1>Generating code
1>Finished generating code
I couldn't understand them, but I wasn't too worried because it worked! The application then bombed almost immediately, but the console output informed me that it couldn't find certain files in "../media/", so I copied the media folder from IrrPhysx/examples to my project's folder and changed the paths in the code (my main.cpp, anyway) to just "media/", and it then worked perfectly!
(I just noticed, from fiddling with the examples, all the textures for the blocks is still looking at "../media/", so the media folder needed to be copied there too. I guess that path assumes your EXE ends up in a /bin/ folder?).
I don't know whether any of this is good/bad/expected, but does anyone know what those warnings mean?
I tried taking similar steps to build the BoxesExample example, which seemed like everything magically knew where everything else was on JP's PC, but those magic pointers had disappeared - I had to add about 4 more Include Directories than my other project, and copy the media folder from the IrrPhysx root to the IrrPhysx/examples/ folder.
Hopefully this is of some use to someone. Stuff works to an extent now! Oh, and having worked with all this stuff for a few days now trying to work out what and what not to add, I've got a glimpse of just how much stuff there is in IrrPhysx, and I've gotta say awesome job, JP!