1.6.0 on Windows: Warning C4275

Hello,

I was compiling Panda3D 1.6.0 on windows Vista 32bit, using both VS8 (2005) Express and VS9 (2008) SP1 Express. SDK is the Windows SDK for Server 2008 (6001.18000.367).

I can compile, but I get the following warning several times:

C:\Program Files\Microsoft Visual Studio 9.0\VC\include\vector(439) : warning C4275: non dll-interface class 'std::_Container_base_aux' used as base for dll-interface class 'std::_Container_base_aux_alloc_real<_Alloc>'
        with
        [
            _Alloc=pallocator_array<std::string>
        ]
        C:\Program Files\Microsoft Visual Studio 9.0\VC\include\xutility(377) : see declaration of 'std::_Container_base_aux'
        c:\libraries\panda3d-1.6.0\dtool\src\dtoolutil\vector_src.h(64) : see reference to class template instantiation 'std::vector<_Ty,_Ax>' being compiled
        with
        [
            _Ty=std::string,
            _Ax=pallocator_array<std::string>
        ]

First I want to ask if this warning is considered “normal”, that is, does the official Panda3D build for Windows produce this warning too? Seconds, what versions of VS and SDK is used to compile the official Panda3D 1.6.0 release?

enn0x

Yeah, those warnings are normal. No big deal, no one will notice at runtime.
The official build was compiled with VC++ 2008 express, with this SDK version:
microsoft.com/downloads/deta … laylang=en

That is the only free SDK that ships with ATL, which is required for Panda’s Webcam code. Either compile with --no-directcam, or you need to use that sdk (or one from the Paid versions of Visual Studio)

Exporting STD containers in a DLL is problematic, at best. You are now locked into using exactly the same compiler and compiler version for both the DLL and whatever software uses the DLL since the implementation of the container must be identical in both builds. Moreover, the builds must share the same compiler switches. You won’t be able to use a Debug software and have it call in to a Release version of the DLL, since the way heap is allocated in the DLL must be implemented in the same manner that heap is deallocated in the application using the DLL, which is the case for Debug and Release builds.

Well, I will try to compile with the PSDK Server 2003 R2. This seems to be the only way to go without dropping any features, since I refuse to buy non-Express versions of VS :slight_smile: Thanks for the information.

enn0x