Skip to content

fresh install does not compile? #207

Description

@Bazmundi
  1. Downloaded: ArduPilot-Arduino-1.0.3 for Windows with GCC 4.8.2 to:
    D:\MEGAPIRATE\ArduPilot-Arduino-1.0.3-windows

  2. Downloaded: MegaPilotNG and saved to:
    D:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4

  3. On windoze 10, so copied pde.jar from distro at 2. to;
    D:\MEGAPIRATE\ArduPilot-Arduino-1.0.3-windows\lib

  4. Copied libraries from distro at 2. to:
    D:\MEGAPIRATE\ArduPilot-Arduino-1.0.3-windows\libraries

  5. Started IDE and selected menu item Arduino IDE: ArduPilot>Hal Board>MegaPirateNG

  6. Selected menu item Arduino IDE: Tools>Board>Arduino Mega

  7. Selected menu item Arduino IDE: File>Preferences, and set "Sketchbook location:" to:
    D:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4

  8. Selected menu item Arduino IDE: File>Sketchbooks>Arducopter

  9. Selected menu item Arduino IDE: Sketch>Verify/Compile

  10. Compile churned for a while, clapped out with the following (look for bold italic text):
    Building for MegaPirateNG
    Excluding arduino core from include paths
    avr-gcc: error: unrecognized command line option '-assembler-with-cpp'

  11. With verbose on, tail is (look for bold italic text):
    D:\MEGAPIRATE\ArduPilot-Arduino-1.0.3-windows\hardware\tools\avr\bin\avr-gcc -c -g -assembler-with-cpp -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=103 -DUSB_VID=null -DUSB_PID=null -mcall-prologues -DCONFIG_HAL_BOARD=HAL_BOARD_MPNG -DEXCLUDECORE -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Common -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Progmem -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Menu -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Param -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_AVR -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_MPNG -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_AVR_SITL -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_SMACCM -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_PX4 -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_Empty -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\GCS_MAVLink -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_GPS -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\DataFlash -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_ADC -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_ADC_AnalogSource -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Baro -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Compass -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Math -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Curve -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_InertialSensor -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_AHRS -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\APM_PI -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AC_PID -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\RC_Channel -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Motors -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_RangeFinder -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_OpticalFlow -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\Filter -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Buffer -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Relay -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Camera -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Mount -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Airspeed -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_InertialNav -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AC_WPNav -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Declination -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AC_Fence -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\memcheck -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\SITL -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_Scheduler -ID:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_AVR\utility D:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\libraries\AP_HAL_AVR\utility\ftoa_engine.S -oC:\Users\rr\AppData\Local\Temp\build8569147893428641893.tmp\AP_HAL_AVR\utility\ftoa_engine.S.o
    avr-gcc: error: unrecognized command line option '-assembler-with-cpp'

  12. The quirk is, on a search of directories with jEdit, "assembler-with-cpp" comes up as:
    D:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\mk\board_avr.mk
    ASOPTS = -x assembler-with-cpp
    D:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\mk\board_avr_sitl.mk
    ASOPTS = -x assembler-with-cpp

So, it seems the correct call is in the *.mk file but the IDE seems to make a deprecated call to "-assembler-with-cpp" instead of "-x assembler-with-cpp" some-old-how.

There in fact seems to be a disconnect because the failed call doesn't appear to line up with the mk files in the distro (under D:\MEGAPIRATE\ardupilot-mpng-mpng-3.0.1-r4\mk), is that true?

In any event, someone with a knowledge of this convoluted build environment please?

Cheers
A

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions