How to cross compile gst-omx?

I want to cross compile gst-omx on my Ubuntu 12.04 64bit.

I have read “README” come with gstomx_src.tbz2 and followed those instructions in it, but there are something I still confused because I don’t have any experience in EGL and X11.

Where can I find these path needed to be set:

export EGL_CFLAGS=“-I /egl/include/khronos -I /egl/include/nvidia -I /opengles/include”
export EGL_LIBS=“-L -lEGL -lGLESv2”
export X11_CFLAGS=“-I /xorg-server/include”
export X11_LIBS=“-L ”

Cross compilation is always a bit messy. In this case getting the X.Org headers and ARM libs (it might even be easiest mount them from Jetson with sshfs…).

I wonder if it would be possible to build gst-omx on natively on the Jetson?

One thing I do to “cheat” in Jetson cross compiles might help. If you have ever flashed, you will have a system.img file (starting in R21.1 you’ll need system.img.raw instead). Loopback mounting this gives you a copy of what’s on your Jetson. If you update packages Jetson and then add new things to Jetson, you can rsync some of the Jetson directories to your host’s loopback mounted copy, and suddenly you have an exact copy of your updated and complete Jetson. Presumably you would make sure your EGL and X11 devel libs and headers exist on Jetson, which would then make your loopback version also have these.