diff options
| author | Trevor Woerner <twoerner@gmail.com> | 2020-12-04 04:31:18 -0500 |
|---|---|---|
| committer | Andrei Gherzan <andrei@gherzan.ro> | 2020-12-13 20:34:11 +0000 |
| commit | e4f5c32925fec90ff688e51197cb052fe12af82e (patch) | |
| tree | 0c98090adde0686868bade5a1d3f2e797a3ed7fd | |
| parent | 4b89f636992b822d13ac748a9f959fbedd962fd4 (diff) | |
| download | meta-raspberrypi-e4f5c32925fec90ff688e51197cb052fe12af82e.tar.gz | |
raspidmx: add
Add a recipe to build a set of dispmanx examples.
Signed-off-by: Trevor Woerner <twoerner@gmail.com>
8 files changed, 720 insertions, 0 deletions
diff --git a/recipes-graphics/raspidmx/raspidmx/0001-gitignore-add-archives-from-lib-directory.patch b/recipes-graphics/raspidmx/raspidmx/0001-gitignore-add-archives-from-lib-directory.patch new file mode 100644 index 0000000..de9d5c3 --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0001-gitignore-add-archives-from-lib-directory.patch | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | From 070b114fd54b6ad38b4eff04279fe89ccaaef61b Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 01:39:30 -0500 | ||
| 4 | Subject: [PATCH] gitignore: add archives from lib directory | ||
| 5 | |||
| 6 | The build creates two *.a files in the lib directory, add these to .gitignore. | ||
| 7 | |||
| 8 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 9 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 10 | --- | ||
| 11 | .gitignore | 1 + | ||
| 12 | 1 file changed, 1 insertion(+) | ||
| 13 | |||
| 14 | diff --git a/.gitignore b/.gitignore | ||
| 15 | index 633f325..4a1ca0c 100644 | ||
| 16 | --- a/.gitignore | ||
| 17 | +++ b/.gitignore | ||
| 18 | @@ -21,5 +21,6 @@ test_pattern/test_pattern | ||
| 19 | worms/worms | ||
| 20 | |||
| 21 | # other directories | ||
| 22 | +lib/*.a | ||
| 23 | |||
| 24 | *_/ | ||
diff --git a/recipes-graphics/raspidmx/raspidmx/0002-add-install-targets-to-Makefiles.patch b/recipes-graphics/raspidmx/raspidmx/0002-add-install-targets-to-Makefiles.patch new file mode 100644 index 0000000..c02a767 --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0002-add-install-targets-to-Makefiles.patch | |||
| @@ -0,0 +1,214 @@ | |||
| 1 | From 3b60fa1598385fb36fef1c47f59cb08d3a6fba35 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 01:54:37 -0500 | ||
| 4 | Subject: [PATCH] add "install" targets to Makefiles | ||
| 5 | |||
| 6 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 7 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 8 | --- | ||
| 9 | Makefile | 3 +++ | ||
| 10 | game/Makefile | 4 ++++ | ||
| 11 | lib/Makefile | 1 + | ||
| 12 | life/Makefile | 4 ++++ | ||
| 13 | mandelbrot/Makefile | 4 ++++ | ||
| 14 | offscreen/Makefile | 4 ++++ | ||
| 15 | pngview/Makefile | 4 ++++ | ||
| 16 | radar_sweep/Makefile | 4 ++++ | ||
| 17 | radar_sweep_alpha/Makefile | 4 ++++ | ||
| 18 | rgb_triangle/Makefile | 4 ++++ | ||
| 19 | spriteview/Makefile | 4 ++++ | ||
| 20 | test_pattern/Makefile | 4 ++++ | ||
| 21 | worms/Makefile | 4 ++++ | ||
| 22 | 13 files changed, 48 insertions(+) | ||
| 23 | |||
| 24 | diff --git a/Makefile b/Makefile | ||
| 25 | index 4e14e18..4a06de9 100644 | ||
| 26 | --- a/Makefile | ||
| 27 | +++ b/Makefile | ||
| 28 | @@ -16,6 +16,9 @@ default :all | ||
| 29 | all: | ||
| 30 | for target in $(TARGETS); do ($(MAKE) -C $$target); done | ||
| 31 | |||
| 32 | +install: | ||
| 33 | + for target in $(TARGETS); do ($(MAKE) -C $$target install); done | ||
| 34 | + | ||
| 35 | clean: | ||
| 36 | for target in $(TARGETS); do ($(MAKE) -C $$target clean); done | ||
| 37 | |||
| 38 | diff --git a/game/Makefile b/game/Makefile | ||
| 39 | index ced9cce..6da6a6d 100644 | ||
| 40 | --- a/game/Makefile | ||
| 41 | +++ b/game/Makefile | ||
| 42 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 43 | $(BIN): $(OBJS) | ||
| 44 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 45 | |||
| 46 | +install: $(BIN) | ||
| 47 | + install -d $(DESTDIR)/usr/bin | ||
| 48 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 49 | + | ||
| 50 | clean: | ||
| 51 | @rm -f $(OBJS) | ||
| 52 | @rm -f $(BIN) | ||
| 53 | diff --git a/lib/Makefile b/lib/Makefile | ||
| 54 | index 15d7c37..2765c91 100644 | ||
| 55 | --- a/lib/Makefile | ||
| 56 | +++ b/lib/Makefile | ||
| 57 | @@ -29,6 +29,7 @@ $(LIB): $(OBJS) | ||
| 58 | $(LIBPNG): $(OBJSPNG) | ||
| 59 | $(AR) rcs lib$(LIBPNG).a $(OBJSPNG) | ||
| 60 | |||
| 61 | +install: | ||
| 62 | |||
| 63 | clean: | ||
| 64 | @rm -f $(OBJS) | ||
| 65 | diff --git a/life/Makefile b/life/Makefile | ||
| 66 | index 2fcb034..44f1edb 100644 | ||
| 67 | --- a/life/Makefile | ||
| 68 | +++ b/life/Makefile | ||
| 69 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 70 | $(BIN): $(OBJS) | ||
| 71 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -pthread -Wl,--no-whole-archive -rdynamic | ||
| 72 | |||
| 73 | +install: $(BIN) | ||
| 74 | + install -d $(DESTDIR)/usr/bin | ||
| 75 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 76 | + | ||
| 77 | clean: | ||
| 78 | @rm -f $(OBJS) | ||
| 79 | @rm -f $(BIN) | ||
| 80 | diff --git a/mandelbrot/Makefile b/mandelbrot/Makefile | ||
| 81 | index e61beb3..a6e6735 100644 | ||
| 82 | --- a/mandelbrot/Makefile | ||
| 83 | +++ b/mandelbrot/Makefile | ||
| 84 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 85 | $(BIN): $(OBJS) | ||
| 86 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -pthread -Wl,--no-whole-archive -rdynamic | ||
| 87 | |||
| 88 | +install: $(BIN) | ||
| 89 | + install -d $(DESTDIR)/usr/bin | ||
| 90 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 91 | + | ||
| 92 | clean: | ||
| 93 | @rm -f $(OBJS) | ||
| 94 | @rm -f $(BIN) | ||
| 95 | diff --git a/offscreen/Makefile b/offscreen/Makefile | ||
| 96 | index 2bc81b9..8d23354 100644 | ||
| 97 | --- a/offscreen/Makefile | ||
| 98 | +++ b/offscreen/Makefile | ||
| 99 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 100 | $(BIN): $(OBJS) | ||
| 101 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 102 | |||
| 103 | +install: $(BIN) | ||
| 104 | + install -d $(DESTDIR)/usr/bin | ||
| 105 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 106 | + | ||
| 107 | clean: | ||
| 108 | @rm -f $(OBJS) | ||
| 109 | @rm -f $(BIN) | ||
| 110 | diff --git a/pngview/Makefile b/pngview/Makefile | ||
| 111 | index f947320..8c037ec 100644 | ||
| 112 | --- a/pngview/Makefile | ||
| 113 | +++ b/pngview/Makefile | ||
| 114 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 115 | $(BIN): $(OBJS) | ||
| 116 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 117 | |||
| 118 | +install: $(BIN) | ||
| 119 | + install -d $(DESTDIR)/usr/bin | ||
| 120 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 121 | + | ||
| 122 | clean: | ||
| 123 | @rm -f $(OBJS) | ||
| 124 | @rm -f $(BIN) | ||
| 125 | diff --git a/radar_sweep/Makefile b/radar_sweep/Makefile | ||
| 126 | index 3a46150..5f814b7 100644 | ||
| 127 | --- a/radar_sweep/Makefile | ||
| 128 | +++ b/radar_sweep/Makefile | ||
| 129 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 130 | $(BIN): $(OBJS) | ||
| 131 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 132 | |||
| 133 | +install: $(BIN) | ||
| 134 | + install -d $(DESTDIR)/usr/bin | ||
| 135 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 136 | + | ||
| 137 | clean: | ||
| 138 | @rm -f $(OBJS) | ||
| 139 | @rm -f $(BIN) | ||
| 140 | diff --git a/radar_sweep_alpha/Makefile b/radar_sweep_alpha/Makefile | ||
| 141 | index 5680b9b..f66c338 100644 | ||
| 142 | --- a/radar_sweep_alpha/Makefile | ||
| 143 | +++ b/radar_sweep_alpha/Makefile | ||
| 144 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 145 | $(BIN): $(OBJS) | ||
| 146 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 147 | |||
| 148 | +install: $(BIN) | ||
| 149 | + install -d $(DESTDIR)/usr/bin | ||
| 150 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 151 | + | ||
| 152 | clean: | ||
| 153 | @rm -f $(OBJS) | ||
| 154 | @rm -f $(BIN) | ||
| 155 | diff --git a/rgb_triangle/Makefile b/rgb_triangle/Makefile | ||
| 156 | index 2017956..2ce779d 100644 | ||
| 157 | --- a/rgb_triangle/Makefile | ||
| 158 | +++ b/rgb_triangle/Makefile | ||
| 159 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 160 | $(BIN): $(OBJS) | ||
| 161 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 162 | |||
| 163 | +install: $(BIN) | ||
| 164 | + install -d $(DESTDIR)/usr/bin | ||
| 165 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 166 | + | ||
| 167 | clean: | ||
| 168 | @rm -f $(OBJS) | ||
| 169 | @rm -f $(BIN) | ||
| 170 | diff --git a/spriteview/Makefile b/spriteview/Makefile | ||
| 171 | index 2713936..ada9277 100644 | ||
| 172 | --- a/spriteview/Makefile | ||
| 173 | +++ b/spriteview/Makefile | ||
| 174 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 175 | $(BIN): $(OBJS) | ||
| 176 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 177 | |||
| 178 | +install: $(BIN) | ||
| 179 | + install -d $(DESTDIR)/usr/bin | ||
| 180 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 181 | + | ||
| 182 | clean: | ||
| 183 | @rm -f $(OBJS) | ||
| 184 | @rm -f $(BIN) | ||
| 185 | diff --git a/test_pattern/Makefile b/test_pattern/Makefile | ||
| 186 | index be434d9..1e02b0a 100644 | ||
| 187 | --- a/test_pattern/Makefile | ||
| 188 | +++ b/test_pattern/Makefile | ||
| 189 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 190 | $(BIN): $(OBJS) | ||
| 191 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 192 | |||
| 193 | +install: $(BIN) | ||
| 194 | + install -d $(DESTDIR)/usr/bin | ||
| 195 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 196 | + | ||
| 197 | clean: | ||
| 198 | @rm -f $(OBJS) | ||
| 199 | @rm -f $(BIN) | ||
| 200 | diff --git a/worms/Makefile b/worms/Makefile | ||
| 201 | index 2a21a4b..c249c8c 100644 | ||
| 202 | --- a/worms/Makefile | ||
| 203 | +++ b/worms/Makefile | ||
| 204 | @@ -15,6 +15,10 @@ all: $(BIN) | ||
| 205 | $(BIN): $(OBJS) | ||
| 206 | $(CC) -o $@ -Wl,--whole-archive $(OBJS) $(LDFLAGS) -Wl,--no-whole-archive -rdynamic | ||
| 207 | |||
| 208 | +install: $(BIN) | ||
| 209 | + install -d $(DESTDIR)/usr/bin | ||
| 210 | + install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 211 | + | ||
| 212 | clean: | ||
| 213 | @rm -f $(OBJS) | ||
| 214 | @rm -f $(BIN) | ||
diff --git a/recipes-graphics/raspidmx/raspidmx/0003-switch-to-pkg-config.patch b/recipes-graphics/raspidmx/raspidmx/0003-switch-to-pkg-config.patch new file mode 100644 index 0000000..7adb12b --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0003-switch-to-pkg-config.patch | |||
| @@ -0,0 +1,114 @@ | |||
| 1 | From 314fbde187e9187b1b3e18e50dd937c070e93633 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 01:58:59 -0500 | ||
| 4 | Subject: [PATCH] switch to "pkg-config" | ||
| 5 | |||
| 6 | I get a build error saying: | ||
| 7 | |||
| 8 | ERROR: /usr/bin/libpng16-config should not be used, use an alternative such as pkg-config | ||
| 9 | |||
| 10 | Therefore switch to the more common and more generic "pkg-config" instead of | ||
| 11 | using a libpng-specific tool for flags and libraries. | ||
| 12 | |||
| 13 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 14 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 15 | --- | ||
| 16 | game/Makefile | 4 ++-- | ||
| 17 | lib/Makefile | 4 ++-- | ||
| 18 | mandelbrot/Makefile | 4 ++-- | ||
| 19 | offscreen/Makefile | 4 ++-- | ||
| 20 | pngview/Makefile | 4 ++-- | ||
| 21 | spriteview/Makefile | 4 ++-- | ||
| 22 | 6 files changed, 12 insertions(+), 12 deletions(-) | ||
| 23 | |||
| 24 | diff --git a/game/Makefile b/game/Makefile | ||
| 25 | index 6da6a6d..0a90a38 100644 | ||
| 26 | --- a/game/Makefile | ||
| 27 | +++ b/game/Makefile | ||
| 28 | @@ -1,8 +1,8 @@ | ||
| 29 | OBJS=main.o | ||
| 30 | BIN=game | ||
| 31 | |||
| 32 | -CFLAGS+=-Wall -g -O3 -I../common $(shell libpng-config --cflags) | ||
| 33 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell libpng-config --ldflags) -L../lib -lraspidmx -lraspidmxPng | ||
| 34 | +CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 35 | +LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 36 | |||
| 37 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 38 | |||
| 39 | diff --git a/lib/Makefile b/lib/Makefile | ||
| 40 | index 2765c91..1e8c759 100644 | ||
| 41 | --- a/lib/Makefile | ||
| 42 | +++ b/lib/Makefile | ||
| 43 | @@ -11,9 +11,9 @@ OBJS=../common/backgroundLayer.o ../common/imageGraphics.o ../common/key.o \ | ||
| 44 | |||
| 45 | OBJSPNG=../common/spriteLayer.o ../common/loadpng.o ../common/savepng.o ../common/scrollingLayer.o | ||
| 46 | |||
| 47 | -CFLAGS+=-Wall -g -O3 -I../common $(shell libpng-config --cflags) | ||
| 48 | +CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 49 | LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm | ||
| 50 | -LDFLAGSPNG=${LDFLAGS} $(shell libpng-config --ldflags) | ||
| 51 | +LDFLAGSPNG=${LDFLAGS} $(shell pkg-config --libs libpng) | ||
| 52 | |||
| 53 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 54 | |||
| 55 | diff --git a/mandelbrot/Makefile b/mandelbrot/Makefile | ||
| 56 | index a6e6735..82910bb 100644 | ||
| 57 | --- a/mandelbrot/Makefile | ||
| 58 | +++ b/mandelbrot/Makefile | ||
| 59 | @@ -1,8 +1,8 @@ | ||
| 60 | OBJS=main.o mandelbrot.o info.o | ||
| 61 | BIN=mandelbrot | ||
| 62 | |||
| 63 | -CFLAGS+=-Wall -g -O3 -I../common $(shell libpng-config --cflags) | ||
| 64 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell libpng-config --ldflags) -L../lib -lraspidmx -lraspidmxPng | ||
| 65 | +CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 66 | +LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 67 | |||
| 68 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 69 | |||
| 70 | diff --git a/offscreen/Makefile b/offscreen/Makefile | ||
| 71 | index 8d23354..0120796 100644 | ||
| 72 | --- a/offscreen/Makefile | ||
| 73 | +++ b/offscreen/Makefile | ||
| 74 | @@ -1,8 +1,8 @@ | ||
| 75 | OBJS=pngresize.o resizeDispmanX.o | ||
| 76 | BIN=pngresize | ||
| 77 | |||
| 78 | -CFLAGS+=-Wall -g -O3 -I../common $(shell libpng-config --cflags) | ||
| 79 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell libpng-config --ldflags) -L../lib -lraspidmx -lraspidmxPng | ||
| 80 | +CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 81 | +LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 82 | |||
| 83 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 84 | |||
| 85 | diff --git a/pngview/Makefile b/pngview/Makefile | ||
| 86 | index 8c037ec..71a5d76 100644 | ||
| 87 | --- a/pngview/Makefile | ||
| 88 | +++ b/pngview/Makefile | ||
| 89 | @@ -1,8 +1,8 @@ | ||
| 90 | OBJS=pngview.o | ||
| 91 | BIN=pngview | ||
| 92 | |||
| 93 | -CFLAGS+=-Wall -g -O3 -I../common $(shell libpng-config --cflags) | ||
| 94 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell libpng-config --ldflags) -L../lib -lraspidmx -lraspidmxPng | ||
| 95 | +CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 96 | +LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 97 | |||
| 98 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 99 | |||
| 100 | diff --git a/spriteview/Makefile b/spriteview/Makefile | ||
| 101 | index ada9277..904c1e8 100644 | ||
| 102 | --- a/spriteview/Makefile | ||
| 103 | +++ b/spriteview/Makefile | ||
| 104 | @@ -1,8 +1,8 @@ | ||
| 105 | OBJS=spriteview.o | ||
| 106 | BIN=spriteview | ||
| 107 | |||
| 108 | -CFLAGS+=-Wall -g -O3 -I../common $(shell libpng-config --cflags) | ||
| 109 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell libpng-config --ldflags) -L../lib -lraspidmx -lraspidmxPng | ||
| 110 | +CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 111 | +LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 112 | |||
| 113 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 114 | |||
diff --git a/recipes-graphics/raspidmx/raspidmx/0004-add-libvchostif-to-link.patch b/recipes-graphics/raspidmx/raspidmx/0004-add-libvchostif-to-link.patch new file mode 100644 index 0000000..908be62 --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0004-add-libvchostif-to-link.patch | |||
| @@ -0,0 +1,170 @@ | |||
| 1 | From bde71fc22bde61ef8fe319c60f478ec370f5bc5d Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 02:13:39 -0500 | ||
| 4 | Subject: [PATCH] add libvchostif to link | ||
| 5 | |||
| 6 | I end up with link errors of the type: | ||
| 7 | |||
| 8 | libvchostif.so: error adding symbols: DSO missing from command line | ||
| 9 | |||
| 10 | Which is caused by not having -lvchostif in the link. | ||
| 11 | |||
| 12 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 13 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 14 | --- | ||
| 15 | game/Makefile | 2 +- | ||
| 16 | life/Makefile | 2 +- | ||
| 17 | mandelbrot/Makefile | 2 +- | ||
| 18 | offscreen/Makefile | 2 +- | ||
| 19 | pngview/Makefile | 2 +- | ||
| 20 | radar_sweep/Makefile | 2 +- | ||
| 21 | radar_sweep_alpha/Makefile | 2 +- | ||
| 22 | rgb_triangle/Makefile | 2 +- | ||
| 23 | spriteview/Makefile | 2 +- | ||
| 24 | test_pattern/Makefile | 2 +- | ||
| 25 | worms/Makefile | 2 +- | ||
| 26 | 11 files changed, 11 insertions(+), 11 deletions(-) | ||
| 27 | |||
| 28 | diff --git a/game/Makefile b/game/Makefile | ||
| 29 | index 0a90a38..b756fa2 100644 | ||
| 30 | --- a/game/Makefile | ||
| 31 | +++ b/game/Makefile | ||
| 32 | @@ -2,7 +2,7 @@ OBJS=main.o | ||
| 33 | BIN=game | ||
| 34 | |||
| 35 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 36 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 37 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 38 | |||
| 39 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 40 | |||
| 41 | diff --git a/life/Makefile b/life/Makefile | ||
| 42 | index 44f1edb..2addf69 100644 | ||
| 43 | --- a/life/Makefile | ||
| 44 | +++ b/life/Makefile | ||
| 45 | @@ -2,7 +2,7 @@ OBJS=main.o life.o info.o | ||
| 46 | BIN=life | ||
| 47 | |||
| 48 | CFLAGS+=-Wall -g -O3 -I../common | ||
| 49 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -L../lib -lraspidmx | ||
| 50 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -L../lib -lraspidmx | ||
| 51 | |||
| 52 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 53 | |||
| 54 | diff --git a/mandelbrot/Makefile b/mandelbrot/Makefile | ||
| 55 | index 82910bb..31097f2 100644 | ||
| 56 | --- a/mandelbrot/Makefile | ||
| 57 | +++ b/mandelbrot/Makefile | ||
| 58 | @@ -2,7 +2,7 @@ OBJS=main.o mandelbrot.o info.o | ||
| 59 | BIN=mandelbrot | ||
| 60 | |||
| 61 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 62 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 63 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 64 | |||
| 65 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 66 | |||
| 67 | diff --git a/offscreen/Makefile b/offscreen/Makefile | ||
| 68 | index 0120796..4f13fd0 100644 | ||
| 69 | --- a/offscreen/Makefile | ||
| 70 | +++ b/offscreen/Makefile | ||
| 71 | @@ -2,7 +2,7 @@ OBJS=pngresize.o resizeDispmanX.o | ||
| 72 | BIN=pngresize | ||
| 73 | |||
| 74 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 75 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 76 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 77 | |||
| 78 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 79 | |||
| 80 | diff --git a/pngview/Makefile b/pngview/Makefile | ||
| 81 | index 71a5d76..cce8d63 100644 | ||
| 82 | --- a/pngview/Makefile | ||
| 83 | +++ b/pngview/Makefile | ||
| 84 | @@ -2,7 +2,7 @@ OBJS=pngview.o | ||
| 85 | BIN=pngview | ||
| 86 | |||
| 87 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 88 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 89 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 90 | |||
| 91 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 92 | |||
| 93 | diff --git a/radar_sweep/Makefile b/radar_sweep/Makefile | ||
| 94 | index 5f814b7..aa1d32c 100644 | ||
| 95 | --- a/radar_sweep/Makefile | ||
| 96 | +++ b/radar_sweep/Makefile | ||
| 97 | @@ -2,7 +2,7 @@ OBJS=radar_sweep.o | ||
| 98 | BIN=radar_sweep | ||
| 99 | |||
| 100 | CFLAGS+=-Wall -O3 -g -I../common | ||
| 101 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm -L../lib -lraspidmx | ||
| 102 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx | ||
| 103 | |||
| 104 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 105 | |||
| 106 | diff --git a/radar_sweep_alpha/Makefile b/radar_sweep_alpha/Makefile | ||
| 107 | index f66c338..571d47b 100644 | ||
| 108 | --- a/radar_sweep_alpha/Makefile | ||
| 109 | +++ b/radar_sweep_alpha/Makefile | ||
| 110 | @@ -2,7 +2,7 @@ OBJS=radar_sweep_alpha.o | ||
| 111 | BIN=radar_sweep_alpha | ||
| 112 | |||
| 113 | CFLAGS+=-Wall -O3 -g -I../common | ||
| 114 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm -L../lib -lraspidmx | ||
| 115 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx | ||
| 116 | |||
| 117 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 118 | |||
| 119 | diff --git a/rgb_triangle/Makefile b/rgb_triangle/Makefile | ||
| 120 | index 2ce779d..0266715 100644 | ||
| 121 | --- a/rgb_triangle/Makefile | ||
| 122 | +++ b/rgb_triangle/Makefile | ||
| 123 | @@ -2,7 +2,7 @@ OBJS=rgb_triangle.o | ||
| 124 | BIN=rgb_triangle | ||
| 125 | |||
| 126 | CFLAGS+=-Wall -O3 -g -I../common | ||
| 127 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm -L../lib -lraspidmx | ||
| 128 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx | ||
| 129 | |||
| 130 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 131 | |||
| 132 | diff --git a/spriteview/Makefile b/spriteview/Makefile | ||
| 133 | index 904c1e8..d2fb3c8 100644 | ||
| 134 | --- a/spriteview/Makefile | ||
| 135 | +++ b/spriteview/Makefile | ||
| 136 | @@ -2,7 +2,7 @@ OBJS=spriteview.o | ||
| 137 | BIN=spriteview | ||
| 138 | |||
| 139 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 140 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 141 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 142 | |||
| 143 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 144 | |||
| 145 | diff --git a/test_pattern/Makefile b/test_pattern/Makefile | ||
| 146 | index 1e02b0a..c231fb6 100644 | ||
| 147 | --- a/test_pattern/Makefile | ||
| 148 | +++ b/test_pattern/Makefile | ||
| 149 | @@ -2,7 +2,7 @@ OBJS=test_pattern.o | ||
| 150 | BIN=test_pattern | ||
| 151 | |||
| 152 | CFLAGS+=-Wall -g -O3 -I../common | ||
| 153 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm -L../lib -lraspidmx | ||
| 154 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx | ||
| 155 | |||
| 156 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 157 | |||
| 158 | diff --git a/worms/Makefile b/worms/Makefile | ||
| 159 | index c249c8c..3b6c830 100644 | ||
| 160 | --- a/worms/Makefile | ||
| 161 | +++ b/worms/Makefile | ||
| 162 | @@ -2,7 +2,7 @@ OBJS=main.o worms.o | ||
| 163 | BIN=worms | ||
| 164 | |||
| 165 | CFLAGS+=-Wall -g -O3 -I../common | ||
| 166 | -LDFLAGS+=-L/opt/vc/lib/ -lbcm_host -lm -L../lib -lraspidmx | ||
| 167 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx | ||
| 168 | |||
| 169 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 170 | |||
diff --git a/recipes-graphics/raspidmx/raspidmx/0005-change-library-linking-order.patch b/recipes-graphics/raspidmx/raspidmx/0005-change-library-linking-order.patch new file mode 100644 index 0000000..ceefd03 --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0005-change-library-linking-order.patch | |||
| @@ -0,0 +1,87 @@ | |||
| 1 | From 07e7b727b7df7fc5bf0e1f296ba136e0653202ea Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 03:25:08 -0500 | ||
| 4 | Subject: [PATCH] change library linking order | ||
| 5 | |||
| 6 | Since -lraspidmxPng requires the png library (libpng), re-arrange the order of | ||
| 7 | linking so that it succeeds. Otherwise I get errors like the following: | ||
| 8 | |||
| 9 | undefined reference to `png_create_write_struct' | ||
| 10 | |||
| 11 | ...as well as undefined references to various other libpng objects. | ||
| 12 | |||
| 13 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 14 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 15 | --- | ||
| 16 | game/Makefile | 2 +- | ||
| 17 | mandelbrot/Makefile | 2 +- | ||
| 18 | offscreen/Makefile | 2 +- | ||
| 19 | pngview/Makefile | 2 +- | ||
| 20 | spriteview/Makefile | 2 +- | ||
| 21 | 5 files changed, 5 insertions(+), 5 deletions(-) | ||
| 22 | |||
| 23 | diff --git a/game/Makefile b/game/Makefile | ||
| 24 | index b756fa2..f33916d 100644 | ||
| 25 | --- a/game/Makefile | ||
| 26 | +++ b/game/Makefile | ||
| 27 | @@ -2,7 +2,7 @@ OBJS=main.o | ||
| 28 | BIN=game | ||
| 29 | |||
| 30 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 31 | -LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 32 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx -lraspidmxPng $(shell pkg-config --libs libpng) | ||
| 33 | |||
| 34 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 35 | |||
| 36 | diff --git a/mandelbrot/Makefile b/mandelbrot/Makefile | ||
| 37 | index 31097f2..08d1113 100644 | ||
| 38 | --- a/mandelbrot/Makefile | ||
| 39 | +++ b/mandelbrot/Makefile | ||
| 40 | @@ -2,7 +2,7 @@ OBJS=main.o mandelbrot.o info.o | ||
| 41 | BIN=mandelbrot | ||
| 42 | |||
| 43 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 44 | -LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 45 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx -lraspidmxPng $(shell pkg-config --libs libpng) | ||
| 46 | |||
| 47 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 48 | |||
| 49 | diff --git a/offscreen/Makefile b/offscreen/Makefile | ||
| 50 | index 4f13fd0..49fc744 100644 | ||
| 51 | --- a/offscreen/Makefile | ||
| 52 | +++ b/offscreen/Makefile | ||
| 53 | @@ -2,7 +2,7 @@ OBJS=pngresize.o resizeDispmanX.o | ||
| 54 | BIN=pngresize | ||
| 55 | |||
| 56 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 57 | -LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 58 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx -lraspidmxPng $(shell pkg-config --libs libpng) | ||
| 59 | |||
| 60 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 61 | |||
| 62 | diff --git a/pngview/Makefile b/pngview/Makefile | ||
| 63 | index cce8d63..bd6c154 100644 | ||
| 64 | --- a/pngview/Makefile | ||
| 65 | +++ b/pngview/Makefile | ||
| 66 | @@ -2,7 +2,7 @@ OBJS=pngview.o | ||
| 67 | BIN=pngview | ||
| 68 | |||
| 69 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 70 | -LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 71 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx -lraspidmxPng $(shell pkg-config --libs libpng) | ||
| 72 | |||
| 73 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 74 | |||
| 75 | diff --git a/spriteview/Makefile b/spriteview/Makefile | ||
| 76 | index d2fb3c8..89d9e01 100644 | ||
| 77 | --- a/spriteview/Makefile | ||
| 78 | +++ b/spriteview/Makefile | ||
| 79 | @@ -2,7 +2,7 @@ OBJS=spriteview.o | ||
| 80 | BIN=spriteview | ||
| 81 | |||
| 82 | CFLAGS+=-Wall -g -O3 -I../common $(shell pkg-config --cflags libpng) | ||
| 83 | -LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm $(shell pkg-config --libs libpng) -L../lib -lraspidmx -lraspidmxPng | ||
| 84 | +LDFLAGS+=-L/opt/vc/lib/ -lvchostif -lbcm_host -lm -L../lib -lraspidmx -lraspidmxPng $(shell pkg-config --libs libpng) | ||
| 85 | |||
| 86 | INCLUDES+=-I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux | ||
| 87 | |||
diff --git a/recipes-graphics/raspidmx/raspidmx/0006-game-Makefile-install-sample-png-files.patch b/recipes-graphics/raspidmx/raspidmx/0006-game-Makefile-install-sample-png-files.patch new file mode 100644 index 0000000..dae847d --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0006-game-Makefile-install-sample-png-files.patch | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | From 1868a111450be0053ab124df501cfcb7542f5e77 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 03:47:17 -0500 | ||
| 4 | Subject: [PATCH] game/Makefile: install sample png files | ||
| 5 | |||
| 6 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 7 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 8 | --- | ||
| 9 | game/Makefile | 2 ++ | ||
| 10 | 1 file changed, 2 insertions(+) | ||
| 11 | |||
| 12 | diff --git a/game/Makefile b/game/Makefile | ||
| 13 | index f33916d..d007972 100644 | ||
| 14 | --- a/game/Makefile | ||
| 15 | +++ b/game/Makefile | ||
| 16 | @@ -18,6 +18,8 @@ $(BIN): $(OBJS) | ||
| 17 | install: $(BIN) | ||
| 18 | install -d $(DESTDIR)/usr/bin | ||
| 19 | install -m 0755 $(BIN) $(DESTDIR)/usr/bin | ||
| 20 | + install -d $(DESTDIR)/usr/share/raspidmx | ||
| 21 | + install -m 444 spotlight.png sprite.png texture.png $(DESTDIR)/usr/share/raspidmx | ||
| 22 | |||
| 23 | clean: | ||
| 24 | @rm -f $(OBJS) | ||
diff --git a/recipes-graphics/raspidmx/raspidmx/0007-Makefile-reorganize.patch b/recipes-graphics/raspidmx/raspidmx/0007-Makefile-reorganize.patch new file mode 100644 index 0000000..b5c743e --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx/0007-Makefile-reorganize.patch | |||
| @@ -0,0 +1,57 @@ | |||
| 1 | From f195ffffb133c9cda88d5eac41c0f584fd4540c9 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Fri, 4 Dec 2020 03:48:36 -0500 | ||
| 4 | Subject: [PATCH] Makefile: reorganize | ||
| 5 | |||
| 6 | Reorganize the main Makefile in order to: | ||
| 7 | 1. be able to build in parallel | ||
| 8 | 2. have build failures in subdirectories stop the build | ||
| 9 | |||
| 10 | Now the "-j <#threads>" option can be used with 'make'. | ||
| 11 | |||
| 12 | Also, if a build failure occurs in a subdirectory, this new arrangement will | ||
| 13 | cause the build to stop and fail instead of silently ignoring it. | ||
| 14 | |||
| 15 | To build simply invoke 'make' with or without a -j option. | ||
| 16 | To install simply invoke: make TARGET=install | ||
| 17 | To clean simply invoke: make TARGET=clean | ||
| 18 | |||
| 19 | Upstream-status: submitted [https://github.com/AndrewFromMelbourne/raspidmx/pull/29] | ||
| 20 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 21 | --- | ||
| 22 | Makefile | 19 +++++++------------ | ||
| 23 | 1 file changed, 7 insertions(+), 12 deletions(-) | ||
| 24 | |||
| 25 | diff --git a/Makefile b/Makefile | ||
| 26 | index 4a06de9..1f9f7c4 100644 | ||
| 27 | --- a/Makefile | ||
| 28 | +++ b/Makefile | ||
| 29 | @@ -1,5 +1,4 @@ | ||
| 30 | -TARGETS=lib \ | ||
| 31 | - life \ | ||
| 32 | +TARGETS=life \ | ||
| 33 | mandelbrot \ | ||
| 34 | offscreen \ | ||
| 35 | pngview \ | ||
| 36 | @@ -10,15 +9,11 @@ TARGETS=lib \ | ||
| 37 | spriteview \ | ||
| 38 | test_pattern \ | ||
| 39 | worms | ||
| 40 | +.PHONY: all lib install clean $(TARGETS) | ||
| 41 | |||
| 42 | -default :all | ||
| 43 | - | ||
| 44 | -all: | ||
| 45 | - for target in $(TARGETS); do ($(MAKE) -C $$target); done | ||
| 46 | - | ||
| 47 | -install: | ||
| 48 | - for target in $(TARGETS); do ($(MAKE) -C $$target install); done | ||
| 49 | - | ||
| 50 | -clean: | ||
| 51 | - for target in $(TARGETS); do ($(MAKE) -C $$target clean); done | ||
| 52 | +all: $(TARGETS) | ||
| 53 | |||
| 54 | +$(TARGETS): lib | ||
| 55 | + $(MAKE) -C $@ $(TARGET) | ||
| 56 | +lib: | ||
| 57 | + $(MAKE) -C $@ $(TARGET) | ||
diff --git a/recipes-graphics/raspidmx/raspidmx_git.bb b/recipes-graphics/raspidmx/raspidmx_git.bb new file mode 100644 index 0000000..ffe305a --- /dev/null +++ b/recipes-graphics/raspidmx/raspidmx_git.bb | |||
| @@ -0,0 +1,30 @@ | |||
| 1 | SUMMARY = "Some examples using the DispmanX API on the Raspberry Pi" | ||
| 2 | HOMEPAGE = "https://github.com/AndrewFromMelbourne/raspidmx" | ||
| 3 | SECTION = "graphics" | ||
| 4 | LICENSE = "MIT" | ||
| 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=52962875ab02c36df6cde47b1f463024" | ||
| 6 | |||
| 7 | COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', 'null', '(.*)', d)}" | ||
| 8 | |||
| 9 | SRC_URI = "git://github.com/AndrewFromMelbourne/raspidmx;protocol=https \ | ||
| 10 | file://0001-gitignore-add-archives-from-lib-directory.patch \ | ||
| 11 | file://0002-add-install-targets-to-Makefiles.patch \ | ||
| 12 | file://0003-switch-to-pkg-config.patch \ | ||
| 13 | file://0004-add-libvchostif-to-link.patch \ | ||
| 14 | file://0005-change-library-linking-order.patch \ | ||
| 15 | file://0006-game-Makefile-install-sample-png-files.patch \ | ||
| 16 | file://0007-Makefile-reorganize.patch \ | ||
| 17 | " | ||
| 18 | |||
| 19 | PV = "0.0+git${SRCPV}" | ||
| 20 | SRCREV = "e2ee6faa0d01a5ece06bcc74a47f37d7e6837310" | ||
| 21 | |||
| 22 | S = "${WORKDIR}/git" | ||
| 23 | |||
| 24 | inherit pkgconfig | ||
| 25 | |||
| 26 | DEPENDS += "libpng userland" | ||
| 27 | |||
| 28 | do_install () { | ||
| 29 | oe_runmake 'DESTDIR=${D}' 'TARGET=install' | ||
| 30 | } | ||
