Skip to content

Unexpected results with --board & --verify arguments in CLI #3503

Closed
@toddtreece

Description

@toddtreece

I've been experimenting with adding Travis CI to test Adafruit library builds, and I'm having an issue running builds against the Due. SoftwareSerial is used in the examples, and there's an #ifdef to use Serial1 on the Due instead of SoftwareSerial. The build fails when I set the --board and --verify in one shot, and it seems like the CLI is only partially accepting the new board setting:

$ arduino --verify --board arduino:sam:arduino_due_x_dbg $PWD/examples/IncomingCall/IncomingCall.ino
Picked up JAVA_TOOL_OPTIONS: 
Loading configuration...
Xlib:  extension "RANDR" missing on display ":1.0".
Initializing packages...
Preparing boards...
Verifying...
WARNING: library SoftwareSerial claims to run on [avr] architecture(s) and may be incompatible with your current board which runs on [sam] architecture(s).
/usr/local/share/arduino/hardware/arduino/avr/libraries/SoftwareSerial/SoftwareSerial.cpp:45:30: fatal error: util/delay_basic.h: No such file or directory
 #include <util/delay_basic.h>
                              ^
compilation terminated.
Error compiling.
The command "arduino --verify --board arduino:sam:arduino_due_x_dbg $PWD/examples/IncomingCall/IncomingCall.ino" exited with 1.

It does work if I set the --board and --save-prefs separately in another call to arduino:

$ arduino --board arduino:sam:arduino_due_x --save-prefs
Picked up JAVA_TOOL_OPTIONS: 
Xlib:  extension "RANDR" missing on display ":1.0".
The command "arduino --board arduino:sam:arduino_due_x --save-prefs" exited with 0.

$ arduino --verify $PWD/examples/FONAtest/FONAtest.ino
Picked up JAVA_TOOL_OPTIONS: 
Loading configuration...
Xlib:  extension "RANDR" missing on display ":1.0".
Initializing packages...
Preparing boards...
Verifying...
Sketch uses 26,488 bytes (5%) of program storage space. Maximum is 524,288 bytes.
The command "arduino --verify $PWD/examples/FONAtest/FONAtest.ino" exited with 0.

This happens in v1.6.5 on both Linux & OS X.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Component: CLIThe Arduino IDE's command line interface

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions