Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error compiling for sparkfun pro micro #17

Open
COZMIKDX opened this issue Jun 23, 2020 · 5 comments
Open

Error compiling for sparkfun pro micro #17

COZMIKDX opened this issue Jun 23, 2020 · 5 comments
Labels
bug stale Ticket wasn’t updated in a long time

Comments

@COZMIKDX
Copy link

COZMIKDX commented Jun 23, 2020

I am on Ubuntu 18.04 and using Arduino 1.8.3 since the activate.py script seems to want this version.
I am trying to compile the example program. I have run activate.py and it's output was all successes.

Here is the error message:
Archiving built core (caching) in: /tmp/arduino_cache_770586/core/core_SparkFun_avr_promicro_cpu_16MHzatmega32U4_4ec126580105bbcfef3f91ee9bd9669d.a USBCore.cpp.o (symbol from plugin): In function RxLEDPulse':
(.text+0x0): multiple definition of __vector_11' sketch/LUFA.c.o (symbol from plugin):(.text+0x0): first defined here USBCore.cpp.o (symbol from plugin): In function RxLEDPulse':
(.text+0x0): multiple definition of __vector_10' sketch/LUFA.c.o (symbol from plugin):(.text+0x0): first defined here collect2: error: ld returned 1 exit status exit status 1 Error compiling for board SparkFun Pro Micro.

@iFreilicht
Copy link
Collaborator

This seems to be related to #14, except that person is using an Arduino Leonardo. I'm starting to suspect the activate.py script doesn't hide some file properly.

I tried this on my machine with 1.8.12 using the Sparkfun Board Manager URL https://raw.githubusercontent.com/sparkfun/Arduino_Boards/master/IDE_Board_Manager/package_sparkfun_index.json and selecting "Sparkfun Pro Micro" as the board, and it compiled succesfully.

Could you run deactivate.py and activate.py again and post the output of activate.py here?

@iFreilicht
Copy link
Collaborator

Ah, I just noticed the shebang is missing in deactivate.py so because you're on linux, rather run python3 deactivate.py

@COZMIKDX
Copy link
Author

COZMIKDX commented Jul 4, 2020

activate.py output:

Compatible Arduino IDE version 1.8.3 detected!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/CDC.cpp'!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/PluggableUSB.cpp'!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/PluggableUSB.h'!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBAPI.h'!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBCore.cpp'!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBCore.h'!
Successfully hid file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBDesc.h'!
Successfully hid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/Arduino.h'!
Successfully hid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/main.cpp'!

deactivate.py output:

Compatible Arduino IDE version 1.8.3 detected!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/CDC.cpp'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/PluggableUSB.cpp'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/PluggableUSB.h'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBAPI.h'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBCore.cpp'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBCore.h'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBDesc.h'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/Arduino.h'!
Successfully unhid section in file `/home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/main.cpp'!

@iFreilicht
Copy link
Collaborator

Short tip for formatting: You can wrap all the output like so:

```
output
```

This way, it will be displayed correctly.

But this is a very strange issue.

If deactivate.py is successful, that means USBCore.cpp was fully hidden, so __vector_10 and __vector_11 can't be defined there, but still your build output shows that it tries to create USBCore.cpp.o.

Could you run the activate.py script again and check what the file /home/cosmictacocat/Programs/arduino-1.8.3/hardware/arduino/avr/cores/arduino/USBCore.cpp contains? It should have these lines at the beginning:

//=====================================
//== This section is hidden by LUFA! ==
//=====================================
#if 0

If that is indeed the case, try to compile it again and see if you have the same error.

If you still get that error, run the Arduino IDE from the command line instead of from the launcher, and check whether the correct version of the Arduino IDE is running before compiling.

@RayPS
Copy link

RayPS commented Aug 12, 2021

I got the same error

USBCore.cpp.o (symbol from plugin): In function `RxLEDPulse':
(.text+0x0): multiple definition of `__vector_11'
sketch/LUFA.c.o (symbol from plugin):(.text+0x0): first defined here
USBCore.cpp.o (symbol from plugin): In function `RxLEDPulse':
(.text+0x0): multiple definition of `__vector_10'
sketch/LUFA.c.o (symbol from plugin):(.text+0x0): first defined here
collect2: error: ld returned 1 exit status
exit status 1
Error compiling for board SparkFun Pro Micro.

@iFreilicht iFreilicht added bug stale Ticket wasn’t updated in a long time labels Sep 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug stale Ticket wasn’t updated in a long time
Projects
None yet
Development

No branches or pull requests

3 participants