iNavFlight / inav

INAV: Navigation-enabled flight control software
https://inavflight.github.io
GNU General Public License v3.0
3.14k stars 1.48k forks source link

INAV 1.73 (BETA) Build error 127 #2172

Closed wolflonezx11 closed 7 years ago

wolflonezx11 commented 7 years ago

Build error occurred. I am looking for a solution. Please

[/cygdrive/c/dev/inav]$ make TARGET=NAZE settings.yaml -> settings_generated.h, settings_generated.c /bin/sh: ruby: command not found make: *** [Makefile:933: src/main/fc/settings_generated.h] Error 127 [/cygdrive/c/dev/inav]$

stronnag commented 7 years ago

Install ruby Read release notes an Dev docs Search prior issues on this topic

DzikuVx commented 7 years ago

@wolflonezx11 just like @stronnag wrote: you need ruby

wolflonezx11 commented 7 years ago

Install ruby

Become a problem solver Thank you so much

2017-09-18 20:43 GMT+09:00 Paweł Spychalski notifications@github.com:

Closed #2172 https://github.com/iNavFlight/inav/issues/2172.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/iNavFlight/inav/issues/2172#event-1253261405, or mute the thread https://github.com/notifications/unsubscribe-auth/APiB_2HGMwwz7mfIp2hp3fhDItpOQLuhks5sjldbgaJpZM4Par8f .

StefoTheHighElf commented 7 years ago

For some reason I still get Ruby Problem:

/cygdrive/d/github/inav $ make TARGET=NAZE settings.yaml -> settings_generated.h, settings_generated.c C:/Ruby24-x64/lib/ruby/2.4.0/open3.rb:199:in spawn': No such file or directory - C:\Program Files (x86)\GNU Tools ARM Embedded\4.8 2014q2\bin/arm-none-eabi-g++.exe -mthumb -mcpu=cortex-m3 -flto -fuse-linker-plugin -Os -I./src/main -I./src/main/target -I./lib/main/STM32F10x_StdPeriph_Driver/inc -I./lib/main/CMSIS/CM3/CoreSupport -I./lib/main/CMSIS/CM3/DeviceSupport/ST/STM32F10x -I./lib/main/MAVLink -I./src/main/target/NAZE -ggdb3 -DDEBUG -std=c++11 -Wall -Wextra -Wunsafe-loop-optimizations -Wdouble-promotion -ffunction-sections -fdata-sections -DSTM32F10X_MD -DSTM32F10X -DFLASH_SIZE=128 -DHSE_VALUE=8000000 -DUSE_STDPERIPH_DRIVER -DNAZE -pedantic -D__FORKNAME__=inav -D__TARGET__=NAZE -D__REVISION__=974440df -o obj/tmp/test obj/tmp/test.cpp (Errno::ENOENT) from C:/Ruby24-x64/lib/ruby/2.4.0/open3.rb:199:inpopen_run' from C:/Ruby24-x64/lib/ruby/2.4.0/open3.rb:95:in popen3' from C:/Ruby24-x64/lib/ruby/2.4.0/open3.rb:258:incapture3' from ./src/utils/settings.rb:647:in block in compile_test_file' from ./src/utils/settings.rb:571:inmktmpdir' from ./src/utils/settings.rb:623:in compile_test_file' from ./src/utils/settings.rb:670:incheck_conditions' from ./src/utils/settings.rb:278:in initialize' from ./src/utils/settings.rb:876:innew' from ./src/utils/settings.rb:876:in `

' make: *** [Makefile:933: src/main/fc/settings_generated.h] Error 1

Regards

klomfar commented 7 years ago

Me too,how solve the problem?

digitalentity commented 7 years ago

The problem is spaces in your PATH: C:\Program Files (x86)\GNU Tools ARM Embedded\4.8 2014q2..... Ruby on CYGWIN doesn't like spaces in PATH variable.

klomfar commented 7 years ago

Thanks a lot but i have error with next line :/ Can you help me? $ make TARGET=NAZE settings.yaml -> settings_generated.h, settings_generated.c %% cli.c ./src/main/fc/cli.c:302:37: error: unknown type name 'clivalue_t' static void printValuePointer(const clivalue_t *var, const void *valuePointer, uint32_t full) ^ ./src/main/fc/cli.c: In function 'printValuePointer': ./src/main/fc/cli.c:307:16: error: request for member 'type' in something not a structure or union switch (var->type & VALUE_TYPE_MASK) { ^ ./src/main/fc/cli.c:307:25: error: 'VALUE_TYPE_MASK' undeclared (first use in this function) switch (var->type & VALUE_TYPE_MASK) { ^ ./src/main/fc/cli.c:307:25: note: each undeclared identifier is reported only once for each function it appears in ./src/main/fc/cli.c:308:10: error: 'VAR_UINT8' undeclared (first use in this function) case VAR_UINT8: ^ ./src/main/fc/cli.c:312:10: error: 'VAR_INT8' undeclared (first use in this function) case VAR_INT8: ^ ./src/main/fc/cli.c:316:10: error: 'VAR_UINT16' undeclared (first use in this function) case VAR_UINT16: ^ ./src/main/fc/cli.c:320:10: error: 'VAR_INT16' undeclared (first use in this function) case VAR_INT16: ^ ./src/main/fc/cli.c:324:10: error: 'VAR_UINT32' undeclared (first use in this function) case VAR_UINT32: ^ ./src/main/fc/cli.c:328:10: error: 'VAR_FLOAT' undeclared (first use in this function) case VAR_FLOAT: ^ ./src/main/fc/cli.c:331:21: error: request for member 'type' in something not a structure or union if ((var->type & VALUE_MODE_MASK) == MODE_DIRECT) { ^ ./src/main/fc/cli.c:331:30: error: 'VALUE_MODE_MASK' undeclared (first use in this function) if ((var->type & VALUE_MODE_MASK) == MODE_DIRECT) { ^ ./src/main/fc/cli.c:331:50: error: 'MODE_DIRECT' undeclared (first use in this function) if ((var->type & VALUE_MODE_MASK) == MODE_DIRECT) { ^ ./src/main/fc/cli.c:332:46: warning: implicit declaration of function 'clivalue_get_min' [-Wimplicit-function-declaration] cliPrintf(" %s", ftoa((float)clivalue_get_min(var), buf)); ^ ./src/main/fc/cli.c:333:46: warning: implicit declaration of function 'clivalue_get_max' [-Wimplicit-function-declaration] cliPrintf(" %s", ftoa((float)clivalue_get_max(var), buf)); ^ ./src/main/fc/cli.c:339:16: error: request for member 'type' in something not a structure or union switch (var->type & VALUE_MODE_MASK) { ^ ./src/main/fc/cli.c:341:17: error: request for member 'type' in something not a structure or union if ((var->type & VALUE_TYPE_MASK) == VAR_UINT32) ^ ./src/main/fc/cli.c:346:21: error: request for member 'type' in something not a structure or union if ((var->type & VALUE_MODE_MASK) == MODE_DIRECT) { ^ ./src/main/fc/cli.c:351:10: error: 'MODE_LOOKUP' undeclared (first use in this function) case MODE_LOOKUP: ^ ./src/main/fc/cli.c:352:16: error: request for member 'config' in something not a structure or union if (var->config.lookup.tableIndex < LOOKUP_TABLE_COUNT) { ^ ./src/main/fc/cli.c:353:23: error: 'cliLookupTables' undeclared (first use in this function) cliPrintf(cliLookupTables[var->config.lookup.tableIndex].values[value]); ^ ./src/main/fc/cli.c:353:42: error: request for member 'config' in something not a structure or union cliPrintf(cliLookupTables[var->config.lookup.tableIndex].values[value]); ^ ./src/main/fc/cli.c:355:13: warning: implicit declaration of function 'clivalue_get_name' [-Wimplicit-function-declaration] clivalue_get_name(var, buf); ^ ./src/main/fc/cli.c: In function 'valuePtrEqualsDefault': ./src/main/fc/cli.c:365:20: error: 'VALUE_TYPE_MASK' undeclared (first use in this function) switch (type & VALUE_TYPE_MASK) { ^ ./src/main/fc/cli.c:366:10: error: 'VAR_UINT8' undeclared (first use in this function) case VAR_UINT8: ^ ./src/main/fc/cli.c:370:10: error: 'VAR_INT8' undeclared (first use in this function) case VAR_INT8: ^ ./src/main/fc/cli.c:374:10: error: 'VAR_UINT16' undeclared (first use in this function) case VAR_UINT16: ^ ./src/main/fc/cli.c:378:10: error: 'VAR_INT16' undeclared (first use in this function) case VAR_INT16: ^ ./src/main/fc/cli.c:382:10: error: 'VAR_UINT32' undeclared (first use in this function) case VAR_UINT32: ^ ./src/main/fc/cli.c:386:10: error: 'VAR_FLOAT' undeclared (first use in this function) case VAR_FLOAT: ^ ./src/main/fc/cli.c: At top level: ./src/main/fc/cli.c:393:38: error: unknown type name 'clivalue_t' static uint16_t getValueOffset(const clivalue_t *value) ^ ./src/main/fc/cli.c: In function 'getValueOffset': ./src/main/fc/cli.c:395:18: error: request for member 'type' in something not a structure or union switch (value->type & VALUE_SECTION_MASK) { ^ ./src/main/fc/cli.c:395:27: error: 'VALUE_SECTION_MASK' undeclared (first use in this function) switch (value->type & VALUE_SECTION_MASK) { ^ ./src/main/fc/cli.c:396:10: error: 'MASTER_VALUE' undeclared (first use in this function) case MASTER_VALUE: ^ ./src/main/fc/cli.c:397:21: error: request for member 'offset' in something not a structure or union return value->offset; ^ ./src/main/fc/cli.c:398:10: error: 'PROFILE_VALUE' undeclared (first use in this function) case PROFILE_VALUE: ^ ./src/main/fc/cli.c:399:21: error: request for member 'offset' in something not a structure or union return value->offset + sizeof(pidProfile_t) * getConfigProfile(); ^ ./src/main/fc/cli.c:400:10: error: 'CONTROL_RATE_VALUE' undeclared (first use in this function) case CONTROL_RATE_VALUE: ^ ./src/main/fc/cli.c:401:21: error: request for member 'offset' in something not a structure or union return value->offset + sizeof(controlRateConfig_t) * getConfigProfile(); ^ ./src/main/fc/cli.c: At top level: ./src/main/fc/cli.c:406:36: error: unknown type name 'clivalue_t' static void *getValuePointer(const clivalue_t *value) ^ ./src/main/fc/cli.c: In function 'getValuePointer': ./src/main/fc/cli.c:408:37: warning: implicit declaration of function 'clivalue_get_pgn' [-Wimplicit-function-declaration] const pgRegistry_t* pg = pgFind(clivalue_get_pgn(value)); ^ ./src/main/fc/cli.c: At top level: ./src/main/fc/cli.c:412:31: error: unknown type name 'clivalue_t' static void dumpPgValue(const clivalue_t *value, uint8_t dumpMask) ^ ./src/main/fc/cli.c: In function 'dumpPgValue': ./src/main/fc/cli.c:420:58: error: request for member 'type' in something not a structure or union const bool equalsDefault = valuePtrEqualsDefault(value->type, pg->copy + valueOffset, pg->address + valueOffset); ^ ./src/main/fc/cli.c: In function 'dumpAllValues': ./src/main/fc/cli.c:437:15: error: unknown type name 'clivalue_t' const clivalue_t *value = &cliValueTable[i]; ^ ./src/main/fc/cli.c:437:36: error: 'cliValueTable' undeclared (first use in this function) const clivalue_t *value = &cliValueTable[i]; ^ ./src/main/fc/cli.c:439:19: error: request for member 'type' in something not a structure or union if ((value->type & VALUE_SECTION_MASK) == valueSection) { ^ ./src/main/fc/cli.c:439:28: error: 'VALUE_SECTION_MASK' undeclared (first use in this function) if ((value->type & VALUE_SECTION_MASK) == valueSection) { ^ ./src/main/fc/cli.c: At top level: ./src/main/fc/cli.c:445:31: error: unknown type name 'clivalue_t' static void cliPrintVar(const clivalue_t *var, uint32_t full) ^ ./src/main/fc/cli.c:452:36: error: unknown type name 'clivalue_t' static void cliPrintVarRange(const clivalue_t *var) ^ ./src/main/fc/cli.c: In function 'cliPrintVarRange': ./src/main/fc/cli.c:454:16: error: request for member 'type' in something not a structure or union switch (var->type & VALUE_MODE_MASK) { ^ ./src/main/fc/cli.c:454:25: error: 'VALUE_MODE_MASK' undeclared (first use in this function) switch (var->type & VALUE_MODE_MASK) { ^ ./src/main/fc/cli.c:455:11: error: 'MODE_DIRECT' undeclared (first use in this function) case (MODE_DIRECT): ^ ./src/main/fc/cli.c:458:11: error: 'MODE_LOOKUP' undeclared (first use in this function) case (MODE_LOOKUP): { ^ ./src/main/fc/cli.c:459:15: error: unknown type name 'lookupTableEntry_t' const lookupTableEntry_t *tableEntry = &cliLookupTables[var->config.lookup.tableIndex]; ^ ./src/main/fc/cli.c:459:49: error: 'cliLookupTables' undeclared (first use in this function) const lookupTableEntry_t *tableEntry = &cliLookupTables[var->config.lookup.tableIndex]; ^ ./src/main/fc/cli.c:459:68: error: request for member 'config' in something not a structure or union const lookupTableEntry_t *tableEntry = &cliLookupTables[var->config.lookup.tableIndex]; ^ ./src/main/fc/cli.c:461:44: error: request for member 'valueCount' in something not a structure or union for (uint32_t i = 0; i < tableEntry->valueCount ; i++) { ^ ./src/main/fc/cli.c:464:40: error: request for member 'values' in something not a structure or union cliPrintf(" %s", tableEntry->values[i]); ^ ./src/main/fc/cli.c: At top level: ./src/main/fc/cli.c:478:29: error: unknown type name 'clivalue_t' static void cliSetVar(const clivalue_t *var, const int_float_value_t value) ^ ./src/main/fc/cli.c: In function 'cliSetVar': ./src/main/fc/cli.c:482:16: error: request for member 'type' in something not a structure or union switch (var->type & VALUE_TYPE_MASK) { ^ ./src/main/fc/cli.c:482:25: error: 'VALUE_TYPE_MASK' undeclared (first use in this function) switch (var->type & VALUE_TYPE_MASK) { ^ ./src/main/fc/cli.c:483:10: error: 'VAR_UINT8' undeclared (first use in this function) case VAR_UINT8: ^ ./src/main/fc/cli.c:484:10: error: 'VAR_INT8' undeclared (first use in this function) case VAR_INT8: ^ ./src/main/fc/cli.c:488:10: error: 'VAR_UINT16' undeclared (first use in this function) case VAR_UINT16: ^ ./src/main/fc/cli.c:489:10: error: 'VAR_INT16' undeclared (first use in this function) case VAR_INT16: ^ ./src/main/fc/cli.c:493:10: error: 'VAR_UINT32' undeclared (first use in this function) case VAR_UINT32: ^ ./src/main/fc/cli.c:497:10: error: 'VAR_FLOAT' undeclared (first use in this function) case VAR_FLOAT: ^ ./src/main/fc/cli.c: In function 'cliDumpProfile': ./src/main/fc/cli.c:2165:19: error: 'PROFILE_VALUE' undeclared (first use in this function) dumpAllValues(PROFILE_VALUE, dumpMask); ^ ./src/main/fc/cli.c:2166:19: error: 'CONTROL_RATE_VALUE' undeclared (first use in this function) dumpAllValues(CONTROL_RATE_VALUE, dumpMask); ^ ./src/main/fc/cli.c: In function 'cliGet': ./src/main/fc/cli.c:2192:11: error: unknown type name 'clivalue_t' const clivalue_t *val; ^ ./src/main/fc/cli.c:2197:16: error: 'cliValueTable' undeclared (first use in this function) val = &cliValueTable[i]; ^ ./src/main/fc/cli.c:2198:13: warning: implicit declaration of function 'clivalue_name_contains' [-Wimplicit-function-declaration] if (clivalue_name_contains(val, name, cmdline)) { ^ ./src/main/fc/cli.c: In function 'cliSet': ./src/main/fc/cli.c:2220:11: error: unknown type name 'clivalue_t' const clivalue_t *val; ^ ./src/main/fc/cli.c:2229:20: error: 'cliValueTable' undeclared (first use in this function) val = &cliValueTable[i]; ^ ./src/main/fc/cli.c:2253:17: warning: implicit declaration of function 'clivalue_name_exact_match' [-Wimplicit-function-declaration] if (clivalue_name_exact_match(val, name, cmdline, variableNameLength)) { ^ ./src/main/fc/cli.c:2256:37: error: request for member 'type' in something not a structure or union const int mode = val->type & VALUE_MODE_MASK; ^ ./src/main/fc/cli.c:2256:46: error: 'VALUE_MODE_MASK' undeclared (first use in this function) const int mode = val->type & VALUE_MODE_MASK; ^ ./src/main/fc/cli.c:2258:22: error: 'MODE_DIRECT' undeclared (first use in this function) case MODE_DIRECT: { ^ ./src/main/fc/cli.c:2264:62: error: 'VALUE_TYPE_MASK' undeclared (first use in this function) if ((cliValueTable[i].type & VALUE_TYPE_MASK) == VAR_FLOAT) ^ ./src/main/fc/cli.c:2264:82: error: 'VAR_FLOAT' undeclared (first use in this function) if ((cliValueTable[i].type & VALUE_TYPE_MASK) == VAR_FLOAT) ^ ./src/main/fc/cli.c:2266:87: error: 'VAR_UINT32' undeclared (first use in this function) else if ((cliValueTable[i].type & VALUE_TYPE_MASK) == VAR_UINT32) ^ ./src/main/fc/cli.c:2276:22: error: 'MODE_LOOKUP' undeclared (first use in this function) case MODE_LOOKUP: { ^ ./src/main/fc/cli.c:2277:31: error: unknown type name 'lookupTableEntry_t' const lookupTableEntry_t *tableEntry = &cliLookupTables[cliValueTable[i].config.lookup.tableIndex]; ^ ./src/main/fc/cli.c:2277:65: error: 'cliLookupTables' undeclared (first use in this function) const lookupTableEntry_t *tableEntry = &cliLookupTables[cliValueTable[i].config.lookup.tableIndex]; ^ ./src/main/fc/cli.c:2279:88: error: request for member 'valueCount' in something not a structure or union for (uint32_t tableValueIndex = 0; tableValueIndex < tableEntry->valueCount && !matched; tableValueIndex++) { ^ ./src/main/fc/cli.c:2280:63: error: request for member 'values' in something not a structure or union matched = sl_strcasecmp(tableEntry->values[tableValueIndex], eqptr) == 0; ^ ./src/main/fc/cli.c: In function 'printConfig': ./src/main/fc/cli.c:2599:23: error: 'MASTER_VALUE' undeclared (first use in this function) dumpAllValues(MASTER_VALUE, dumpMask); ^ make: *** [Makefile:961: obj/main/NAZE/fc/cli.o] Chyba 1

stronnag commented 7 years ago

a contemporary compiler might help, 4.8 is ancient.

fiam commented 7 years ago

@klomfar You seem to have your local copy in an inconsistent state. Remove:

Make sure your checkout is clean (check git status output). Also, as @stronnag has said an updated compiler might be required too. The settings generator wasn't tested with GCC 4.8.

klomfar commented 7 years ago

thanks a lot, firmware compiled....

Arvycka commented 6 years ago

/usr/bin/sh: ruby: command not found

Installed everything as described in https://github.com/iNavFlight/inav/blob/master/docs/development/Building%20in%20Windows%20light.md

Tried on 2 different Windows 7 64 bit machines - same result :(

What Ruby version and where do I need to install?

Feldsalat commented 6 years ago

https://github.com/iNavFlight/inav/pull/2280

Arvycka commented 6 years ago

Thanks for the pointer. It helped.