Description
I am trying to do something fairly unconventional, which is trying to use arduino-builder on a Beaglebone Black (armhf single board computer) to build an Arduino sketch with the latest 1.6.6 Arduino files. arduino-builder is required, since the distribution itself is CLI only, no display (and no one has built an armhf port of 1.6.6). Here are the steps I have taken (all on a beaglebone):
- Cloned the latest Arduino master branch on Git to get the latest /hardware/ folder
- Installed the latest avr-gcc toolchain (4.8.1) to /usr/bin/
- Successfully built arduino-builder
- Created a test sketch which is an empty init() and a loop(){ Delay(1000); }
- Added the line "mega.build.mcu=atmega2560" to Arduino/hardware/arduino/avr/boards.txt, since it was missing for some reason and caused arduino-builder to error with an empty -mmcu flag
- Changed the following to fix an error:
compiler.path={runtime.tools.avr-gcc.path}/bin/
to
compiler.path=/usr/bin/
- Executed the following command:
./arduino-builder -hardware="/root/workspace/Arduino/hardware/" -tools="/usr/bin/" -fqbn=arduino:avr:mega -verbose test.ino
Following is the resulting output. The apparent error is "ctags pattern is missing"
"/usr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -w -x c++ -E -CC -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10600 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR "-I/root/workspace/Arduino/hardware/arduino/avr/cores/arduino" "-I/root/workspace/Arduino/hardware/arduino/avr/variants/mega" "/tmp/arduino-sketch-F65E51C7CC67F8F1D777CCD86FAE2D65/sketch/test.ino.cpp" -o "/tmp/arduino-sketch-F65E51C7CC67F8F1D777CCD86FAE2D65/preproc/test.ino.cpp_134020434_preprocessed.cpp"
"/usr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -w -x c++ -E -CC -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10600 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR "-I/root/workspace/Arduino/hardware/arduino/avr/cores/arduino" "-I/root/workspace/Arduino/hardware/arduino/avr/variants/mega" "/tmp/arduino-sketch-F65E51C7CC67F8F1D777CCD86FAE2D65/sketch/test.ino.cpp" -o "/tmp/arduino-sketch-F65E51C7CC67F8F1D777CCD86FAE2D65/preproc/test.ino.cpp_1597969999_preprocessed.cpp"
"/usr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -w -x c++ -E -CC -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10600 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR "-I/root/workspace/Arduino/hardware/arduino/avr/cores/arduino" "-I/root/workspace/Arduino/hardware/arduino/avr/variants/mega" "/tmp/arduino-sketch-F65E51C7CC67F8F1D777CCD86FAE2D65/sketch/test.ino.cpp" -o "/tmp/arduino-sketch-F65E51C7CC67F8F1D777CCD86FAE2D65/preproc/ctags_target_for_gcc_minus_e.cpp"
ctags pattern is missing
I tried grepping through the arduino-builder folder, but couldn't find that specific error string anywhere. I then realized that the machine itself didn't have ctags installed, so I ran apt-get install exuberant-ctags, which added ctags to /usr/bin/ as well. No change observed.
Any ideas on how I might fix this problem?
Also, I notice that there is a arduino-builder/src/arduino.cc/builder/hardware/platform.txt file which sets the variables:
tools.ctags.path={runtime.tools.ctags.path}
tools.ctags.cmd.path={path}/ctags
tools.ctags.pattern="{cmd.path}" -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives "{source_file}"
Where are these being used? They aren't present in my Arduino/hardware/..../platform.txt file, and as far as I can tell, the arduino-builder executable doesn't know anything about the platform.txt file in its build folder (unless those options were built into it somehow when I ran the Go build?)