[SOLVED] egg-optchar.exe doesn't link under optimize 4

FYI. Showing up with optimize 4 option (windows 7, Panda1.8 )

makepanda  --verbose --everything --no-maya2012 --optimize 4 --installer
1>[ 70%] Linking executable built/bin/egg-optchar.exe
1>link /nologo /NOD:MFC90.LIB /NOD:MFC80.LIB /NOD:LIBCMT /NOD:LIBCI.LIB /DEBUG /nod:libc /nod:libcmtd /nod:atlthunk /nod:atls /MAP:NUL /LTCG /NOD:MSVCRTD.LIB /NOD:MSVCPRTD.LIB /NOD:MSVCIRTD.LIB /FIXED:NO /OPT:REF /STACK:4194304 /INCREMENTAL:NO  /OUT:built/bin/egg-optchar.exe /LIBPATH:thirdparty/win-python/libs built/tmp/egg-optchar_config_egg_optchar.obj built/tmp/egg-optchar_eggOptchar.obj built/tmp/egg-optchar_eggOptcharUserData.obj built/tmp/egg-optchar_vertexMembership.obj built/lib/libeggcharbase.lib built/lib/libeggbase.lib built/lib/libprogbase.lib built/lib/libconverter.lib built/lib/libpandatoolbase.lib built/lib/libpandaegg.lib built/lib/libpanda.lib built/lib/libpandaexpress.lib built/lib/libp3dtool.lib built/lib/libp3dtoolconfig.lib built/lib/libp3pystub.lib built/tmp/pandaIcon.res advapi32.lib thirdparty/win-libs-vc9/freetype/lib/freetype.lib
1>libeggcharbase.lib(eggcharbase_composite1.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall pvector<class LVecBase3f>::pvector<class LVecBase3f>(class TypeHandle)" (__imp_??0?$pvector@VLVecBase3f@@@@QAE@VTypeHandle@@@Z)
1>libeggcharbase.lib(eggcharbase_composite1.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::vector<class LVecBase3f,class pallocator_array<class LVecBase3f> >::push_back(class LVecBase3f const &)" (__imp_?push_back@?$vector@VLVecBase3f@@V?$pallocator_array@VLVecBase3f@@@@@std@@QAEXABVLVecBase3f@@@Z)
1>libeggcharbase.lib(eggcharbase_composite1.obj) : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall pvector<class LVecBase3f>::~pvector<class LVecBase3f>(void)" (__imp_??1?$pvector@VLVecBase3f@@@@QAE@XZ)
1>built/bin/egg-optchar.exe : fatal error LNK1120: 3 unresolved externals

I believe this is by design, since optimize 4 is for an end-user release build in which tools would not be needed.

Right, this is not a major issue since the tools can be compiled in optimize 3.

Neithertheless they should be able to compile in optimize 4 too, I think that some of them do.

I agree, all of the tools should compile in optimize 4. I haven’t tried it in a while, though, and not with makepanda either. But that’s a strange error message; it’s as if the pvector definition wasn’t exported properly. Weird.

I’ll give it a try when I can, but it will take a few days.

David

I have confirmed the problem. Investigating.

Hi David,
I don’t know if it is still a problem with the last CVS since I managed to get it compiled (under Intel compiler) yesterday?
So I thought you fixed it already!! didn’t you?

I did check in a fix, but only just now. Still, I think the underlying problem is a compiler bug, so switching to the Intel compiler may have fixed it anyway. Were you using the Intel compiler the first time too?

David

Just tried to compile on both Microsoft and Intel and the issue seems to be fixed for both!