Mercurial > sdl-ios-xcode
annotate src/video/ps3/spulibs/Makefile @ 3154:95e48f7a3a93 gsoc2009_ps3
Added Makefile rule for spu programs. Added Readme.
author | Martin Lowinski <martin@goldtopf.org> |
---|---|
date | Mon, 10 Aug 2009 18:05:33 +0000 |
parents | 104786a909a2 |
children | abc49915ccb2 |
rev | line source |
---|---|
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
1 # This Makefile is for building the CELL BE SPU libs |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
2 # libfb_writer_spu.so, libyuv2rgb_spu.so, libbilin_scaler_spu.so |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
3 |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
4 # Toolchain |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
5 SPU_GCC=/usr/bin/spu-gcc |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
6 PPU_EMBEDSPU=/usr/bin/embedspu |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
7 PPU_AR=/usr/bin/ar |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
8 PPU_LD=/usr/bin/ld |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
9 SPU_SRCDIR=$(srcdir)/src/video/ps3/spulibs |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
10 SPU_LIBDIR=$(srcdir)/src/video/ps3/spulibs/libs |
3146
9e902f423497
YUV-Textures with SPU-support working.
Martin Lowinski <martin@goldtopf.org>
parents:
3144
diff
changeset
|
11 SPU_CFLAGS=-g -W -Wall -Winline -Wno-main -I. -I /usr/spu/include -I /opt/cell/sdk/usr/spu/include -finline-limit=10000 -Winline -ftree-vectorize -funroll-loops -fmodulo-sched -ffast-math -fPIC -O2 |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
12 |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
13 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
14 ps3libs: $(SPU_LIBDIR)/libfb_writer_spu.a $(SPU_LIBDIR)/libfb_writer_spu.so \ |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
15 $(SPU_LIBDIR)/libyuv2rgb_spu.so $(SPU_LIBDIR)/libyuv2rgb_spu.a \ |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
16 $(SPU_LIBDIR)/libbilin_scaler_spu.so $(SPU_LIBDIR)/libbilin_scaler_spu.a |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
17 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
18 $(SPU_LIBDIR): |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
19 $(SHELL) $(auxdir)/mkinstalldirs $(SPU_LIBDIR) |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
20 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
21 # fb_writer (basically copying from a to b) |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
22 $(SPU_LIBDIR)/fb_writer_spu-embed.o: $(SPU_LIBDIR) $(SPU_SRCDIR)/fb_writer.c $(SPU_SRCDIR)/spu_common.h |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
23 $(SPU_GCC) $(SPU_CFLAGS) -o $(SPU_LIBDIR)/fb_writer_spu $(SPU_SRCDIR)/fb_writer.c -lm |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
24 $(PPU_EMBEDSPU) -m32 fb_writer_spu $(SPU_LIBDIR)/fb_writer_spu $(SPU_LIBDIR)/fb_writer_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
25 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
26 $(SPU_LIBDIR)/libfb_writer_spu.a: $(SPU_LIBDIR)/fb_writer_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
27 $(PPU_AR) -qcs $(SPU_LIBDIR)/libfb_writer_spu.a $(SPU_LIBDIR)/fb_writer_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
28 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
29 $(SPU_LIBDIR)/libfb_writer_spu.so: $(SPU_LIBDIR)/fb_writer_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
30 $(PPU_LD) -o $(SPU_LIBDIR)/libfb_writer_spu.so -shared -soname=libfb_writer_spu.so $(SPU_LIBDIR)/fb_writer_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
31 |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
32 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
33 # yuv2rgb_converter (converting YV12/IYUV to RGB) |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
34 $(SPU_LIBDIR)/yuv2rgb_spu-embed.o: $(SPU_LIBDIR) $(SPU_SRCDIR)/yuv2rgb_converter.c $(SPU_SRCDIR)/spu_common.h |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
35 $(SPU_GCC) $(SPU_CFLAGS) -o $(SPU_LIBDIR)/yuv2rgb_spu $(SPU_SRCDIR)/yuv2rgb_converter.c -lm |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
36 $(PPU_EMBEDSPU) -m32 yuv2rgb_spu $(SPU_LIBDIR)/yuv2rgb_spu $(SPU_LIBDIR)/yuv2rgb_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
37 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
38 $(SPU_LIBDIR)/libyuv2rgb_spu.a: $(SPU_LIBDIR)/yuv2rgb_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
39 $(PPU_AR) -qcs $(SPU_LIBDIR)/libyuv2rgb_spu.a $(SPU_LIBDIR)/yuv2rgb_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
40 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
41 $(SPU_LIBDIR)/libyuv2rgb_spu.so: $(SPU_LIBDIR)/yuv2rgb_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
42 $(PPU_LD) -o $(SPU_LIBDIR)/libyuv2rgb_spu.so -shared -soname=libyuv2rgb_spu.so $(SPU_LIBDIR)/yuv2rgb_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
43 |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
44 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
45 # bilin_scaler (scaling bilinear YV12/IYUV pictures with resolutions /16) |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
46 $(SPU_LIBDIR)/bilin_scaler_spu-embed.o: $(SPU_LIBDIR) $(SPU_SRCDIR)/bilin_scaler.c $(SPU_SRCDIR)/spu_common.h |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
47 $(SPU_GCC) $(SPU_CFLAGS) -o $(SPU_LIBDIR)/bilin_scaler_spu $(SPU_SRCDIR)/bilin_scaler.c -lm |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
48 $(PPU_EMBEDSPU) -m32 bilin_scaler_spu $(SPU_LIBDIR)/bilin_scaler_spu $(SPU_LIBDIR)/bilin_scaler_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
49 |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
50 $(SPU_LIBDIR)/libbilin_scaler_spu.a: $(SPU_LIBDIR)/bilin_scaler_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
51 $(PPU_AR) -qcs $(SPU_LIBDIR)/libbilin_scaler_spu.a $(SPU_LIBDIR)/bilin_scaler_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
52 |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
53 $(SPU_LIBDIR)/libbilin_scaler_spu.so: $(SPU_LIBDIR)/bilin_scaler_spu-embed.o |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
54 $(PPU_LD) -o $(SPU_LIBDIR)/libbilin_scaler_spu.so -shared -soname=libbilin_scaler_spu.so $(SPU_LIBDIR)/bilin_scaler_spu-embed.o |
3141
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
55 |
3df74541339b
Added ps3 video driver based on the dummy driver.
Martin Lowinski <martin@goldtopf.org>
parents:
diff
changeset
|
56 |
3154
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
57 ps3libs-install: $(SPU_LIBDIR)/libfb_writer_spu.a $(SPU_LIBDIR)/libfb_writer_spu.so \ |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
58 $(SPU_LIBDIR)/libyuv2rgb_spu.so $(SPU_LIBDIR)/libyuv2rgb_spu.a \ |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
59 $(SPU_LIBDIR)/libbilin_scaler_spu.so $(SPU_LIBDIR)/libbilin_scaler_spu.a |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
60 $(INSTALL) -c -m 0755 $(SPU_LIBDIR)/libfb_writer_spu.so $(DESTDIR)$(libdir)/. |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
61 $(INSTALL) -c -m 0655 $(SPU_LIBDIR)/libfb_writer_spu.a $(DESTDIR)$(libdir)/. |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
62 $(INSTALL) -c -m 0755 $(SPU_LIBDIR)/libyuv2rgb_spu.so $(DESTDIR)$(libdir)/. |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
63 $(INSTALL) -c -m 0655 $(SPU_LIBDIR)/libyuv2rgb_spu.a $(DESTDIR)$(libdir)/. |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
64 $(INSTALL) -c -m 0755 $(SPU_LIBDIR)/libbilin_scaler_spu.so $(DESTDIR)$(libdir)/. |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
65 $(INSTALL) -c -m 0655 $(SPU_LIBDIR)/libbilin_scaler_spu.a $(DESTDIR)$(libdir)/. |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
66 |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
67 ps3libs-uninstall: |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
68 rm -f $(DESTDIR)$(libdir)/libfb_writer_spu.a |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
69 rm -f $(DESTDIR)$(libdir)/libfb_writer_spu.so |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
70 rm -f $(DESTDIR)$(libdir)/libyuv2rgb_spu.so |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
71 rm -f $(DESTDIR)$(libdir)/libyuv2rgb_spu.a |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
72 rm -f $(DESTDIR)$(libdir)/libbilin_scaler_spu.so |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
73 rm -f $(DESTDIR)$(libdir)/libbilin_scaler_spu.a |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
74 |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
75 ps3libs-clean: |
95e48f7a3a93
Added Makefile rule for spu programs. Added Readme.
Martin Lowinski <martin@goldtopf.org>
parents:
3148
diff
changeset
|
76 rm -f $(SPU_LIBDIR)/* |