[PATCH] hw/xwin: Look for gl spec files in $(srcdir) or .
Keith Packard
keithp at keithp.com
Fri Feb 25 18:27:50 PST 2011
On Sat, 26 Feb 2011 00:19:45 +0000, Jon TURNEY <jon.turney at dronecode.org.uk> wrote:
> Anyhow, I fully accept this is less than ideal as it stands, and I'll try to
> come up with something better for the future, as time permits.
Argh. My first patch didn't work in the o-o-t build from tarball case
(sigh). I've actually got a simpler patch that appears to work in all
cases now. It simply has the commands check for a local file, and when
that fails, to use $(srcdir). I wish gnumake provided syntax within the
command for files which should follow the vpath stuff.
diff --git a/hw/xwin/glx/Makefile.am b/hw/xwin/glx/Makefile.am
index e9fea50..303ff53 100644
--- a/hw/xwin/glx/Makefile.am
+++ b/hw/xwin/glx/Makefile.am
@@ -45,10 +45,10 @@ wgl.tm:
wget http://www.opengl.org/registry/api/wgl.tm
generated_gl_wrappers.c: gen_gl_wrappers.py gl.spec gl.tm
- $(srcdir)/gen_gl_wrappers.py --spec=$(srcdir)/gl.spec --typemap=$(srcdir)/gl.tm --dispatch-header=$(top_srcdir)/glx/dispatch.h --staticwrappers >generated_gl_wrappers.c
+ $(srcdir)/gen_gl_wrappers.py --spec=`test -e gl.spec || echo $(srcdir)/`gl.spec --typemap=`test -e gl.tm || echo $(srcdir)/`gl.tm --dispatch-header=$(top_srcdir)/glx/dispatch.h --staticwrappers >generated_gl_wrappers.c
generated_wgl_wrappers.c: gen_gl_wrappers.py wglext.spec wgl.tm
- $(srcdir)/gen_gl_wrappers.py --spec=$(srcdir)/wglext.spec --typemap=$(srcdir)/wgl.tm --prefix=wgl --preresolve >generated_wgl_wrappers.c
+ $(srcdir)/gen_gl_wrappers.py --spec=`test -e wglext.spec || echo $(srcdir)/`wglext.spec --typemap=`test -e wgl.tm || echo $(srcdir)/`wgl.tm --prefix=wgl --preresolve >generated_wgl_wrappers.c
wglext.h:
wget http://www.opengl.org/registry/api/wglext.h
--
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20110225/824128c9/attachment.pgp>
More information about the xorg-devel
mailing list