Mesa (master): st/egl: Use proper Makefile

Jakob Bornecrantz wallbraker at kemper.freedesktop.org
Fri May 15 22:13:53 UTC 2009


Module: Mesa
Branch: master
Commit: c4538e326a99fde3996f21866497f92ec14086df
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=c4538e326a99fde3996f21866497f92ec14086df

Author: Jakob Bornecrantz <wallbraker at gmail.com>
Date:   Fri May 15 22:47:31 2009 +0100

st/egl: Use proper Makefile

---

 src/gallium/state_trackers/egl/Makefile |   36 +++++++++++-------------------
 1 files changed, 13 insertions(+), 23 deletions(-)

diff --git a/src/gallium/state_trackers/egl/Makefile b/src/gallium/state_trackers/egl/Makefile
index 692a3c8..e825aa7 100644
--- a/src/gallium/state_trackers/egl/Makefile
+++ b/src/gallium/state_trackers/egl/Makefile
@@ -1,29 +1,19 @@
-TARGET     = libegldrm.a
-CFILES     = $(wildcard ./*.c)
-OBJECTS    = $(patsubst ./%.c,./%.o,$(CFILES))
-GALLIUMDIR = ../..
-TOP        = ../../../..
+TOP = ../../../..
+include $(TOP)/configs/current
 
-include ${TOP}/configs/current
+LIBNAME = egldrm
 
-CFLAGS := \
-          -I${GALLIUMDIR}/include \
-          -I${GALLIUMDIR}/auxiliary \
-          -I${TOP}/src/mesa/drivers/dri/common \
-          -I${TOP}/src/mesa \
-          -I$(TOP)/include \
-          -I$(TOP)/src/egl/main \
-          ${LIBDRM_CFLAGS} \
-          ${CFLAGS}
+LIBRARY_INCLUDES = \
+	-I$(TOP)/src/gallium/include \
+	-I$(TOP)/src/gallium/auxiliary \
+	-I$(TOP)/src/mesa/drivers/dri/common \
+	-I$(TOP)/src/mesa \
+	-I$(TOP)/include \
+	-I$(TOP)/src/egl/main \
+	$(shell pkg-config --cflags-only-I libdrm)
 
-#############################################
 
-.PHONY	= all clean
+C_SOURCES = $(wildcard ./*.c)
 
-all: ${TARGET}
 
-${TARGET}: ${OBJECTS}
-	ar rcs $@ $^
-
-clean:
-	rm -rf ${OBJECTS} ${TARGET}
+include ../../Makefile.template




More information about the mesa-commit mailing list