qmk / qmk_firmware

Open-source keyboard firmware for Atmel AVR and Arm USB families
https://qmk.fm
GNU General Public License v2.0
18.24k stars 39.32k forks source link

[Bug] Massdrop Ctrl wont compile if COMMAND enabled #9840

Closed jpmorris closed 2 years ago

jpmorris commented 4 years ago

Describe the Bug

With COMMAND_ENABLE = yes in rules.mk. I get the following error:

Linking: .build/massdrop_ctrl_jmorris.elf                                                           [ERRORS]
 | 
 | /usr/lib/gcc/arm-none-eabi/10.1.0/../../../../arm-none-eabi/bin/ld: .build/obj_massdrop_ctrl_jmorris/common/command.o: in function `command_common':
 | /home/jmorris/qmk_firmware/tmk_core/common/command.c:502: undefined reference to `keyboard_idle'
 | collect2: error: ld returned 1 exit status
 | 
make[1]: *** [tmk_core/rules.mk:306: .build/massdrop_ctrl_jmorris.elf] Error 1

As a workaround I've had to comment out:

//    print_val_hex8(keyboard_protocol);
//    print_val_hex8(keyboard_idle);

In tmk_core/common/command.c

System Information

nblyumberg commented 4 years ago

This may be the gcc 10.x issue. I compiled the default keymap with: COMMAND_ENABLE = yes # Commands for debug and configuration

My environment is:

@nucleus ctrl % qmk doctor Ψ QMK Doctor is checking your environment. Ψ Detected macOS. Ψ All dependencies are installed. Ψ Found arm-none-eabi-gcc version 8.3.1 Ψ Found avr-gcc version 8.4.0 Ψ Found avrdude version 6.3 Ψ Found dfu-util version 0.9 Ψ Found dfu-programmer version 0.7.2 Ψ Submodules are up to date. Ψ QMK is ready to go

zvecr commented 2 years ago

Closing as this is correctly handled in the recent RIOT work, and there is little motivation to update the legacy code.