summaryrefslogtreecommitdiff
path: root/hw/xwin
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2011-02-25 10:54:50 -0800
committerKeith Packard <keithp@keithp.com>2011-02-25 20:27:03 -0800
commitfd4d9c75c265add8d6cc74afb341c9c4f2ec1073 (patch)
treee4680c6bef1043299fd341be3601752a5d3fed8f /hw/xwin
parent6b951dec69103ca76d6d4a61b1a2f67a52d013b9 (diff)
hw/xwin: Look for gl spec files in $(srcdir) or .
Tarballs include the downloaded gl spec files, which will end up in $(srcdir). But, git-based builds will not have them at all and will need to download them from opengl.org. They'll land in in the build directory instead of $(srcdir), and so we need to allow them to be in either place. This change checks for the files in $(srcdir), linking them to . if present. Otherwise, it downloads them from opengl.org. A suggested better solution is to have Mesa install these files somewhere. Signed-off-by: Keith Packard <keithp@keithp.com> Tested-by: Kristian Høgsberg <krh@bitplanet.net>
Diffstat (limited to 'hw/xwin')
-rw-r--r--hw/xwin/glx/Makefile.am4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/xwin/glx/Makefile.am b/hw/xwin/glx/Makefile.am
index e9fea50a7..303ff53f2 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