[PATCH v2 libdrm 5/7] tegra: Add helper library for tests

Thierry Reding thierry.reding at gmail.com
Fri May 2 07:47:01 PDT 2014


On Mon, Apr 28, 2014 at 09:44:35PM +0200, Erik Faye-Lund wrote:
> On Wed, Apr 9, 2014 at 1:40 PM, Thierry Reding <thierry.reding at gmail.com> wrote:
> > From: Thierry Reding <treding at nvidia.com>
> >
> > This library provides helpers for common functionality needed by test
> > programs.
> >
> > Signed-off-by: Thierry Reding <treding at nvidia.com>
> > ---
> > Changes in v2:
> > - fix a couple of memory leaks and get rid of some unneeded code
> >
> >  tests/tegra/Makefile.am      |  10 +-
> >  tests/tegra/drm-test-tegra.c | 137 ++++++++++++++++++++++++
> >  tests/tegra/drm-test-tegra.h |  55 ++++++++++
> >  tests/tegra/drm-test.c       | 248 +++++++++++++++++++++++++++++++++++++++++++
> >  tests/tegra/drm-test.h       |  72 +++++++++++++
> >  5 files changed, 521 insertions(+), 1 deletion(-)
> >  create mode 100644 tests/tegra/drm-test-tegra.c
> >  create mode 100644 tests/tegra/drm-test-tegra.h
> >  create mode 100644 tests/tegra/drm-test.c
> >  create mode 100644 tests/tegra/drm-test.h
> >
> > diff --git a/tests/tegra/Makefile.am b/tests/tegra/Makefile.am
> > index 8b481bde4f11..e468029d152e 100644
> > --- a/tests/tegra/Makefile.am
> > +++ b/tests/tegra/Makefile.am
> > @@ -5,9 +5,17 @@ AM_CPPFLAGS = \
> >
> >  AM_CFLAGS = -Wall -Werror
> >
> > +noinst_LTLIBRARIES = libdrm-test.la
> > +libdrm_test_la_SOURCES = \
> > +       drm-test.c \
> > +       drm-test.h \
> > +       drm-test-tegra.c \
> > +       drm-test-tegra.h
> > +
> >  LDADD = \
> >         ../../tegra/libdrm_tegra.la \
> > -       ../../libdrm.la
> > +       ../../libdrm.la \
> > +       libdrm-test.la
> >
> 
> Hmm, I need the following on top to please the linker:
> 
> diff --git a/tests/tegra/Makefile.am b/tests/tegra/Makefile.am
> index 286af4b..88230c0 100644
> --- a/tests/tegra/Makefile.am
> +++ b/tests/tegra/Makefile.am
> @@ -14,8 +14,8 @@ libdrm_test_la_SOURCES = \
> 
>  LDADD = \
>         ../../tegra/libdrm_tegra.la \
> -       ../../libdrm.la \
> -       libdrm-test.la
> +       libdrm-test.la \
> +       ../../libdrm.la
> 
>  TESTS = \
>         openclose \

Yeah, this was reported by pretty much everybody who tested this. And I
have no setup where I could reproduce it. I eventually managed to
trigger a similar error by explicitly passing both -Wl,--as-needed and
-Wl,--no-copy-dt-needed-entries in LDFLAGS at configure time. I now have
a version that builds with or without these flags, so I hope that
everyone will now be happy.

Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/dri-devel/attachments/20140502/eb599cf6/attachment-0001.sig>


More information about the dri-devel mailing list