Compiling and installing


I have finally managed to compile Panda3d, but I don’t know where I am going to put the compiled files. Can someone tell me? I am using ubuntu 7.04


aQ, I also run Ubuntu (actually Kubuntu). It depends on how you want to run the software, but I decided that it would be simplest for me to avoid potential package conflicts (since Panda3D includes a lot of executables, and in one case, “dcraw”, there is actually a potential naming conflict.

What I did is just leave the build output in its own directory and then create a script to run Panda programs. My scripts look like this (this example runs the port of the nVidia nature demo):


# built using makepanda

export PATH

cd Demo-Nature-2

This works well for running applications, though it is a bit tedious for using the included utilities like converters or the viewer.

Thanks. Do you run this script in the terminal, or in a .py file?

none of both. put that in a file without extension, go to a terminal, do a chmod 755 yourfile, then type ./yourfile.

Ok. when I run it, I get this error:
bash: ./script: /usr/bin/sh: bad interpreter: No such file or directory

Any ideas?

I got the error above fixed, but it still wont work. When I type in ./script in the terminal I get this error:
./script: 11: ppython: not found

Replace /usr/bin/sh with /bin/sh.

Also, dont forget to change this path:
Into the path where you have the built Panda3D located.
By the way. A good place to place the files:
the contents of /bin to /usr/bin
the contents of /lib to /usr/lib
the contents of /etc to /etc/
the contents of /include to /usr/include/panda3d
and, ehrm. put the rest in /usr/share/panda3d

Thank you, I’ve done that.

The error I get now is:
Traceback (most recent call last):
File “”, line 1, in
import direct.directbase.DirectStart
ImportError: No module named direct.directbase.DirectStart

(trying to run the greetingcard)

oh, add this environment var to your sh file:


One step closer, but still not close enough:

New error:

its the library path that isnt correct yet.

Make sure the place where you put the panda3d .lib files is on the LD_LIBRARY_PATH:

LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/lib/ (or wherever you put the libpanda.lib file or so)

Seems like I am one step closer … again. I copied the Panda-libs into the python lib folder, and now these errors displays: