Closed MrCapone closed 7 years ago
Update issue info as required.
Fixed with commit d32b5b656fd481fe73bd300bbfd6fd411f5a612f
After d32b5b6 issue still appear
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c: In function ‘reed_solomon_new’:
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:399:9: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int row = 0; row < rs->shards; row++) {
^
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:399:9: note: use option -std=c99 or -std=gnu99 to compile your code
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:400:13: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int col = 0; col < data_shards; col++)
^
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:419:9: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int j = 0; j < parity_shards; j++) {
^
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:420:13: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int i = 0; i < data_shards; i++)
^
udooer@udoo:~/moonlight-embedded$ git log
commit d32b5b656fd481fe73bd300bbfd6fd411f5a612f
Author: Iwan Timmer <irtimmer@gmail.com>
Date: Wed Sep 6 22:14:22 2017 +0200
Set C99 usage globally instead of per target
Commit 06c3c7a should fix the issue with moonlight-common-c
Build works without errors on gcc-5 (Ubuntu/Linaro 5.4.1-2ubuntu1~14.04)
.
But if i switch to gcc-4 (Ubuntu/Linaro 4.8.5-2ubuntu1~14.04.1)
i got build errors:
[ 41%] Building C object libgamestream/CMakeFiles/moonlight-common.dir/__/third_party/moonlight-common-c/reedsolomon/rs.c.o
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c: In function ‘reed_solomon_new’:
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:399:9: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int row = 0; row < rs->shards; row++) {
^
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:399:9: note: use option -std=c99 or -std=gnu99 to compile your code
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:400:13: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int col = 0; col < data_shards; col++)
^
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:419:9: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int j = 0; j < parity_shards; j++) {
^
/home/udooer/moonlight-embedded/third_party/moonlight-common-c/reedsolomon/rs.c:420:13: error: ‘for’ loop initial declarations are only allowed in C99 mode
for (int i = 0; i < data_shards; i++)
^
make[2]: *** [libgamestream/CMakeFiles/moonlight-common.dir/__/third_party/moonlight-common-c/reedsolomon/rs.c.o] Error 1
make[1]: *** [libgamestream/CMakeFiles/moonlight-common.dir/all] Error 2
make: *** [all] Error 2
Please provide the following info.
Moonlight Embedded version: a4e19af Moonlight Embedded source: compiled from git source Moonlight Embedded running on: UDOO Quad based on imx6 Moonlight Embedded running on distribution: Udoobuntu based on Ubuntu 14.04
I installed all dependencies and tried build with commands:
and got build error
I made PR to fix it https://github.com/irtimmer/moonlight-embedded/pull/554