Jakob Bornecrantz | 9395fb6 | 2008-05-22 16:24:51 +0200 | [diff] [blame] | 1 | # -*-makefile-*- |
| 2 | # Configuration for linux-dri: Linux DRI hardware drivers for XFree86 & others |
| 3 | |
| 4 | include $(TOP)/configs/default |
| 5 | |
| 6 | CONFIG_NAME = linux-dri |
| 7 | |
| 8 | # Compiler and flags |
| 9 | CC = gcc |
| 10 | CXX = g++ |
| 11 | |
| 12 | #MKDEP = /usr/X11R6/bin/makedepend |
| 13 | #MKDEP = gcc -M |
| 14 | #MKDEP_OPTIONS = -MF depend |
| 15 | |
| 16 | OPT_FLAGS = -O -g |
| 17 | PIC_FLAGS = -fPIC |
| 18 | |
| 19 | # Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support. |
| 20 | ARCH_FLAGS ?= |
| 21 | |
| 22 | DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \ |
| 23 | -D_BSD_SOURCE -D_GNU_SOURCE \ |
| 24 | -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER \ |
| 25 | -DGLX_DIRECT_RENDERING -DGLX_INDIRECT_RENDERING \ |
| 26 | -DHAVE_ALIAS -DHAVE_POSIX_MEMALIGN |
| 27 | |
| 28 | X11_INCLUDES = -I/usr/X11R6/include |
| 29 | |
| 30 | CFLAGS = -Wall -Wmissing-prototypes -std=c99 -ffast-math \ |
| 31 | $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS) |
| 32 | |
| 33 | CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) |
| 34 | |
| 35 | |
| 36 | MESA_ASM_SOURCES = |
| 37 | |
| 38 | # Library/program dependencies |
| 39 | EXTRA_LIB_PATH=-L/usr/X11R6/lib |
| 40 | |
| 41 | LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm) |
| 42 | LIBDRM_LIB = $(shell pkg-config --libs libdrm) |
| 43 | DRI_LIB_DEPS = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB) |
| 44 | GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \ |
| 45 | -lm -lpthread -ldl \ |
| 46 | $(LIBDRM_LIB) |
| 47 | |
| 48 | |
Jakob Bornecrantz | 9395fb6 | 2008-05-22 16:24:51 +0200 | [diff] [blame] | 49 | # Directories |
| 50 | SRC_DIRS = gallium mesa gallium/winsys glu egl |
| 51 | PROGRAM_DIRS = egl |
| 52 | |
| 53 | DRIVER_DIRS = dri |
| 54 | WINDOW_SYSTEM = dri |
| 55 | GALLIUM_WINSYS_DIRS = egl_drm |
| 56 | |
| 57 | # gamma are missing because they have not been converted to use the new |
| 58 | # interface. |
| 59 | DRI_DIRS = intel |