aboutsummaryrefslogtreecommitdiffstats
path: root/src/egl/drivers
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2012-02-05 10:46:13 +0100
committerEric Anholt <[email protected]>2012-02-29 11:52:40 -0800
commit88612029f6ce9d2717220a0ef31bfe71a8c85529 (patch)
treed86254fa4af549ab8850c39d07b929ea6cb82fd2 /src/egl/drivers
parent28d92eff73a0821e7a73b04d3f50e715850dc5e9 (diff)
egl/main: Convert to automake.
The drivers/ walk-through-subdirs makefile is converted as well so I didn't need to keep EGL_DRIVERS_DIRS along with the per-driver HAVE_EGL_DRIVER_WHATEVER. Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/egl/drivers')
-rw-r--r--src/egl/drivers/.gitignore2
-rw-r--r--src/egl/drivers/Makefile31
-rw-r--r--src/egl/drivers/Makefile.am30
-rw-r--r--src/egl/drivers/Makefile.template2
4 files changed, 33 insertions, 32 deletions
diff --git a/src/egl/drivers/.gitignore b/src/egl/drivers/.gitignore
new file mode 100644
index 00000000000..282522db034
--- /dev/null
+++ b/src/egl/drivers/.gitignore
@@ -0,0 +1,2 @@
+Makefile
+Makefile.in
diff --git a/src/egl/drivers/Makefile b/src/egl/drivers/Makefile
deleted file mode 100644
index dde4ee22551..00000000000
--- a/src/egl/drivers/Makefile
+++ /dev/null
@@ -1,31 +0,0 @@
-# src/egl/drivers/Makefile
-
-TOP = ../../..
-include $(TOP)/configs/current
-
-SUBDIRS = $(EGL_DRIVERS_DIRS)
-
-
-default: subdirs
-
-
-subdirs:
- @for dir in $(SUBDIRS) ; do \
- if [ -d $$dir ] ; then \
- (cd $$dir ; $(MAKE)) || exit 1 ; \
- fi \
- done
-
-install:
- @ for dir in $(SUBDIRS) ; do \
- if [ -d $$dir ] ; then \
- (cd $$dir ; $(MAKE) install) || exit 1 ; \
- fi \
- done
-
-clean:
- @for dir in $(SUBDIRS) ; do \
- if [ -d $$dir ] ; then \
- (cd $$dir ; $(MAKE) clean) ; \
- fi \
- done
diff --git a/src/egl/drivers/Makefile.am b/src/egl/drivers/Makefile.am
new file mode 100644
index 00000000000..99d5b80045f
--- /dev/null
+++ b/src/egl/drivers/Makefile.am
@@ -0,0 +1,30 @@
+# Copyright © 2012 Intel Corporation
+#
+# Permission is hereby granted, free of charge, to any person obtaining a
+# copy of this software and associated documentation files (the "Software"),
+# to deal in the Software without restriction, including without limitation
+# the rights to use, copy, modify, merge, publish, distribute, sublicense,
+# and/or sell copies of the Software, and to permit persons to whom the
+# Software is furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice (including the next
+# paragraph) shall be included in all copies or substantial portions of the
+# Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+# IN THE SOFTWARE.
+
+SUBDIRS =
+
+if HAVE_EGL_DRIVER_GLX
+SUBDIRS += glx
+endif
+
+if HAVE_EGL_DRIVER_DRI2
+SUBDIRS += dri2
+endif
diff --git a/src/egl/drivers/Makefile.template b/src/egl/drivers/Makefile.template
index e96f9975540..894ec4a028e 100644
--- a/src/egl/drivers/Makefile.template
+++ b/src/egl/drivers/Makefile.template
@@ -13,7 +13,7 @@
EGL_OBJECTS = $(EGL_SOURCES:.c=.o)
-default: depend lib$(EGL_DRIVER).a
+all: depend lib$(EGL_DRIVER).a
lib$(EGL_DRIVER).a: $(EGL_OBJECTS) Makefile $(TOP)/src/egl/drivers/Makefile.template
@$(MKLIB) -o $(EGL_DRIVER) -static $(EGL_OBJECTS)