build error

hello i’m currently building dtools on 64 bit linux.

g++ -ftemplate-depth-30 -c -o Opt1-Linux/dtoolutil_dtoolutil_composite1.o -I. -I/home/sean/src/panda3d/dtool -I…/dtoolbase -I/usr/include/python2.6 -Wall -g -fPIC dtoolutil_composite1.cxx
In file included from dtoolutil_composite1.cxx:2:
filename.cxx: In static member function ‘static const Filename& Filename::get_home_directory()’:
filename.cxx:464: error: no matching function for call to ‘AtomicAdjustPosixImpl::get_ptr(Filename*&)’
…/dtoolbase/atomicAdjustPosixImpl.I:113: note: candidates are: static void* AtomicAdjustPosixImpl::get_ptr(void* const volatile&)
filename.cxx: In static member function ‘static const Filename& Filename::get_temp_directory()’:
filename.cxx:525: error: no matching function for call to ‘AtomicAdjustPosixImpl::get_ptr(Filename*&)’
…/dtoolbase/atomicAdjustPosixImpl.I:113: note: candidates are: static void* AtomicAdjustPosixImpl::get_ptr(void* const volatile&)
filename.cxx: In static member function ‘static const Filename& Filename::get_user_appdata_directory()’:
filename.cxx:574: error: no matching function for call to ‘AtomicAdjustPosixImpl::get_ptr(Filename*&)’
…/dtoolbase/atomicAdjustPosixImpl.I:113: note: candidates are: static void* AtomicAdjustPosixImpl::get_ptr(void* const volatile&)
filename.cxx: In static member function ‘static const Filename& Filename::get_common_appdata_directory()’:
filename.cxx:623: error: no matching function for call to ‘AtomicAdjustPosixImpl::get_ptr(Filename*&)’
…/dtoolbase/atomicAdjustPosixImpl.I:113: note: candidates are: static void* AtomicAdjustPosixImpl::get_ptr(void* const volatile&)
make[1]: *** [Opt1-Linux/dtoolutil_dtoolutil_composite1.o] Error 1
make[1]: Leaving directory `/home/sean/src/panda3d/dtool/src/dtoolutil’
make: *** [dtoolutil] Error 2

My opinion is that 64 bit gcc is a bit more restrictive about implicit type casts. I’ve seen similar things before. casting to void * didn’t working. Neither did declaring the variables volatile. the only thing that did work was casting the variable to “void* const volatile.” That makes me a bit uncomfortable and i’m not really sure if those types should actually be able to be casted. For Now i simply disabled the HAVE_THREADS macro in Config.pp

Another unrelated issue. It seems that the panda build needs some files that weren’t included in the cvs repository.

Warning: dependent file /home/sean/src/panda3d/panda/src/audio/Opt1-Linux/libaudio_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/chan/Opt1-Linux/libchan_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/char/Opt1-Linux/libchar_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/collide/Opt1-Linux/libcollide_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/cull/Opt1-Linux/libcull_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/device/Opt1-Linux/libdevice_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/dgraph/Opt1-Linux/libdgraph_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/display/Opt1-Linux/libdisplay_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/distort/Opt1-Linux/libdistort_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/downloader/Opt1-Linux/libdownloader_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/effects/Opt1-Linux/libeffects_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/egg/Opt1-Linux/libegg_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/egg2pg/Opt1-Linux/libegg2pg_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/event/Opt1-Linux/libevent_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/express/Opt1-Linux/libexpress_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/gobj/Opt1-Linux/libgobj_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/grutil/Opt1-Linux/libgrutil_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/gsgbase/Opt1-Linux/libgsgbase_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/lerp/Opt1-Linux/liblerp_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/linmath/Opt1-Linux/liblinmath_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/mathutil/Opt1-Linux/libmathutil_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/movies/Opt1-Linux/libmovies_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/nativenet/Opt1-Linux/libnativenet_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/net/Opt1-Linux/libnet_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/ode/Opt1-Linux/libpode_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/parametrics/Opt1-Linux/libparametrics_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/particlesystem/Opt1-Linux/libparticlesystem_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pgraph/Opt1-Linux/libpgraph_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pgraphnodes/Opt1-Linux/libpgraphnodes_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pgui/Opt1-Linux/libpgui_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/physics/Opt1-Linux/libphysics_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pipeline/Opt1-Linux/libpipeline_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pnmimage/Opt1-Linux/libpnmimage_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pnmtext/Opt1-Linux/libpnmtext_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/pstatclient/Opt1-Linux/libpstatclient_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/putil/Opt1-Linux/libputil_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/recorder/Opt1-Linux/librecorder_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/skel/Opt1-Linux/libskel_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/text/Opt1-Linux/libtext_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/tform/Opt1-Linux/libtform_igate.cxx does not exist.
Warning: dependent file /home/sean/src/panda3d/panda/src/vision/Opt1-Linux/libp3vision_igate.cxx does not exist.

Its not that they are in the wrong folder, but rather that they simply don’t exist anywhere on my computer. i’ve tried cvs up in and around the area and nothing.

I’m gonna assume that you have used ppremake, and not makepanda, to build Panda. (For the record, I have no problem building Panda by both systems.)
As for the missing files, ignore the warnings. These files contain auto-generated Python wrappers, if they don’t exist ppremake will simply invoke interrogate to generate them.

I believe there is no harm in casting the pointers to (void * const TVOLATILE). The volatile keyword is there to tell the compiler not to over-optimize the pointer within the cal, since multiple threads might be simultaneously accessing it. It actually doesn’t really matter too much in this context.

David