Brian Paul | ab93aa7 | 2008-09-03 09:08:19 -0600 | [diff] [blame] | 1 | # linux-cell (non-debug build) |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 2 | |
Jakob Bornecrantz | 7fad277 | 2009-02-10 14:14:28 +0100 | [diff] [blame] | 3 | include $(TOP)/configs/default |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 4 | |
5 | CONFIG_NAME = linux-cell | ||||
6 | |||||
7 | |||||
Brian Paul | 4356d34 | 2008-11-21 13:57:57 -0700 | [diff] [blame] | 8 | # Omiting other gallium drivers: |
Jakob Bornecrantz | d67bd60 | 2009-02-20 11:03:18 +0000 | [diff] [blame] | 9 | GALLIUM_DRIVERS_DIRS = cell softpipe trace |
José Fonseca | bfd5916 | 2008-02-18 14:25:04 +0900 | [diff] [blame] | 10 | |
11 | |||||
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 12 | # Compiler and flags |
Ian Romanick | eb4a738 | 2008-01-03 14:57:07 -0800 | [diff] [blame] | 13 | CC = ppu32-gcc |
14 | CXX = ppu32-g++ | ||||
Ian Romanick | b3492a2 | 2008-01-03 15:08:53 -0800 | [diff] [blame] | 15 | HOST_CC = gcc |
Brian Paul | 90c93bb | 2008-09-11 11:00:54 -0600 | [diff] [blame] | 16 | APP_CC = gcc |
17 | APP_CXX = g++ | ||||
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 18 | |
Brian Paul | ab93aa7 | 2008-09-03 09:08:19 -0600 | [diff] [blame] | 19 | OPT_FLAGS = -O3 |
Brian | 59e7bfd | 2008-01-28 18:17:55 -0700 | [diff] [blame] | 20 | |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 21 | # Cell SDK location |
Brian Paul | b5ab3b7 | 2008-08-26 14:09:28 -0600 | [diff] [blame] | 22 | ## For SDK 2.1: (plus, remove -DSPU_MAIN_PARAM_LONG_LONG below) |
23 | #SDK = /opt/ibm/cell-sdk/prototype/sysroot/usr | ||||
24 | ## For SDK 3.0: | ||||
Brian Paul | 90c93bb | 2008-09-11 11:00:54 -0600 | [diff] [blame] | 25 | SDK = /opt/cell/sdk/usr |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 26 | |
27 | |||||
Brian Paul | a35210b | 2008-11-12 11:01:05 -0700 | [diff] [blame] | 28 | CFLAGS = $(OPT_FLAGS) -Wall -Winline -Wmissing-prototypes \ |
29 | -fPIC -m32 -std=c99 -mabi=altivec -maltivec \ | ||||
Ian Romanick | 542e346 | 2008-03-25 18:15:34 -0700 | [diff] [blame] | 30 | -I. -I$(SDK)/include \ |
Brian Paul | 0996a23 | 2009-02-10 19:33:02 -0700 | [diff] [blame] | 31 | -DGALLIUM_CELL -DUSE_XSHM -D_BSD_SOURCE -D_SVID_SOURCE |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 32 | |
33 | CXXFLAGS = $(CFLAGS) | ||||
34 | |||||
Brian | c270829 | 2007-12-02 15:34:14 -0700 | [diff] [blame] | 35 | # Omitting glw here: |
Brian Paul | cb504a0 | 2009-12-27 10:24:12 -0700 | [diff] [blame^] | 36 | SRC_DIRS = glsl mesa gallium gallium/winsys glu glut/glx glew |
Brian | c270829 | 2007-12-02 15:34:14 -0700 | [diff] [blame] | 37 | |
Brian Paul | 0996a23 | 2009-02-10 19:33:02 -0700 | [diff] [blame] | 38 | # Build no traditional Mesa drivers: |
39 | DRIVER_DIRS = | ||||
40 | |||||
Brian | c270829 | 2007-12-02 15:34:14 -0700 | [diff] [blame] | 41 | |
Brian | 5935626 | 2007-12-05 14:57:19 -0700 | [diff] [blame] | 42 | MKDEP_OPTIONS = -fdepend -Y |
43 | |||||
44 | |||||
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 45 | GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lm -lpthread \ |
Ian Romanick | 9a0fe23 | 2007-12-11 12:40:58 -0800 | [diff] [blame] | 46 | -L$(SDK)/lib -m32 -Wl,-m,elf32ppc -R$(SDK)/lib -lspe2 |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 47 | |
48 | |||||
Brian Paul | ab93aa7 | 2008-09-03 09:08:19 -0600 | [diff] [blame] | 49 | CELL_SPU_LIB = $(TOP)/src/gallium/drivers/cell/spu/g3d_spu.a |
50 | |||||
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 51 | |
52 | ### SPU stuff | ||||
53 | |||||
Ian Romanick | eb4a738 | 2008-01-03 14:57:07 -0800 | [diff] [blame] | 54 | SPU_CC = spu-gcc |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 55 | |
Ian Romanick | 71071b7 | 2008-02-15 10:36:48 -0800 | [diff] [blame] | 56 | SPU_CFLAGS = $(OPT_FLAGS) -W -Wall -Winline -Wmissing-prototypes -Wno-main \ |
Ian Romanick | eb3f7aa | 2008-02-15 10:33:12 -0800 | [diff] [blame] | 57 | -I. -I$(SDK)/spu/include -I$(TOP)/src/mesa/ $(INCLUDE_DIRS) \ |
Brian Paul | b5ab3b7 | 2008-08-26 14:09:28 -0600 | [diff] [blame] | 58 | -DSPU_MAIN_PARAM_LONG_LONG \ |
Ian Romanick | eb3f7aa | 2008-02-15 10:33:12 -0800 | [diff] [blame] | 59 | -include spu_intrinsics.h |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 60 | |
Brian Paul | a4e4774 | 2008-10-08 20:34:35 -0600 | [diff] [blame] | 61 | SPU_LFLAGS = -L$(SDK)/spu/lib -Wl,-N -lmisc -lm |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 62 | |
Ian Romanick | eb4a738 | 2008-01-03 14:57:07 -0800 | [diff] [blame] | 63 | SPU_AR = ppu-ar |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 64 | SPU_AR_FLAGS = -qcs |
65 | |||||
Ian Romanick | eb4a738 | 2008-01-03 14:57:07 -0800 | [diff] [blame] | 66 | SPU_EMBED = ppu32-embedspu |
Brian | 88b715b | 2007-12-02 15:23:51 -0700 | [diff] [blame] | 67 | SPU_EMBED_FLAGS = -m32 |