diff options
author | Andrei Gherzan <andrei@gherzan.ro> | 2015-10-13 19:19:55 +0200 |
---|---|---|
committer | Andrei Gherzan <andrei@gherzan.ro> | 2015-10-13 19:20:00 +0200 |
commit | 72ea51f87b6c22e7cfbdf0541d7b380ef73bf10d (patch) | |
tree | c6e1fcf622ef67e2bd3c339b0c58ffa9514c9704 | |
parent | 4dfa633d2387cf6e88d05635d817289d33c1d905 (diff) | |
download | meta-raspberrypi-72ea51f87b6c22e7cfbdf0541d7b380ef73bf10d.tar.gz |
wiringPi: Bump to 2.29
The patch was rebased to apply on the updated version.
Signed-off-by: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com>
Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
-rw-r--r-- | patch | 550 | ||||
-rw-r--r-- | recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch | 355 | ||||
-rw-r--r-- | recipes-devtools/wiringPi/wiringpi_git.bb | 3 |
3 files changed, 720 insertions, 188 deletions
@@ -0,0 +1,550 @@ | |||
1 | From 1913375d97caee1279345fbbf776472d769f4c5e Mon Sep 17 00:00:00 2001 | ||
2 | From: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com> | ||
3 | Date: Mon, 12 Oct 2015 12:28:06 +0200 | ||
4 | Subject: [PATCH] =?UTF-8?q?Add=20initial=20cross=20compile=20support=20(re?= | ||
5 | =?UTF-8?q?base=20from=20Petter=20Mab=C3=A4cker=20<petter@technux.se>=20ve?= | ||
6 | =?UTF-8?q?rsion)?= | ||
7 | MIME-Version: 1.0 | ||
8 | Content-Type: text/plain; charset=UTF-8 | ||
9 | Content-Transfer-Encoding: 8bit | ||
10 | |||
11 | --- | ||
12 | .../0001-Add-initial-cross-compile-support.patch | 355 ++++++++++----------- | ||
13 | recipes-devtools/wiringPi/wiringpi_git.bb | 3 +- | ||
14 | 2 files changed, 170 insertions(+), 188 deletions(-) | ||
15 | |||
16 | diff --git a/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch b/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch | ||
17 | index c5ba270..ed47fab 100644 | ||
18 | --- a/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch | ||
19 | +++ b/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch | ||
20 | @@ -1,37 +1,26 @@ | ||
21 | -From b0d82bc7cc90db41aa4f7012bbe3009f0b8ab11d Mon Sep 17 00:00:00 2001 | ||
22 | -From: =?UTF-8?q?Petter=20Mab=C3=A4cker?= <petter@technux.se> | ||
23 | -Date: Sat, 18 Jul 2015 23:20:05 +0200 | ||
24 | -Subject: [PATCH] Add initial cross compile support | ||
25 | -MIME-Version: 1.0 | ||
26 | -Content-Type: text/plain; charset=UTF-8 | ||
27 | -Content-Transfer-Encoding: 8bit | ||
28 | +From 6d85e6cc3ab97c3f060e5e0a8e3f1945a14c86ba Mon Sep 17 00:00:00 2001 | ||
29 | +From: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com> | ||
30 | +Date: Mon, 12 Oct 2015 12:15:51 +0200 | ||
31 | +Subject: [PATCH] Add initial cross compile support (rebase from Petter Mabäcker <petter@technux.se> version) | ||
32 | |||
33 | -Upstream-Status: Pending | ||
34 | - | ||
35 | -Signed-off-by: Petter Mabäcker <petter@technux.se> | ||
36 | --- | ||
37 | - devLib/Makefile | 58 +++++++++++++++++++++++++-------------------- | ||
38 | - examples/Gertboard/Makefile | 22 ++++++++++------- | ||
39 | - examples/Makefile | 19 +++++++++------ | ||
40 | - examples/PiFace/Makefile | 22 ++++++++++------- | ||
41 | - examples/PiGlow/Makefile | 4 ++-- | ||
42 | - examples/q2w/Makefile | 5 ++-- | ||
43 | - gpio/Makefile | 31 +++++++++++++----------- | ||
44 | - wiringPi/Makefile | 56 ++++++++++++++++++++++++------------------- | ||
45 | - 8 files changed, 124 insertions(+), 93 deletions(-) | ||
46 | + devLib/Makefile | 54 ++++++++++++++++++++++++------------------- | ||
47 | + examples/Gertboard/Makefile | 22 +++++++++++------- | ||
48 | + examples/Makefile | 22 +++++++++++------- | ||
49 | + examples/PiFace/Makefile | 22 +++++++++++------- | ||
50 | + examples/PiGlow/Makefile | 4 ++-- | ||
51 | + examples/q2w/Makefile | 4 ++-- | ||
52 | + gpio/Makefile | 29 ++++++++++++----------- | ||
53 | + wiringPi/Makefile | 50 +++++++++++++++++++++------------------ | ||
54 | + 8 files changed, 119 insertions(+), 88 deletions(-) | ||
55 | |||
56 | diff --git a/devLib/Makefile b/devLib/Makefile | ||
57 | -index d62b532..c7c7884 100644 | ||
58 | +index 0fb0033..cbea759 100644 | ||
59 | --- a/devLib/Makefile | ||
60 | +++ b/devLib/Makefile | ||
61 | -@@ -22,18 +22,22 @@ | ||
62 | - ################################################################################# | ||
63 | - | ||
64 | - VERSION=$(shell cat ../VERSION) | ||
65 | --DESTDIR=/usr | ||
66 | --PREFIX=/local | ||
67 | -+DESTDIR?=/usr | ||
68 | -+PREFIX?=/local | ||
69 | +@@ -31,15 +31,19 @@ ifneq ($V,1) | ||
70 | + Q ?= @ | ||
71 | + endif | ||
72 | |||
73 | -STATIC=libwiringPiDev.a | ||
74 | -DYNAMIC=libwiringPiDev.so.$(VERSION) | ||
75 | @@ -48,7 +37,7 @@ index d62b532..c7c7884 100644 | ||
76 | +STATIC=$(BASE_NAME).a | ||
77 | +DYNAMIC=$(BASE_NAME).so.$(VERSION) | ||
78 | + | ||
79 | -+#DEBUG ?= -g -O0 | ||
80 | ++#DEBUG ?= -g -O0 | ||
81 | +DEBUG ?= -O2 | ||
82 | +CC ?= gcc | ||
83 | +INCLUDE ?= -I. | ||
84 | @@ -57,81 +46,81 @@ index d62b532..c7c7884 100644 | ||
85 | |||
86 | LIBS = | ||
87 | |||
88 | -@@ -60,16 +64,16 @@ $(STATIC): $(OBJ) | ||
89 | +@@ -66,16 +70,16 @@ $(STATIC): $(OBJ) | ||
90 | |||
91 | $(DYNAMIC): $(OBJ) | ||
92 | - @echo "[Link (Dynamic)]" | ||
93 | -- @$(CC) -shared -Wl,-soname,libwiringPiDev.so -o libwiringPiDev.so.$(VERSION) -lpthread $(OBJ) | ||
94 | -+ @$(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) | ||
95 | + $Q echo "[Link (Dynamic)]" | ||
96 | +- $Q $(CC) -shared -Wl,-soname,libwiringPiDev.so$(WIRINGPI_SONAME_SUFFIX) -o libwiringPiDev.so.$(VERSION) -lpthread $(OBJ) | ||
97 | ++ $Q $(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) | ||
98 | |||
99 | .c.o: | ||
100 | - @echo [Compile] $< | ||
101 | -- @$(CC) -c $(CFLAGS) $< -o $@ | ||
102 | -+ @$(CC) -c $(CFLAGS) -fPIC $< -o $@ | ||
103 | + $Q echo [Compile] $< | ||
104 | +- $Q $(CC) -c $(CFLAGS) $< -o $@ | ||
105 | ++ $Q $(CC) -c $(CFLAGS) -fPIC $< -o $@ | ||
106 | |||
107 | .PHONY: clean | ||
108 | clean: | ||
109 | - @echo "[Clean]" | ||
110 | -- @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPiDev.* | ||
111 | -+ @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a | ||
112 | + $Q echo "[Clean]" | ||
113 | +- $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPiDev.* | ||
114 | ++ $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a | ||
115 | |||
116 | .PHONY: tags | ||
117 | tags: $(SRC) | ||
118 | -@@ -80,22 +84,22 @@ tags: $(SRC) | ||
119 | +@@ -86,22 +90,22 @@ tags: $(SRC) | ||
120 | .PHONY: install | ||
121 | install: $(DYNAMIC) | ||
122 | - @echo "[Install Headers]" | ||
123 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
124 | -- @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
125 | -+ @install -m 0755 -d $(INCLUDE_DIR) | ||
126 | -+ @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
127 | - @echo "[Install Dynamic Lib]" | ||
128 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
129 | -- @install -m 0755 libwiringPiDev.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) | ||
130 | -- @ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) $(DESTDIR)/lib/libwiringPiDev.so | ||
131 | -- @ldconfig | ||
132 | -+ @install -m 0755 -d $(LIB_DIR) | ||
133 | -+ @install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) | ||
134 | -+ @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so | ||
135 | -+ @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
136 | + $Q echo "[Install Headers]" | ||
137 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
138 | +- $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
139 | ++ $Q install -m 0755 -d $(INCLUDE_DIR) | ||
140 | ++ $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
141 | + $Q echo "[Install Dynamic Lib]" | ||
142 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
143 | +- $Q install -m 0755 libwiringPiDev.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) | ||
144 | +- $Q ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) $(DESTDIR)/lib/libwiringPiDev.so | ||
145 | +- $Q $(LDCONFIG) | ||
146 | ++ $Q install -m 0755 -d $(LIB_DIR) | ||
147 | ++ $Q install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) | ||
148 | ++ $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so | ||
149 | ++ $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
150 | |||
151 | .PHONY: install-static | ||
152 | install-static: $(STATIC) | ||
153 | - @echo "[Install Headers]" | ||
154 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
155 | -- @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
156 | -+ @install -m 0755 -d $(INCLUDE_DIR) | ||
157 | -+ @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
158 | - @echo "[Install Static Lib]" | ||
159 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
160 | -- @install -m 0755 libwiringPiDev.a $(DESTDIR)$(PREFIX)/lib | ||
161 | -+ @install -m 0755 -d $(LIB_DIR) | ||
162 | -+ @install -m 0644 $(STATIC) $(LIB_DIR) | ||
163 | + $Q echo "[Install Headers]" | ||
164 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
165 | +- $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
166 | ++ $Q install -m 0755 -d $(INCLUDE_DIR) | ||
167 | ++ $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
168 | + $Q echo "[Install Static Lib]" | ||
169 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
170 | +- $Q install -m 0755 libwiringPiDev.a $(DESTDIR)$(PREFIX)/lib | ||
171 | ++ $Q install -m 0755 -d $(LIB_DIR) | ||
172 | ++ $Q install -m 0755 $(STATIC) $(LIB_DIR) | ||
173 | |||
174 | .PHONY: install-deb | ||
175 | install-deb: $(DYNAMIC) | ||
176 | -@@ -110,9 +114,11 @@ install-deb: $(DYNAMIC) | ||
177 | +@@ -116,9 +120,11 @@ install-deb: $(DYNAMIC) | ||
178 | .PHONY: uninstall | ||
179 | uninstall: | ||
180 | - @echo "[UnInstall]" | ||
181 | -- @cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) | ||
182 | -- @cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPiDev.* | ||
183 | -- @ldconfig | ||
184 | -+ @cd $(INCLUDE_DIR) && rm -f $(HEADERS) | ||
185 | -+ @rm -f $(LIB_DIR)/$(STATIC) | ||
186 | -+ @rm -f $(LIB_DIR)/$(DYNAMIC) | ||
187 | -+ @rm -f $(LIB_DIR)/$(BASE_NAME).so | ||
188 | -+ @rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
189 | + $Q echo "[UnInstall]" | ||
190 | +- $Q cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) | ||
191 | +- $Q cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPiDev.* | ||
192 | +- $Q $(LDCONFIG) | ||
193 | ++ $Q cd $(INCLUDE_DIR) && rm -f $(HEADERS) | ||
194 | ++ $Q rm -f $(LIB_DIR)/$(STATIC) | ||
195 | ++ $Q rm -f $(LIB_DIR)/$(DYNAMIC) | ||
196 | ++ $Q rm -f $(LIB_DIR)/$(BASE_NAME).so | ||
197 | ++ $Q rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
198 | |||
199 | |||
200 | .PHONY: depend | ||
201 | diff --git a/examples/Gertboard/Makefile b/examples/Gertboard/Makefile | ||
202 | -index 7569261..b0c32e0 100644 | ||
203 | +index 1939ad6..98d1415 100644 | ||
204 | --- a/examples/Gertboard/Makefile | ||
205 | +++ b/examples/Gertboard/Makefile | ||
206 | -@@ -5,14 +5,20 @@ | ||
207 | - # Copyright (c) 2013 Gordon Henderson | ||
208 | - ################################################################################# | ||
209 | +@@ -9,14 +9,20 @@ ifneq ($V,1) | ||
210 | + Q ?= @ | ||
211 | + endif | ||
212 | |||
213 | -#DEBUG = -g -O0 | ||
214 | -DEBUG = -O3 | ||
215 | @@ -159,26 +148,27 @@ index 7569261..b0c32e0 100644 | ||
216 | # Should not alter anything below this line | ||
217 | ############################################################################### | ||
218 | diff --git a/examples/Makefile b/examples/Makefile | ||
219 | -index c9967dc..c2f8b9d 100644 | ||
220 | +index e6b9b71..931b167 100644 | ||
221 | --- a/examples/Makefile | ||
222 | +++ b/examples/Makefile | ||
223 | -@@ -22,15 +22,20 @@ | ||
224 | - # along with wiringPi. If not, see <http://www.gnu.org/licenses/>. | ||
225 | - ################################################################################# | ||
226 | - | ||
227 | -+DESTDIR?=/usr | ||
228 | -+PREFIX?=/local | ||
229 | +@@ -26,14 +26,20 @@ ifneq ($V,1) | ||
230 | + Q ?= @ | ||
231 | + endif | ||
232 | |||
233 | -#DEBUG = -g -O0 | ||
234 | -DEBUG = -O3 | ||
235 | -CC = gcc | ||
236 | -INCLUDE = -I/usr/local/include | ||
237 | -CFLAGS = $(DEBUG) -Wall $(INCLUDE) -Winline -pipe | ||
238 | -+INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include | ||
239 | -+LIB_DIR?=$(DESTDIR)$(PREFIX)/lib | ||
240 | - | ||
241 | +- | ||
242 | -LDFLAGS = -L/usr/local/lib | ||
243 | -LDLIBS = -lwiringPi -lwiringPiDev -lpthread -lm | ||
244 | ++DESTDIR?=/usr | ||
245 | ++PREFIX?=/local | ||
246 | ++ | ||
247 | ++INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include | ||
248 | ++LIB_DIR?=$(DESTDIR)$(PREFIX)/lib | ||
249 | ++ | ||
250 | +#DEBUG ?= -g -O0 | ||
251 | +DEBUG ?= -O3 | ||
252 | +CC ?= gcc | ||
253 | @@ -191,12 +181,12 @@ index c9967dc..c2f8b9d 100644 | ||
254 | # Should not alter anything below this line | ||
255 | ############################################################################### | ||
256 | diff --git a/examples/PiFace/Makefile b/examples/PiFace/Makefile | ||
257 | -index 0bde334..fc14c0c 100644 | ||
258 | +index 4685adc..cfaf902 100644 | ||
259 | --- a/examples/PiFace/Makefile | ||
260 | +++ b/examples/PiFace/Makefile | ||
261 | -@@ -23,14 +23,20 @@ | ||
262 | - ################################################################################# | ||
263 | - | ||
264 | +@@ -26,14 +26,20 @@ ifneq ($V,1) | ||
265 | + Q ?= @ | ||
266 | + endif | ||
267 | |||
268 | -#DEBUG = -g -O0 | ||
269 | -DEBUG = -O3 | ||
270 | @@ -224,10 +214,10 @@ index 0bde334..fc14c0c 100644 | ||
271 | # Should not alter anything below this line | ||
272 | ############################################################################### | ||
273 | diff --git a/examples/PiGlow/Makefile b/examples/PiGlow/Makefile | ||
274 | -index 8d31141..482c9e7 100644 | ||
275 | +index acd4818..dabd64e 100644 | ||
276 | --- a/examples/PiGlow/Makefile | ||
277 | +++ b/examples/PiGlow/Makefile | ||
278 | -@@ -26,10 +26,10 @@ | ||
279 | +@@ -29,10 +29,10 @@ endif | ||
280 | #DEBUG = -g -O0 | ||
281 | DEBUG = -O3 | ||
282 | CC = gcc | ||
283 | @@ -241,14 +231,10 @@ index 8d31141..482c9e7 100644 | ||
284 | |||
285 | # Should not alter anything below this line | ||
286 | diff --git a/examples/q2w/Makefile b/examples/q2w/Makefile | ||
287 | -index 150c825..0544aa3 100644 | ||
288 | +index 6f50fa0..c5e9f6e 100644 | ||
289 | --- a/examples/q2w/Makefile | ||
290 | +++ b/examples/q2w/Makefile | ||
291 | -@@ -22,14 +22,13 @@ | ||
292 | - # along with wiringPi. If not, see <http://www.gnu.org/licenses/>. | ||
293 | - ################################################################################# | ||
294 | - | ||
295 | -- | ||
296 | +@@ -29,10 +29,10 @@ endif | ||
297 | #DEBUG = -g -O0 | ||
298 | DEBUG = -O3 | ||
299 | CC = gcc | ||
300 | @@ -262,17 +248,12 @@ index 150c825..0544aa3 100644 | ||
301 | |||
302 | ############################################################################### | ||
303 | diff --git a/gpio/Makefile b/gpio/Makefile | ||
304 | -index 449986e..95af1ad 100644 | ||
305 | +index 7dcd090..83ec454 100644 | ||
306 | --- a/gpio/Makefile | ||
307 | +++ b/gpio/Makefile | ||
308 | -@@ -23,16 +23,20 @@ | ||
309 | - # along with wiringPi. If not, see <http://www.gnu.org/licenses/>. | ||
310 | - ################################################################################# | ||
311 | - | ||
312 | --DESTDIR=/usr | ||
313 | --PREFIX=/local | ||
314 | -+DESTDIR?=/usr | ||
315 | -+PREFIX?=/local | ||
316 | +@@ -30,13 +30,17 @@ ifneq ($V,1) | ||
317 | + Q ?= @ | ||
318 | + endif | ||
319 | |||
320 | -#DEBUG = -g -O0 | ||
321 | -DEBUG = -O2 | ||
322 | @@ -290,49 +271,53 @@ index 449986e..95af1ad 100644 | ||
323 | +INCLUDE ?= -I$(INCLUDE_DIR) | ||
324 | +CFLAGS ?= $(DEBUG) -Wall $(INCLUDE) -Winline -pipe | ||
325 | + | ||
326 | -+LDFLAGS = -L$(LIB_DIR) | ||
327 | - LIBS = -lwiringPi -lwiringPiDev -lpthread -lm | ||
328 | ++LDFLAGS ?= -L$(LIB_DIR) | ||
329 | + LIBS = -lwiringPi -lwiringPiDev -lpthread | ||
330 | |||
331 | # May not need to alter anything below this line | ||
332 | -@@ -68,11 +72,10 @@ tags: $(SRC) | ||
333 | +@@ -72,13 +76,10 @@ tags: $(SRC) | ||
334 | .PHONY: install | ||
335 | install: gpio | ||
336 | - @echo "[Install]" | ||
337 | -- @cp gpio $(DESTDIR)$(PREFIX)/bin | ||
338 | -- @chown root.root $(DESTDIR)$(PREFIX)/bin/gpio | ||
339 | -- @chmod 4755 $(DESTDIR)$(PREFIX)/bin/gpio | ||
340 | -- @mkdir -p $(DESTDIR)$(PREFIX)/man/man1 | ||
341 | -- @cp gpio.1 $(DESTDIR)$(PREFIX)/man/man1 | ||
342 | -+ @install -d $(BIN_DIR) | ||
343 | -+ @install -m 4755 -o root -g root gpio $(BIN_DIR) | ||
344 | -+ @install -d $(DESTDIR)$(PREFIX)/share/man/man1 | ||
345 | -+ @install -m 644 -o root -g root gpio.1 $(DESTDIR)$(PREFIX)/share/man/man1 | ||
346 | + $Q echo "[Install]" | ||
347 | +- $Q cp gpio $(DESTDIR)$(PREFIX)/bin | ||
348 | +-ifneq ($(WIRINGPI_SUID),0) | ||
349 | +- $Q chown root.root $(DESTDIR)$(PREFIX)/bin/gpio | ||
350 | +- $Q chmod 4755 $(DESTDIR)$(PREFIX)/bin/gpio | ||
351 | +-endif | ||
352 | +- $Q mkdir -p $(DESTDIR)$(PREFIX)/man/man1 | ||
353 | +- $Q cp gpio.1 $(DESTDIR)$(PREFIX)/man/man1 | ||
354 | ++ $Q install -d $(BIN_DIR) | ||
355 | ++ $Q install -m 4755 -o root -g root gpio $(BIN_DIR) | ||
356 | ++ $Q install -d $(DESTDIR)$(PREFIX)/share/man/man1 | ||
357 | ++ $Q install -m 644 -o root -g root gpio.1 $(DESTDIR)$(PREFIX)/share/man/man1 | ||
358 | |||
359 | .PHONY: install-deb | ||
360 | install-deb: gpio | ||
361 | -@@ -83,7 +86,7 @@ install-deb: gpio | ||
362 | +@@ -89,7 +90,7 @@ install-deb: gpio | ||
363 | .PHONY: uninstall | ||
364 | uninstall: | ||
365 | - @echo "[UnInstall]" | ||
366 | -- @rm -f $(DESTDIR)$(PREFIX)/bin/gpio | ||
367 | -+ @rm -f $(BIN_DIR)/gpio | ||
368 | - @rm -f $(DESTDIR)$(PREFIX)/man/man1/gpio.1 | ||
369 | + $Q echo "[UnInstall]" | ||
370 | +- $Q rm -f $(DESTDIR)$(PREFIX)/bin/gpio | ||
371 | ++ $Q rm -f $(BIN_DIR)/gpio | ||
372 | + $Q rm -f $(DESTDIR)$(PREFIX)/man/man1/gpio.1 | ||
373 | |||
374 | .PHONY: depend | ||
375 | diff --git a/wiringPi/Makefile b/wiringPi/Makefile | ||
376 | -index 015a894..5fc0659 100644 | ||
377 | +index 6bbcc5d..5355b74 100644 | ||
378 | --- a/wiringPi/Makefile | ||
379 | +++ b/wiringPi/Makefile | ||
380 | -@@ -22,18 +22,22 @@ | ||
381 | - ################################################################################# | ||
382 | +@@ -25,19 +25,23 @@ VERSION=$(shell cat ../VERSION) | ||
383 | + DESTDIR?=/usr | ||
384 | + PREFIX?=/local | ||
385 | |||
386 | - VERSION=$(shell cat ../VERSION) | ||
387 | --DESTDIR=/usr | ||
388 | --PREFIX=/local | ||
389 | -+DESTDIR?=/usr | ||
390 | -+PREFIX?=/local | ||
391 | +INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include | ||
392 | +LIB_DIR?=$(DESTDIR)$(PREFIX)/lib | ||
393 | ++ | ||
394 | + LDCONFIG?=ldconfig | ||
395 | + | ||
396 | + ifneq ($V,1) | ||
397 | + Q ?= @ | ||
398 | + endif | ||
399 | |||
400 | -STATIC=libwiringPi.a | ||
401 | -DYNAMIC=libwiringPi.so.$(VERSION) | ||
402 | @@ -344,86 +329,82 @@ index 015a894..5fc0659 100644 | ||
403 | -DEBUG = -O2 | ||
404 | -CC = gcc | ||
405 | -INCLUDE = -I. | ||
406 | --DEFS = -D_GNU_SOURCE | ||
407 | +#DEBUG ?= -g -O0 | ||
408 | - CFLAGS = $(DEBUG) $(DEFS) -Wformat=2 -Wall -Winline $(INCLUDE) -pipe -fPIC | ||
409 | +DEBUG ?= -O2 | ||
410 | +CC ?= gcc | ||
411 | -+DEFS = -D_GNU_SOURCE | ||
412 | +INCLUDE ?= -I. | ||
413 | -+CFLAGS ?= $(DEBUG) $(DEFS) -Wformat=2 -Wall -Winline $(INCLUDE) -pipe -fPIC | ||
414 | - | ||
415 | - LIBS = | ||
416 | + DEFS = -D_GNU_SOURCE | ||
417 | + CFLAGS = $(DEBUG) $(DEFS) -Wformat=2 -Wall -Winline $(INCLUDE) -pipe -fPIC | ||
418 | |||
419 | -@@ -83,17 +87,17 @@ $(STATIC): $(OBJ) | ||
420 | +@@ -89,17 +93,17 @@ $(STATIC): $(OBJ) | ||
421 | |||
422 | $(DYNAMIC): $(OBJ) | ||
423 | - @echo "[Link (Dynamic)]" | ||
424 | -- @$(CC) -shared -Wl,-soname,libwiringPi.so -o libwiringPi.so.$(VERSION) -lpthread $(OBJ) | ||
425 | -+ @$(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) | ||
426 | + $Q echo "[Link (Dynamic)]" | ||
427 | +- $Q $(CC) -shared -Wl,-soname,libwiringPi.so$(WIRINGPI_SONAME_SUFFIX) -o libwiringPi.so.$(VERSION) -lpthread $(OBJ) | ||
428 | ++ $Q $(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) | ||
429 | |||
430 | .c.o: | ||
431 | - @echo [Compile] $< | ||
432 | -- @$(CC) -c $(CFLAGS) $< -o $@ | ||
433 | -+ @$(CC) -c $(CFLAGS) -fPIC $< -o $@ | ||
434 | + $Q echo [Compile] $< | ||
435 | +- $Q $(CC) -c $(CFLAGS) $< -o $@ | ||
436 | ++ $Q $(CC) -c $(CFLAGS) -fPIC $< -o $@ | ||
437 | |||
438 | |||
439 | .PHONY: clean | ||
440 | clean: | ||
441 | - @echo "[Clean]" | ||
442 | -- @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPi.* | ||
443 | -+ @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a | ||
444 | + $Q echo "[Clean]" | ||
445 | +- $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPi.* | ||
446 | ++ $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a | ||
447 | |||
448 | .PHONY: tags | ||
449 | tags: $(SRC) | ||
450 | -@@ -104,22 +108,22 @@ tags: $(SRC) | ||
451 | +@@ -110,22 +114,22 @@ tags: $(SRC) | ||
452 | .PHONY: install | ||
453 | install: $(DYNAMIC) | ||
454 | - @echo "[Install Headers]" | ||
455 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
456 | -- @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
457 | -+ @install -m 0755 -d $(INCLUDE_DIR) | ||
458 | -+ @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
459 | - @echo "[Install Dynamic Lib]" | ||
460 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
461 | -- @install -m 0755 libwiringPi.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) | ||
462 | -- @ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) $(DESTDIR)/lib/libwiringPi.so | ||
463 | -- @ldconfig | ||
464 | -+ @install -m 0755 -d $(LIB_DIR) | ||
465 | -+ @install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) | ||
466 | -+ @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so | ||
467 | -+ @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
468 | + $Q echo "[Install Headers]" | ||
469 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
470 | +- $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
471 | ++ $Q install -m 0755 -d $(INCLUDE_DIR) | ||
472 | ++ $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
473 | + $Q echo "[Install Dynamic Lib]" | ||
474 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
475 | +- $Q install -m 0755 libwiringPi.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) | ||
476 | +- $Q ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) $(DESTDIR)/lib/libwiringPi.so | ||
477 | +- $Q $(LDCONFIG) | ||
478 | ++ $Q install -m 0755 -d $(LIB_DIR) | ||
479 | ++ $Q install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) | ||
480 | ++ $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so | ||
481 | ++ $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
482 | |||
483 | .PHONY: install-static | ||
484 | install-static: $(STATIC) | ||
485 | - @echo "[Install Headers]" | ||
486 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
487 | -- @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
488 | -+ @install -m 0755 -d $(INCLUDE_DIR) | ||
489 | -+ @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
490 | - @echo "[Install Static Lib]" | ||
491 | -- @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
492 | -- @install -m 0755 libwiringPi.a $(DESTDIR)$(PREFIX)/lib | ||
493 | -+ @install -m 0755 -d $(LIB_DIR) | ||
494 | -+ @install -m 0644 $(STATIC) $(LIB_DIR) | ||
495 | + $Q echo "[Install Headers]" | ||
496 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include | ||
497 | +- $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | ||
498 | ++ $Q install -m 0755 -d $(INCLUDE_DIR) | ||
499 | ++ $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) | ||
500 | + $Q echo "[Install Static Lib]" | ||
501 | +- $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | ||
502 | +- $Q install -m 0755 libwiringPi.a $(DESTDIR)$(PREFIX)/lib | ||
503 | ++ $Q install -m 0755 -d $(LIB_DIR) | ||
504 | ++ $Q install -m 0755 $(STATIC) $(LIB_DIR) | ||
505 | |||
506 | .PHONY: install-deb | ||
507 | install-deb: $(DYNAMIC) | ||
508 | -@@ -134,9 +138,11 @@ install-deb: $(DYNAMIC) | ||
509 | +@@ -140,9 +144,11 @@ install-deb: $(DYNAMIC) | ||
510 | .PHONY: uninstall | ||
511 | uninstall: | ||
512 | - @echo "[UnInstall]" | ||
513 | -- @cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) | ||
514 | -- @cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPi.* | ||
515 | -- @ldconfig | ||
516 | -+ @cd $(INCLUDE_DIR) && rm -f $(HEADERS) | ||
517 | -+ @rm -f $(LIB_DIR)/$(STATIC) | ||
518 | -+ @rm -f $(LIB_DIR)/$(DYNAMIC) | ||
519 | -+ @rm -f $(LIB_DIR)/$(BASE_NAME).so | ||
520 | -+ @rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
521 | + $Q echo "[UnInstall]" | ||
522 | +- $Q cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) | ||
523 | +- $Q cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPi.* | ||
524 | +- $Q $(LDCONFIG) | ||
525 | ++ $Q cd $(INCLUDE_DIR) && rm -f $(HEADERS) | ||
526 | ++ $Q rm -f $(LIB_DIR)/$(STATIC) | ||
527 | ++ $Q rm -f $(LIB_DIR)/$(DYNAMIC) | ||
528 | ++ $Q rm -f $(LIB_DIR)/$(BASE_NAME).so | ||
529 | ++ $Q rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | ||
530 | |||
531 | |||
532 | .PHONY: depend | ||
533 | -- | ||
534 | -1.9.1 | ||
535 | +2.1.4 | ||
536 | |||
537 | diff --git a/recipes-devtools/wiringPi/wiringpi_git.bb b/recipes-devtools/wiringPi/wiringpi_git.bb | ||
538 | index 21b5294..4254a0a 100644 | ||
539 | --- a/recipes-devtools/wiringPi/wiringpi_git.bb | ||
540 | +++ b/recipes-devtools/wiringPi/wiringpi_git.bb | ||
541 | @@ -4,7 +4,8 @@ SECTION = "devel/libs" | ||
542 | LICENSE = "LGPLv3+" | ||
543 | LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=e6a600fd5e1d9cbde2d983680233ad02" | ||
544 | |||
545 | -SRCREV = "5edd177112c99416f68ba3e8c6c4db6ed942e796" | ||
546 | +# tag 2.29 | ||
547 | +SRCREV = "d79506694d7ba1c3da865d095238289d6175057d" | ||
548 | |||
549 | S = "${WORKDIR}/git" | ||
550 | \ No newline at end of file | ||
diff --git a/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch b/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch index c5ba270..ed47fab 100644 --- a/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch +++ b/recipes-devtools/wiringPi/files/0001-Add-initial-cross-compile-support.patch | |||
@@ -1,37 +1,26 @@ | |||
1 | From b0d82bc7cc90db41aa4f7012bbe3009f0b8ab11d Mon Sep 17 00:00:00 2001 | 1 | From 6d85e6cc3ab97c3f060e5e0a8e3f1945a14c86ba Mon Sep 17 00:00:00 2001 |
2 | From: =?UTF-8?q?Petter=20Mab=C3=A4cker?= <petter@technux.se> | 2 | From: Gianfranco Costamagna <gianfranco.costamagna@abinsula.com> |
3 | Date: Sat, 18 Jul 2015 23:20:05 +0200 | 3 | Date: Mon, 12 Oct 2015 12:15:51 +0200 |
4 | Subject: [PATCH] Add initial cross compile support | 4 | Subject: [PATCH] Add initial cross compile support (rebase from Petter Mabäcker <petter@technux.se> version) |
5 | MIME-Version: 1.0 | ||
6 | Content-Type: text/plain; charset=UTF-8 | ||
7 | Content-Transfer-Encoding: 8bit | ||
8 | 5 | ||
9 | Upstream-Status: Pending | ||
10 | |||
11 | Signed-off-by: Petter Mabäcker <petter@technux.se> | ||
12 | --- | 6 | --- |
13 | devLib/Makefile | 58 +++++++++++++++++++++++++-------------------- | 7 | devLib/Makefile | 54 ++++++++++++++++++++++++------------------- |
14 | examples/Gertboard/Makefile | 22 ++++++++++------- | 8 | examples/Gertboard/Makefile | 22 +++++++++++------- |
15 | examples/Makefile | 19 +++++++++------ | 9 | examples/Makefile | 22 +++++++++++------- |
16 | examples/PiFace/Makefile | 22 ++++++++++------- | 10 | examples/PiFace/Makefile | 22 +++++++++++------- |
17 | examples/PiGlow/Makefile | 4 ++-- | 11 | examples/PiGlow/Makefile | 4 ++-- |
18 | examples/q2w/Makefile | 5 ++-- | 12 | examples/q2w/Makefile | 4 ++-- |
19 | gpio/Makefile | 31 +++++++++++++----------- | 13 | gpio/Makefile | 29 ++++++++++++----------- |
20 | wiringPi/Makefile | 56 ++++++++++++++++++++++++------------------- | 14 | wiringPi/Makefile | 50 +++++++++++++++++++++------------------ |
21 | 8 files changed, 124 insertions(+), 93 deletions(-) | 15 | 8 files changed, 119 insertions(+), 88 deletions(-) |
22 | 16 | ||
23 | diff --git a/devLib/Makefile b/devLib/Makefile | 17 | diff --git a/devLib/Makefile b/devLib/Makefile |
24 | index d62b532..c7c7884 100644 | 18 | index 0fb0033..cbea759 100644 |
25 | --- a/devLib/Makefile | 19 | --- a/devLib/Makefile |
26 | +++ b/devLib/Makefile | 20 | +++ b/devLib/Makefile |
27 | @@ -22,18 +22,22 @@ | 21 | @@ -31,15 +31,19 @@ ifneq ($V,1) |
28 | ################################################################################# | 22 | Q ?= @ |
29 | 23 | endif | |
30 | VERSION=$(shell cat ../VERSION) | ||
31 | -DESTDIR=/usr | ||
32 | -PREFIX=/local | ||
33 | +DESTDIR?=/usr | ||
34 | +PREFIX?=/local | ||
35 | 24 | ||
36 | -STATIC=libwiringPiDev.a | 25 | -STATIC=libwiringPiDev.a |
37 | -DYNAMIC=libwiringPiDev.so.$(VERSION) | 26 | -DYNAMIC=libwiringPiDev.so.$(VERSION) |
@@ -48,7 +37,7 @@ index d62b532..c7c7884 100644 | |||
48 | +STATIC=$(BASE_NAME).a | 37 | +STATIC=$(BASE_NAME).a |
49 | +DYNAMIC=$(BASE_NAME).so.$(VERSION) | 38 | +DYNAMIC=$(BASE_NAME).so.$(VERSION) |
50 | + | 39 | + |
51 | +#DEBUG ?= -g -O0 | 40 | +#DEBUG ?= -g -O0 |
52 | +DEBUG ?= -O2 | 41 | +DEBUG ?= -O2 |
53 | +CC ?= gcc | 42 | +CC ?= gcc |
54 | +INCLUDE ?= -I. | 43 | +INCLUDE ?= -I. |
@@ -57,81 +46,81 @@ index d62b532..c7c7884 100644 | |||
57 | 46 | ||
58 | LIBS = | 47 | LIBS = |
59 | 48 | ||
60 | @@ -60,16 +64,16 @@ $(STATIC): $(OBJ) | 49 | @@ -66,16 +70,16 @@ $(STATIC): $(OBJ) |
61 | 50 | ||
62 | $(DYNAMIC): $(OBJ) | 51 | $(DYNAMIC): $(OBJ) |
63 | @echo "[Link (Dynamic)]" | 52 | $Q echo "[Link (Dynamic)]" |
64 | - @$(CC) -shared -Wl,-soname,libwiringPiDev.so -o libwiringPiDev.so.$(VERSION) -lpthread $(OBJ) | 53 | - $Q $(CC) -shared -Wl,-soname,libwiringPiDev.so$(WIRINGPI_SONAME_SUFFIX) -o libwiringPiDev.so.$(VERSION) -lpthread $(OBJ) |
65 | + @$(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) | 54 | + $Q $(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) |
66 | 55 | ||
67 | .c.o: | 56 | .c.o: |
68 | @echo [Compile] $< | 57 | $Q echo [Compile] $< |
69 | - @$(CC) -c $(CFLAGS) $< -o $@ | 58 | - $Q $(CC) -c $(CFLAGS) $< -o $@ |
70 | + @$(CC) -c $(CFLAGS) -fPIC $< -o $@ | 59 | + $Q $(CC) -c $(CFLAGS) -fPIC $< -o $@ |
71 | 60 | ||
72 | .PHONY: clean | 61 | .PHONY: clean |
73 | clean: | 62 | clean: |
74 | @echo "[Clean]" | 63 | $Q echo "[Clean]" |
75 | - @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPiDev.* | 64 | - $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPiDev.* |
76 | + @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a | 65 | + $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a |
77 | 66 | ||
78 | .PHONY: tags | 67 | .PHONY: tags |
79 | tags: $(SRC) | 68 | tags: $(SRC) |
80 | @@ -80,22 +84,22 @@ tags: $(SRC) | 69 | @@ -86,22 +90,22 @@ tags: $(SRC) |
81 | .PHONY: install | 70 | .PHONY: install |
82 | install: $(DYNAMIC) | 71 | install: $(DYNAMIC) |
83 | @echo "[Install Headers]" | 72 | $Q echo "[Install Headers]" |
84 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | 73 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include |
85 | - @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | 74 | - $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include |
86 | + @install -m 0755 -d $(INCLUDE_DIR) | 75 | + $Q install -m 0755 -d $(INCLUDE_DIR) |
87 | + @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | 76 | + $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) |
88 | @echo "[Install Dynamic Lib]" | 77 | $Q echo "[Install Dynamic Lib]" |
89 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | 78 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib |
90 | - @install -m 0755 libwiringPiDev.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) | 79 | - $Q install -m 0755 libwiringPiDev.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) |
91 | - @ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) $(DESTDIR)/lib/libwiringPiDev.so | 80 | - $Q ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPiDev.so.$(VERSION) $(DESTDIR)/lib/libwiringPiDev.so |
92 | - @ldconfig | 81 | - $Q $(LDCONFIG) |
93 | + @install -m 0755 -d $(LIB_DIR) | 82 | + $Q install -m 0755 -d $(LIB_DIR) |
94 | + @install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) | 83 | + $Q install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) |
95 | + @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so | 84 | + $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so |
96 | + @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | 85 | + $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) |
97 | 86 | ||
98 | .PHONY: install-static | 87 | .PHONY: install-static |
99 | install-static: $(STATIC) | 88 | install-static: $(STATIC) |
100 | @echo "[Install Headers]" | 89 | $Q echo "[Install Headers]" |
101 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | 90 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include |
102 | - @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | 91 | - $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include |
103 | + @install -m 0755 -d $(INCLUDE_DIR) | 92 | + $Q install -m 0755 -d $(INCLUDE_DIR) |
104 | + @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | 93 | + $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) |
105 | @echo "[Install Static Lib]" | 94 | $Q echo "[Install Static Lib]" |
106 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | 95 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib |
107 | - @install -m 0755 libwiringPiDev.a $(DESTDIR)$(PREFIX)/lib | 96 | - $Q install -m 0755 libwiringPiDev.a $(DESTDIR)$(PREFIX)/lib |
108 | + @install -m 0755 -d $(LIB_DIR) | 97 | + $Q install -m 0755 -d $(LIB_DIR) |
109 | + @install -m 0644 $(STATIC) $(LIB_DIR) | 98 | + $Q install -m 0755 $(STATIC) $(LIB_DIR) |
110 | 99 | ||
111 | .PHONY: install-deb | 100 | .PHONY: install-deb |
112 | install-deb: $(DYNAMIC) | 101 | install-deb: $(DYNAMIC) |
113 | @@ -110,9 +114,11 @@ install-deb: $(DYNAMIC) | 102 | @@ -116,9 +120,11 @@ install-deb: $(DYNAMIC) |
114 | .PHONY: uninstall | 103 | .PHONY: uninstall |
115 | uninstall: | 104 | uninstall: |
116 | @echo "[UnInstall]" | 105 | $Q echo "[UnInstall]" |
117 | - @cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) | 106 | - $Q cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) |
118 | - @cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPiDev.* | 107 | - $Q cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPiDev.* |
119 | - @ldconfig | 108 | - $Q $(LDCONFIG) |
120 | + @cd $(INCLUDE_DIR) && rm -f $(HEADERS) | 109 | + $Q cd $(INCLUDE_DIR) && rm -f $(HEADERS) |
121 | + @rm -f $(LIB_DIR)/$(STATIC) | 110 | + $Q rm -f $(LIB_DIR)/$(STATIC) |
122 | + @rm -f $(LIB_DIR)/$(DYNAMIC) | 111 | + $Q rm -f $(LIB_DIR)/$(DYNAMIC) |
123 | + @rm -f $(LIB_DIR)/$(BASE_NAME).so | 112 | + $Q rm -f $(LIB_DIR)/$(BASE_NAME).so |
124 | + @rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | 113 | + $Q rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) |
125 | 114 | ||
126 | 115 | ||
127 | .PHONY: depend | 116 | .PHONY: depend |
128 | diff --git a/examples/Gertboard/Makefile b/examples/Gertboard/Makefile | 117 | diff --git a/examples/Gertboard/Makefile b/examples/Gertboard/Makefile |
129 | index 7569261..b0c32e0 100644 | 118 | index 1939ad6..98d1415 100644 |
130 | --- a/examples/Gertboard/Makefile | 119 | --- a/examples/Gertboard/Makefile |
131 | +++ b/examples/Gertboard/Makefile | 120 | +++ b/examples/Gertboard/Makefile |
132 | @@ -5,14 +5,20 @@ | 121 | @@ -9,14 +9,20 @@ ifneq ($V,1) |
133 | # Copyright (c) 2013 Gordon Henderson | 122 | Q ?= @ |
134 | ################################################################################# | 123 | endif |
135 | 124 | ||
136 | -#DEBUG = -g -O0 | 125 | -#DEBUG = -g -O0 |
137 | -DEBUG = -O3 | 126 | -DEBUG = -O3 |
@@ -159,26 +148,27 @@ index 7569261..b0c32e0 100644 | |||
159 | # Should not alter anything below this line | 148 | # Should not alter anything below this line |
160 | ############################################################################### | 149 | ############################################################################### |
161 | diff --git a/examples/Makefile b/examples/Makefile | 150 | diff --git a/examples/Makefile b/examples/Makefile |
162 | index c9967dc..c2f8b9d 100644 | 151 | index e6b9b71..931b167 100644 |
163 | --- a/examples/Makefile | 152 | --- a/examples/Makefile |
164 | +++ b/examples/Makefile | 153 | +++ b/examples/Makefile |
165 | @@ -22,15 +22,20 @@ | 154 | @@ -26,14 +26,20 @@ ifneq ($V,1) |
166 | # along with wiringPi. If not, see <http://www.gnu.org/licenses/>. | 155 | Q ?= @ |
167 | ################################################################################# | 156 | endif |
168 | |||
169 | +DESTDIR?=/usr | ||
170 | +PREFIX?=/local | ||
171 | 157 | ||
172 | -#DEBUG = -g -O0 | 158 | -#DEBUG = -g -O0 |
173 | -DEBUG = -O3 | 159 | -DEBUG = -O3 |
174 | -CC = gcc | 160 | -CC = gcc |
175 | -INCLUDE = -I/usr/local/include | 161 | -INCLUDE = -I/usr/local/include |
176 | -CFLAGS = $(DEBUG) -Wall $(INCLUDE) -Winline -pipe | 162 | -CFLAGS = $(DEBUG) -Wall $(INCLUDE) -Winline -pipe |
177 | +INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include | 163 | - |
178 | +LIB_DIR?=$(DESTDIR)$(PREFIX)/lib | ||
179 | |||
180 | -LDFLAGS = -L/usr/local/lib | 164 | -LDFLAGS = -L/usr/local/lib |
181 | -LDLIBS = -lwiringPi -lwiringPiDev -lpthread -lm | 165 | -LDLIBS = -lwiringPi -lwiringPiDev -lpthread -lm |
166 | +DESTDIR?=/usr | ||
167 | +PREFIX?=/local | ||
168 | + | ||
169 | +INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include | ||
170 | +LIB_DIR?=$(DESTDIR)$(PREFIX)/lib | ||
171 | + | ||
182 | +#DEBUG ?= -g -O0 | 172 | +#DEBUG ?= -g -O0 |
183 | +DEBUG ?= -O3 | 173 | +DEBUG ?= -O3 |
184 | +CC ?= gcc | 174 | +CC ?= gcc |
@@ -191,12 +181,12 @@ index c9967dc..c2f8b9d 100644 | |||
191 | # Should not alter anything below this line | 181 | # Should not alter anything below this line |
192 | ############################################################################### | 182 | ############################################################################### |
193 | diff --git a/examples/PiFace/Makefile b/examples/PiFace/Makefile | 183 | diff --git a/examples/PiFace/Makefile b/examples/PiFace/Makefile |
194 | index 0bde334..fc14c0c 100644 | 184 | index 4685adc..cfaf902 100644 |
195 | --- a/examples/PiFace/Makefile | 185 | --- a/examples/PiFace/Makefile |
196 | +++ b/examples/PiFace/Makefile | 186 | +++ b/examples/PiFace/Makefile |
197 | @@ -23,14 +23,20 @@ | 187 | @@ -26,14 +26,20 @@ ifneq ($V,1) |
198 | ################################################################################# | 188 | Q ?= @ |
199 | 189 | endif | |
200 | 190 | ||
201 | -#DEBUG = -g -O0 | 191 | -#DEBUG = -g -O0 |
202 | -DEBUG = -O3 | 192 | -DEBUG = -O3 |
@@ -224,10 +214,10 @@ index 0bde334..fc14c0c 100644 | |||
224 | # Should not alter anything below this line | 214 | # Should not alter anything below this line |
225 | ############################################################################### | 215 | ############################################################################### |
226 | diff --git a/examples/PiGlow/Makefile b/examples/PiGlow/Makefile | 216 | diff --git a/examples/PiGlow/Makefile b/examples/PiGlow/Makefile |
227 | index 8d31141..482c9e7 100644 | 217 | index acd4818..dabd64e 100644 |
228 | --- a/examples/PiGlow/Makefile | 218 | --- a/examples/PiGlow/Makefile |
229 | +++ b/examples/PiGlow/Makefile | 219 | +++ b/examples/PiGlow/Makefile |
230 | @@ -26,10 +26,10 @@ | 220 | @@ -29,10 +29,10 @@ endif |
231 | #DEBUG = -g -O0 | 221 | #DEBUG = -g -O0 |
232 | DEBUG = -O3 | 222 | DEBUG = -O3 |
233 | CC = gcc | 223 | CC = gcc |
@@ -241,14 +231,10 @@ index 8d31141..482c9e7 100644 | |||
241 | 231 | ||
242 | # Should not alter anything below this line | 232 | # Should not alter anything below this line |
243 | diff --git a/examples/q2w/Makefile b/examples/q2w/Makefile | 233 | diff --git a/examples/q2w/Makefile b/examples/q2w/Makefile |
244 | index 150c825..0544aa3 100644 | 234 | index 6f50fa0..c5e9f6e 100644 |
245 | --- a/examples/q2w/Makefile | 235 | --- a/examples/q2w/Makefile |
246 | +++ b/examples/q2w/Makefile | 236 | +++ b/examples/q2w/Makefile |
247 | @@ -22,14 +22,13 @@ | 237 | @@ -29,10 +29,10 @@ endif |
248 | # along with wiringPi. If not, see <http://www.gnu.org/licenses/>. | ||
249 | ################################################################################# | ||
250 | |||
251 | - | ||
252 | #DEBUG = -g -O0 | 238 | #DEBUG = -g -O0 |
253 | DEBUG = -O3 | 239 | DEBUG = -O3 |
254 | CC = gcc | 240 | CC = gcc |
@@ -262,17 +248,12 @@ index 150c825..0544aa3 100644 | |||
262 | 248 | ||
263 | ############################################################################### | 249 | ############################################################################### |
264 | diff --git a/gpio/Makefile b/gpio/Makefile | 250 | diff --git a/gpio/Makefile b/gpio/Makefile |
265 | index 449986e..95af1ad 100644 | 251 | index 7dcd090..83ec454 100644 |
266 | --- a/gpio/Makefile | 252 | --- a/gpio/Makefile |
267 | +++ b/gpio/Makefile | 253 | +++ b/gpio/Makefile |
268 | @@ -23,16 +23,20 @@ | 254 | @@ -30,13 +30,17 @@ ifneq ($V,1) |
269 | # along with wiringPi. If not, see <http://www.gnu.org/licenses/>. | 255 | Q ?= @ |
270 | ################################################################################# | 256 | endif |
271 | |||
272 | -DESTDIR=/usr | ||
273 | -PREFIX=/local | ||
274 | +DESTDIR?=/usr | ||
275 | +PREFIX?=/local | ||
276 | 257 | ||
277 | -#DEBUG = -g -O0 | 258 | -#DEBUG = -g -O0 |
278 | -DEBUG = -O2 | 259 | -DEBUG = -O2 |
@@ -290,49 +271,53 @@ index 449986e..95af1ad 100644 | |||
290 | +INCLUDE ?= -I$(INCLUDE_DIR) | 271 | +INCLUDE ?= -I$(INCLUDE_DIR) |
291 | +CFLAGS ?= $(DEBUG) -Wall $(INCLUDE) -Winline -pipe | 272 | +CFLAGS ?= $(DEBUG) -Wall $(INCLUDE) -Winline -pipe |
292 | + | 273 | + |
293 | +LDFLAGS = -L$(LIB_DIR) | 274 | +LDFLAGS ?= -L$(LIB_DIR) |
294 | LIBS = -lwiringPi -lwiringPiDev -lpthread -lm | 275 | LIBS = -lwiringPi -lwiringPiDev -lpthread |
295 | 276 | ||
296 | # May not need to alter anything below this line | 277 | # May not need to alter anything below this line |
297 | @@ -68,11 +72,10 @@ tags: $(SRC) | 278 | @@ -72,13 +76,10 @@ tags: $(SRC) |
298 | .PHONY: install | 279 | .PHONY: install |
299 | install: gpio | 280 | install: gpio |
300 | @echo "[Install]" | 281 | $Q echo "[Install]" |
301 | - @cp gpio $(DESTDIR)$(PREFIX)/bin | 282 | - $Q cp gpio $(DESTDIR)$(PREFIX)/bin |
302 | - @chown root.root $(DESTDIR)$(PREFIX)/bin/gpio | 283 | -ifneq ($(WIRINGPI_SUID),0) |
303 | - @chmod 4755 $(DESTDIR)$(PREFIX)/bin/gpio | 284 | - $Q chown root.root $(DESTDIR)$(PREFIX)/bin/gpio |
304 | - @mkdir -p $(DESTDIR)$(PREFIX)/man/man1 | 285 | - $Q chmod 4755 $(DESTDIR)$(PREFIX)/bin/gpio |
305 | - @cp gpio.1 $(DESTDIR)$(PREFIX)/man/man1 | 286 | -endif |
306 | + @install -d $(BIN_DIR) | 287 | - $Q mkdir -p $(DESTDIR)$(PREFIX)/man/man1 |
307 | + @install -m 4755 -o root -g root gpio $(BIN_DIR) | 288 | - $Q cp gpio.1 $(DESTDIR)$(PREFIX)/man/man1 |
308 | + @install -d $(DESTDIR)$(PREFIX)/share/man/man1 | 289 | + $Q install -d $(BIN_DIR) |
309 | + @install -m 644 -o root -g root gpio.1 $(DESTDIR)$(PREFIX)/share/man/man1 | 290 | + $Q install -m 4755 -o root -g root gpio $(BIN_DIR) |
291 | + $Q install -d $(DESTDIR)$(PREFIX)/share/man/man1 | ||
292 | + $Q install -m 644 -o root -g root gpio.1 $(DESTDIR)$(PREFIX)/share/man/man1 | ||
310 | 293 | ||
311 | .PHONY: install-deb | 294 | .PHONY: install-deb |
312 | install-deb: gpio | 295 | install-deb: gpio |
313 | @@ -83,7 +86,7 @@ install-deb: gpio | 296 | @@ -89,7 +90,7 @@ install-deb: gpio |
314 | .PHONY: uninstall | 297 | .PHONY: uninstall |
315 | uninstall: | 298 | uninstall: |
316 | @echo "[UnInstall]" | 299 | $Q echo "[UnInstall]" |
317 | - @rm -f $(DESTDIR)$(PREFIX)/bin/gpio | 300 | - $Q rm -f $(DESTDIR)$(PREFIX)/bin/gpio |
318 | + @rm -f $(BIN_DIR)/gpio | 301 | + $Q rm -f $(BIN_DIR)/gpio |
319 | @rm -f $(DESTDIR)$(PREFIX)/man/man1/gpio.1 | 302 | $Q rm -f $(DESTDIR)$(PREFIX)/man/man1/gpio.1 |
320 | 303 | ||
321 | .PHONY: depend | 304 | .PHONY: depend |
322 | diff --git a/wiringPi/Makefile b/wiringPi/Makefile | 305 | diff --git a/wiringPi/Makefile b/wiringPi/Makefile |
323 | index 015a894..5fc0659 100644 | 306 | index 6bbcc5d..5355b74 100644 |
324 | --- a/wiringPi/Makefile | 307 | --- a/wiringPi/Makefile |
325 | +++ b/wiringPi/Makefile | 308 | +++ b/wiringPi/Makefile |
326 | @@ -22,18 +22,22 @@ | 309 | @@ -25,19 +25,23 @@ VERSION=$(shell cat ../VERSION) |
327 | ################################################################################# | 310 | DESTDIR?=/usr |
311 | PREFIX?=/local | ||
328 | 312 | ||
329 | VERSION=$(shell cat ../VERSION) | ||
330 | -DESTDIR=/usr | ||
331 | -PREFIX=/local | ||
332 | +DESTDIR?=/usr | ||
333 | +PREFIX?=/local | ||
334 | +INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include | 313 | +INCLUDE_DIR?=$(DESTDIR)$(PREFIX)/include |
335 | +LIB_DIR?=$(DESTDIR)$(PREFIX)/lib | 314 | +LIB_DIR?=$(DESTDIR)$(PREFIX)/lib |
315 | + | ||
316 | LDCONFIG?=ldconfig | ||
317 | |||
318 | ifneq ($V,1) | ||
319 | Q ?= @ | ||
320 | endif | ||
336 | 321 | ||
337 | -STATIC=libwiringPi.a | 322 | -STATIC=libwiringPi.a |
338 | -DYNAMIC=libwiringPi.so.$(VERSION) | 323 | -DYNAMIC=libwiringPi.so.$(VERSION) |
@@ -344,86 +329,82 @@ index 015a894..5fc0659 100644 | |||
344 | -DEBUG = -O2 | 329 | -DEBUG = -O2 |
345 | -CC = gcc | 330 | -CC = gcc |
346 | -INCLUDE = -I. | 331 | -INCLUDE = -I. |
347 | -DEFS = -D_GNU_SOURCE | ||
348 | +#DEBUG ?= -g -O0 | 332 | +#DEBUG ?= -g -O0 |
349 | CFLAGS = $(DEBUG) $(DEFS) -Wformat=2 -Wall -Winline $(INCLUDE) -pipe -fPIC | ||
350 | +DEBUG ?= -O2 | 333 | +DEBUG ?= -O2 |
351 | +CC ?= gcc | 334 | +CC ?= gcc |
352 | +DEFS = -D_GNU_SOURCE | ||
353 | +INCLUDE ?= -I. | 335 | +INCLUDE ?= -I. |
354 | +CFLAGS ?= $(DEBUG) $(DEFS) -Wformat=2 -Wall -Winline $(INCLUDE) -pipe -fPIC | 336 | DEFS = -D_GNU_SOURCE |
355 | 337 | CFLAGS = $(DEBUG) $(DEFS) -Wformat=2 -Wall -Winline $(INCLUDE) -pipe -fPIC | |
356 | LIBS = | ||
357 | 338 | ||
358 | @@ -83,17 +87,17 @@ $(STATIC): $(OBJ) | 339 | @@ -89,17 +93,17 @@ $(STATIC): $(OBJ) |
359 | 340 | ||
360 | $(DYNAMIC): $(OBJ) | 341 | $(DYNAMIC): $(OBJ) |
361 | @echo "[Link (Dynamic)]" | 342 | $Q echo "[Link (Dynamic)]" |
362 | - @$(CC) -shared -Wl,-soname,libwiringPi.so -o libwiringPi.so.$(VERSION) -lpthread $(OBJ) | 343 | - $Q $(CC) -shared -Wl,-soname,libwiringPi.so$(WIRINGPI_SONAME_SUFFIX) -o libwiringPi.so.$(VERSION) -lpthread $(OBJ) |
363 | + @$(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) | 344 | + $Q $(CC) -shared -Wl,-soname,$(BASE_NAME).so.$(DYN_VERS_MAJ) -o $(BASE_NAME).so -lpthread $(OBJ) |
364 | 345 | ||
365 | .c.o: | 346 | .c.o: |
366 | @echo [Compile] $< | 347 | $Q echo [Compile] $< |
367 | - @$(CC) -c $(CFLAGS) $< -o $@ | 348 | - $Q $(CC) -c $(CFLAGS) $< -o $@ |
368 | + @$(CC) -c $(CFLAGS) -fPIC $< -o $@ | 349 | + $Q $(CC) -c $(CFLAGS) -fPIC $< -o $@ |
369 | 350 | ||
370 | 351 | ||
371 | .PHONY: clean | 352 | .PHONY: clean |
372 | clean: | 353 | clean: |
373 | @echo "[Clean]" | 354 | $Q echo "[Clean]" |
374 | - @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPi.* | 355 | - $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak libwiringPi.* |
375 | + @rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a | 356 | + $Q rm -f $(OBJ) $(OBJ_I2C) *~ core tags Makefile.bak $(BASE_NAME).so* $(BASE_NAME).a |
376 | 357 | ||
377 | .PHONY: tags | 358 | .PHONY: tags |
378 | tags: $(SRC) | 359 | tags: $(SRC) |
379 | @@ -104,22 +108,22 @@ tags: $(SRC) | 360 | @@ -110,22 +114,22 @@ tags: $(SRC) |
380 | .PHONY: install | 361 | .PHONY: install |
381 | install: $(DYNAMIC) | 362 | install: $(DYNAMIC) |
382 | @echo "[Install Headers]" | 363 | $Q echo "[Install Headers]" |
383 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | 364 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include |
384 | - @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | 365 | - $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include |
385 | + @install -m 0755 -d $(INCLUDE_DIR) | 366 | + $Q install -m 0755 -d $(INCLUDE_DIR) |
386 | + @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | 367 | + $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) |
387 | @echo "[Install Dynamic Lib]" | 368 | $Q echo "[Install Dynamic Lib]" |
388 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | 369 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib |
389 | - @install -m 0755 libwiringPi.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) | 370 | - $Q install -m 0755 libwiringPi.so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) |
390 | - @ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) $(DESTDIR)/lib/libwiringPi.so | 371 | - $Q ln -sf $(DESTDIR)$(PREFIX)/lib/libwiringPi.so.$(VERSION) $(DESTDIR)/lib/libwiringPi.so |
391 | - @ldconfig | 372 | - $Q $(LDCONFIG) |
392 | + @install -m 0755 -d $(LIB_DIR) | 373 | + $Q install -m 0755 -d $(LIB_DIR) |
393 | + @install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) | 374 | + $Q install -m 0755 $(BASE_NAME).so $(LIB_DIR)/$(DYNAMIC) |
394 | + @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so | 375 | + $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so |
395 | + @ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | 376 | + $Q ln -sf $(DYNAMIC) $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) |
396 | 377 | ||
397 | .PHONY: install-static | 378 | .PHONY: install-static |
398 | install-static: $(STATIC) | 379 | install-static: $(STATIC) |
399 | @echo "[Install Headers]" | 380 | $Q echo "[Install Headers]" |
400 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/include | 381 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/include |
401 | - @install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include | 382 | - $Q install -m 0644 $(HEADERS) $(DESTDIR)$(PREFIX)/include |
402 | + @install -m 0755 -d $(INCLUDE_DIR) | 383 | + $Q install -m 0755 -d $(INCLUDE_DIR) |
403 | + @install -m 0644 $(HEADERS) $(INCLUDE_DIR) | 384 | + $Q install -m 0644 $(HEADERS) $(INCLUDE_DIR) |
404 | @echo "[Install Static Lib]" | 385 | $Q echo "[Install Static Lib]" |
405 | - @install -m 0755 -d $(DESTDIR)$(PREFIX)/lib | 386 | - $Q install -m 0755 -d $(DESTDIR)$(PREFIX)/lib |
406 | - @install -m 0755 libwiringPi.a $(DESTDIR)$(PREFIX)/lib | 387 | - $Q install -m 0755 libwiringPi.a $(DESTDIR)$(PREFIX)/lib |
407 | + @install -m 0755 -d $(LIB_DIR) | 388 | + $Q install -m 0755 -d $(LIB_DIR) |
408 | + @install -m 0644 $(STATIC) $(LIB_DIR) | 389 | + $Q install -m 0755 $(STATIC) $(LIB_DIR) |
409 | 390 | ||
410 | .PHONY: install-deb | 391 | .PHONY: install-deb |
411 | install-deb: $(DYNAMIC) | 392 | install-deb: $(DYNAMIC) |
412 | @@ -134,9 +138,11 @@ install-deb: $(DYNAMIC) | 393 | @@ -140,9 +144,11 @@ install-deb: $(DYNAMIC) |
413 | .PHONY: uninstall | 394 | .PHONY: uninstall |
414 | uninstall: | 395 | uninstall: |
415 | @echo "[UnInstall]" | 396 | $Q echo "[UnInstall]" |
416 | - @cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) | 397 | - $Q cd $(DESTDIR)$(PREFIX)/include/ && rm -f $(HEADERS) |
417 | - @cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPi.* | 398 | - $Q cd $(DESTDIR)$(PREFIX)/lib/ && rm -f libwiringPi.* |
418 | - @ldconfig | 399 | - $Q $(LDCONFIG) |
419 | + @cd $(INCLUDE_DIR) && rm -f $(HEADERS) | 400 | + $Q cd $(INCLUDE_DIR) && rm -f $(HEADERS) |
420 | + @rm -f $(LIB_DIR)/$(STATIC) | 401 | + $Q rm -f $(LIB_DIR)/$(STATIC) |
421 | + @rm -f $(LIB_DIR)/$(DYNAMIC) | 402 | + $Q rm -f $(LIB_DIR)/$(DYNAMIC) |
422 | + @rm -f $(LIB_DIR)/$(BASE_NAME).so | 403 | + $Q rm -f $(LIB_DIR)/$(BASE_NAME).so |
423 | + @rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) | 404 | + $Q rm -f $(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ) |
424 | 405 | ||
425 | 406 | ||
426 | .PHONY: depend | 407 | .PHONY: depend |
427 | -- | 408 | -- |
428 | 1.9.1 | 409 | 2.1.4 |
429 | 410 | ||
diff --git a/recipes-devtools/wiringPi/wiringpi_git.bb b/recipes-devtools/wiringPi/wiringpi_git.bb index 21b5294..4254a0a 100644 --- a/recipes-devtools/wiringPi/wiringpi_git.bb +++ b/recipes-devtools/wiringPi/wiringpi_git.bb | |||
@@ -4,7 +4,8 @@ SECTION = "devel/libs" | |||
4 | LICENSE = "LGPLv3+" | 4 | LICENSE = "LGPLv3+" |
5 | LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=e6a600fd5e1d9cbde2d983680233ad02" | 5 | LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=e6a600fd5e1d9cbde2d983680233ad02" |
6 | 6 | ||
7 | SRCREV = "5edd177112c99416f68ba3e8c6c4db6ed942e796" | 7 | # tag 2.29 |
8 | SRCREV = "d79506694d7ba1c3da865d095238289d6175057d" | ||
8 | 9 | ||
9 | S = "${WORKDIR}/git" | 10 | S = "${WORKDIR}/git" |
10 | 11 | ||