build from source

Tim-Philipp Müller t.i.m at zen.co.uk
Wed Jan 16 15:56:00 PST 2013


On Thu, 2013-01-17 at 12:40 +1300, Angelica Perduta wrote:

Hi,

> make[3]: Entering directory
> `/home/Perduta/buildGST/gst-plugins-bad-1.0.5/sys/d3dvideosink'
>   CC     libgstd3dvideosink_la-d3dvideosink.lo
> In file included from d3dvideosink.c:25:0:
> d3dvideosink.h:47:22: fatal error: d3dx9tex.h: No such file or directory
> compilation terminated.
> make[3]: *** [libgstd3dvideosink_la-d3dvideosink.lo] Error 1
> 
> It doesn't help one little bit specifying where said header is with:
> 
> make --include-dir=/opt/DirectXSDK/Include
> 
> So sadly once again these 'clever' tools have outsmarted me as I
> simply can't work out how to tell them where my SDK is installed. ATM
> I can't even work out how to tell it to just skip past d3dvideosink.
> 
> I do realize that if I spend some weeks learning more about the
> details of how these scripts work I might eventually be able to fix
> it, but it has already detracted far too much of my effort from my own
> project and IMHO it's a real shame that gstreamer and in fact all the
> gnome packages are blighted with these ghastly autotools :(

Just some quick pointers, which you may or may not find useful:

- 'make V=1' will give you more verbose output including all the
compiler and linker flags passed, so you can see where it's looking or
not looking.

- have a look at the Makefile.am in the directory in question
(sys/d3dvideosink in this case). The *_CFLAGS are for compiler flags and
preprocessor includes, and _LIBADD and _LIBS is for the linker (where to
look for libraries and which to link to).

In this case:

libgstd3dvideosink_la_SOURCES = d3dvideosink.c d3dhelpers.c
libgstd3dvideosink_la_CFLAGS = $(GST_PLUGINS_BAD_CFLAGS)
$(GST_PLUGINS_BASE_CFLAGS) $(GST_CFLAGS) $(DIRECT3D_CFLAGS)
$(DIRECTX_CFLAGS)
libgstd3dvideosink_la_LIBADD = $(GST_BASE_LIBS) $(GST_PLUGINS_BASE_LIBS)
\
	-lgstvideo-$(GST_API_VERSION) \
	$(DIRECT3D_LIBS) $(DIRECTX_LDFAGS)

(Background: autogen.sh will create a Makefile.in from Makefile.am, and
when you run configure, it will create Makefile from the Makefile.in
template, and fill it with the actual values detected.)

You can grep Makefile for the various variables, e.g.:

grep DIRECT3D_CFLAGS Makefile
grep DIRECTX_CFLAGS Makefile

to see the include paths passed to the compiler.

You can also override these with make, e.g.:

make DIRECTX_CFLAGS="-I/opt/DirectXSDK/Include

This stuff certainly needs some fine-tuning on windows. It should
ideally just work out of the box.

 Cheers
  -Tim




More information about the gstreamer-devel mailing list