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

unit test / unity.h compilation errors #27647

Closed
1 task done
mtraven opened this issue Jan 18, 2025 · 1 comment
Closed
1 task done

unit test / unity.h compilation errors #27647

mtraven opened this issue Jan 18, 2025 · 1 comment

Comments

@mtraven
Copy link

mtraven commented Jan 18, 2025

Did you test the latest bugfix-2.1.x code?

Yes, and the problem still exists.

Bug Description

When attempting to compile the most recent bug fix (as of yesterday) and the beta release I am unable to complete compilation. I hesitate to call this a bug, given that I cant compile either of these versions "out of the box", or for my environment (btt skr 2). I must have something wrong? I've attached pictures of the errors for these versions. If I go back to 2.1.2.5 (latest stable), everything works fine. I also dont find the "test" folder that seems to be giving me problems in the newer versions. I'm not sure if thats something corresponding to the newer versions, or just on the bugfix / beta branches?

One thing I noticed that might help: I had to change my environment from BIGTREE_SKR_2_F429_USB to STM32F429VG_btt. Not a big deal, seems like there was just some nomenclature change...but maybe those changes are related?

Image

Image

MarlinConfig.zip

Bug Timeline

new staring with current bf & beta versions

Expected behavior

I expected it to compile!

Actual behavior

it did not compile!

Steps to Reproduce

  1. unzip current marlin repo.
  2. modiy platformIO.ini for STM32F429VG_btt environment
  3. change motherboard to BOARD_BTT_SKR_V2_0_REV_B
  4. build.

Version of Marlin Firmware

bugfix 2.1.x (16 jan 2025)

Printer model

homemade

Electronics

btt skr-2 with 2209 drivers

LCD/Controller

btt mini 12864

Other add-ons

No response

Bed Leveling

UBL Bilinear mesh

Your Slicer

IdeaMaker

Host Software

Repetier Host

Don't forget to include

  • A ZIP file containing your Configuration.h and Configuration_adv.h.

Additional information & file uploads

the config files I've included are very basic, just enough to get it to compile for my system.

thanks to all involved in maintaining this project, it cant be easy!

@ellensp
Copy link
Contributor

ellensp commented Jan 18, 2025

Marlin under platformio uses source filtering, a system of completely skipping files and directories that are not needed.
In platformio.ini it has default_src_filter = +<src/*> -<src/config> -<src/tests>
This set the default to remove the directory src/tests from being compiled
In features.ini it has
MARLIN_TEST_BUILD = build_src_filter=+<src/tests>
Ie this adds the src/tests folder back in, but only when MARLIN_TEST_BUILD is defined.

My best guess if you have totally broken the platformio.ini file disabling source filtering, you probably used import arduino or some other loading option instead of just opening the Marlin folder with menu File|Open folder.

BIGTREE_SKR_2_F429_USB is not a valid build environment for this board.
It was renamed to STM32F429VG_btt_USB 6 months ago
This is the list of valid build environments for this motherboard

  • STM32F407VG_btt
  • STM32F407VG_btt_USB
  • STM32F407VG_btt_USB_debug
  • STM32F429VG_btt
  • STM32F429VG_btt_USB
  • STM32F429VG_btt_USB_debug

If your using the stock "Platformio: Build" button you have to update the file platformio.ini and set default_envs to one of these valid build environments
Or you use the Auto build Marlin plugin which will give buttons for the options you can use

Image

restore your platformio.ini file to the stock one
https://raw.githubusercontent.com/MarlinFirmware/Marlin/refs/heads/bugfix-2.1.x/platformio.ini

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants