[Gstreamer-openmax] [PATCH] fixes for out-of-tree build

Clark, Rob rob at ti.com
Sat Mar 6 10:19:29 PST 2010


opps, I realized this wasn't rebased after Felipe changed OMX_REGISTRY to OMX_CONFIG..   I'll just resend and updated patch momentarily


On Mar 5, 2010, at 2:07 PM, Rob Clark wrote:

> Normally with autotools, you should be able to create a directory outside of the srctree, and then run something like:
> 
>  ../path/to/gst-openmax/configure ....
>  make check install
> 
> but a couple small tweaks were needed to make check work properly.  Mainly replacing Makefile with a Makefile.in, and avoiding relative paths to files in the src tree.
> ---
> configure.ac                 |    1 +
> tests/Makefile.am            |    2 +-
> tests/standalone/Makefile    |   36 ------------------------------------
> tests/standalone/Makefile.in |   38 ++++++++++++++++++++++++++++++++++++++
> 4 files changed, 40 insertions(+), 37 deletions(-)
> delete mode 100644 tests/standalone/Makefile
> create mode 100644 tests/standalone/Makefile.in
> 
> diff --git a/configure.ac b/configure.ac
> index 22dcf7d..b6a1316 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -108,6 +108,7 @@ AC_CONFIG_FILES([Makefile \
> 		 omx/Makefile \
> 		 util/Makefile \
> 		 tests/Makefile \
> +		 tests/standalone/Makefile \
> 		 m4/Makefile])
> 
> AC_OUTPUT
> diff --git a/tests/Makefile.am b/tests/Makefile.am
> index f43098a..dff4f31 100644
> --- a/tests/Makefile.am
> +++ b/tests/Makefile.am
> @@ -9,7 +9,7 @@ CHECK_REGISTRY = $(top_builddir)/tests/test-registry.reg
> TESTS_ENVIRONMENT = GST_REGISTRY=$(CHECK_REGISTRY) \
> 		    LD_LIBRARY_PATH=$(builddir)/standalone \
> 		    GST_PLUGIN_PATH=$(top_builddir)/omx \
> -		    OMX_REGISTRY=gst-openmax.conf
> +		    OMX_REGISTRY=$(srcdir)/gst-openmax.conf
> 
> check_PROGRAMS =
> 
> diff --git a/tests/standalone/Makefile b/tests/standalone/Makefile
> deleted file mode 100644
> index e316d45..0000000
> --- a/tests/standalone/Makefile
> +++ /dev/null
> @@ -1,36 +0,0 @@
> -noinst_LIBRARIES = libomxil-foo.so
> -
> -libomxil_foo_so_SOURCES = core.c
> -libomxil_foo_so_CFLAGS = -I$(top_srcdir)/omx/headers $(GTHREAD_CFLAGS) -I$(top_srcdir)/util
> -libomxil_foo_so_LIBADD = $(GTHREAD_LIBS) $(top_srcdir)/util/.libs/libutil.a
> -
> -# Manual stuff
> -
> -CFLAGS = -ggdb
> -top_srcdir = ../..
> -srcdir = .
> -CC = gcc
> -LIBRARIES = $(noinst_LIBRARIES)
> -GTHREAD_CFLAGS=`pkg-config --cflags gthread-2.0`
> -GTHREAD_LIBS=`pkg-config --libs gthread-2.0`
> -
> -all: 
> -check: $(LIBRARIES)
> -
> -libomxil-foo.so: $(patsubst %.c,%.o,$(libomxil_foo_so_SOURCES))
> -libomxil-foo.so: CFLAGS := $(CFLAGS) -fPIC $(libomxil_foo_so_CFLAGS)
> -libomxil-foo.so: LIBS := $(libomxil_foo_so_LIBADD)
> -
> -%.so::
> -	$(CC) $(LDFLAGS) -shared -o $@ $^ $(LIBS)
> -
> -.PHONY: clean distclean install
> -
> -clean:
> -	rm -rf *.o $(LIBRARIES)
> -
> -install:
> -distdir:
> -	cp -pR $(srcdir)/core.c $(distdir)
> -	cp -pR $(srcdir)/Makefile $(distdir)
> -distclean: clean
> diff --git a/tests/standalone/Makefile.in b/tests/standalone/Makefile.in
> new file mode 100644
> index 0000000..f87ff6f
> --- /dev/null
> +++ b/tests/standalone/Makefile.in
> @@ -0,0 +1,38 @@
> +VPATH = @srcdir@
> +
> +noinst_LIBRARIES = libomxil-foo.so
> +
> +libomxil_foo_so_SOURCES = core.c
> +libomxil_foo_so_CFLAGS = -I$(top_srcdir)/omx/headers $(GTHREAD_CFLAGS) -I$(top_srcdir)/util
> +libomxil_foo_so_LIBADD = $(GTHREAD_LIBS) ../../util/.libs/libutil.a
> +
> +# Manual stuff
> +
> +CFLAGS = -ggdb
> +top_srcdir = @srcdir@/../..
> +srcdir = @srcdir@
> +CC = gcc
> +LIBRARIES = $(noinst_LIBRARIES)
> +GTHREAD_CFLAGS=`pkg-config --cflags gthread-2.0`
> +GTHREAD_LIBS=`pkg-config --libs gthread-2.0`
> +
> +all: 
> +check: $(LIBRARIES)
> +
> +libomxil-foo.so: $(patsubst %.c,%.o,$(libomxil_foo_so_SOURCES))
> +libomxil-foo.so: CFLAGS := $(CFLAGS) -fPIC $(libomxil_foo_so_CFLAGS)
> +libomxil-foo.so: LIBS := $(libomxil_foo_so_LIBADD)
> +
> +%.so::
> +	$(CC) $(LDFLAGS) -shared -o $@ $^ $(LIBS)
> +
> +.PHONY: clean distclean install
> +
> +clean:
> +	rm -rf *.o $(LIBRARIES)
> +
> +install:
> +distdir:
> +	cp -pR $(srcdir)/core.c $(distdir)
> +	cp -pR $(srcdir)/Makefile $(distdir)
> +distclean: clean
> -- 
> 1.6.3.2
> 





More information about the Gstreamer-openmax mailing list