feilipu / avrfreertos

AVR ATmega port of freeRTOS
185 stars 54 forks source link

Compile error LINUX #2

Closed geosmall closed 8 years ago

geosmall commented 8 years ago

Repository downloaded as a zip file and extracted into folder. Instructions followed per https://feilipu.me/2011/09/22/freertos-and-libraries-for-avr-atmega/ as directed. Eclipse and Arduino build environments set up per above on Ubuntu 14.04 LTS.

"Build All" appears to build files successfully, but missing file errors are thrown. Example include file "lib_crc.h" is referenced, but does not appear to be included in repository.

Console capture from build below:

` 09:40:09 \ Build of configuration Release for project freeRTOS82x ** make all Building file: ../retrograde_v2/main.c Invoking: AVR Compiler avr-gcc -I"/home/geo/STM32Toolchain/projects/freeRTOS82x/freeRTOS82x/include" -Wall -Os -fpack-struct -fshort-enums -ffunction-sections -fdata-sections -ffunction-sections -fdata-sections -mcall-prologues -mrelax -std=gnu99 -funsigned-char -funsigned-bitfields -mmcu=atmega328p -DF_CPU=16000000UL -MMD -MP -MF"retrograde_v2/main.d" -MT"retrograde_v2/main.o" -c -o "retrograde_v2/main.o" "../retrograde_v2/main.c" Finished building: ../retrograde_v2/main.c

Building file: ../ramfs_supervisor/main.c Invoking: AVR Compiler avr-gcc -I"/home/geo/STM32Toolchain/projects/freeRTOS82x/freeRTOS82x/include" -Wall -Os -fpack-struct -fshort-enums -ffunction-sections -fdata-sections -ffunction-sections -fdata-sections -mcall-prologues -mrelax -std=gnu99 -funsigned-char -funsigned-bitfields -mmcu=atmega328p -DF_CPU=16000000UL -MMD -MP -MF"ramfs_supervisor/main.d" -MT"ramfs_supervisor/main.o" -c -o "ramfs_supervisor/main.o" "../ramfs_supervisor/main.c" ../ramfs_supervisor/main.c:22:21: fatal error: lib_crc.h: No such file or directory

include "lib_crc.h"

                 ^

compilation terminated. make: *\ [ramfs_supervisor/main.o] Error 1

09:40:10 Build Finished (took 687ms) `

feilipu commented 8 years ago

There's about 4 years of history in this repository, with projects of different stages of development. Trying to "Build All" across all of the separate projects is something I've never tried.

The instructions point towards putting the freeRTOS files in one static library project, and importing each project into a separate application project. It would not be appropriate to put everything into one mega-sized project.

Occasionally, I will move my freeRTOS library files around or rename them in order to make things cleaner, but not go back to update every old project. Some of them are experimental anyway, and don't completely work.

The ramfs project was one that I built using a Rugged Circuits QuadRAM device. I passed the QuadRAM device onto someone else, and therefore don't have one to test any more. So the ramfs_supervisor project hasn't been built for a while. I've changed the lib_crc.h file to be called lib_util.h in the interim.

geosmall commented 8 years ago

Ok thanks, I understand better now sorry from the explanation above. I'm new to FreeRTOS so a bit overwhelmed by files folders and options currently.

It may be worth an update as the repository points to the https://feilipu.me/2011/09/22/freertos-and-libraries-for-avr-atmega/ for getting started. I see this link is to an older post. It makes no mention of several points you clarify above.

Best Regards, George

feilipu commented 8 years ago

For interest have a look at miniAVRfreeRTOS. Then you can see the essence of freertos. Everything else is collections I've added, at one time or other.