Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

Problems after updating ceedling from 0.31.1 to 1.0.1

27 views
Skip to first unread message

Marc Palmer

unread,
Feb 4, 2025, 2:43:18 AMFeb 4
to ThrowTheSwitch Forums

Hey,

after updating from 0.31.1 to 1.0.1 ceedling does not link my files anymore. I get this error messages for every function:

👟 Building Objects

-------------------

Compiling test_CTRL.c...

Compiling test_CTRL::test_CTRL_runner.c...

Compiling test_CTRL::unity.c...

👟 Building Test Executables

----------------------------

Linking test_CTRL.out...

🧨 EXCEPTION: 'Default Test Linker' (gcc) terminated with exit code [1] and output >>

/usr/bin/ld: build/test/out/test_CTRL/test_CTRL.o: in function `setUp':

/mnt/c/Users/User/Documents/git_repos/CamCar/test/test_CTRL.c:25: undefined reference to `crcInit'

/usr/bin/ld: /mnt/c/Users/User/Documents/git_repos/CamCar/test/test_CTRL.c:26: undefined reference to `crcFast'

/usr/bin/ld: build/test/out/test_CTRL/test_CTRL.o: in function `test_CTRL_receiveMsg_check_len':

/mnt/c/Users/User/Documents/git_repos/CamCar/test/test_CTRL.c:35: undefined reference to `fake_fill_msgBuffer'

/usr/bin/ld: /mnt/c/Users/User/Documents/git_repos/CamCar/test/test_CTRL.c:36: undefined reference to `receive_msg'

/usr/bin/ld: build/test/out/test_CTRL/test_CTRL.o: in function `test_CTRL_receiveMsg_check_cmd':

/mnt/c/Users/User/Documents/git_repos/CamCar/test/test_CTRL.c:41: undefined reference to `fake_fill_msgBuffer'

/usr/bin/ld: /mnt/c/Users/User/Documents/git_repos/CamCar/test/test_CTRL.c:42: undefined reference to `receive_msg'

/usr/bin/ld: build/test/out/test_CTRL/test_CTRL.o: in function `test_CTRL_receiveMsg_check_command_not_inquiry':

.... and so on.

I don't really understand how to solve this problem. I added the directories to the paths part of the project.yml

:paths:

:test:

  • +:test/**

  • -:test/support

:source:

  • CAM_CART/**

  • CAM_CART/vl/src/**

  • CAM_CART/hal/include/**

  • "/mnt/c/Program Files (x86)/Atmel/Studio/7.0/packs/atmel/SAMD21_DFP/1.3.395/samd21a/include/"

  • "/mnt/c/Program Files (x86)/Atmel/Studio/7.0/packs/arm/CMSIS/5.4.0/CMSIS/Core/Include/"

#    - src/**

:include:

  • CAM_CART/**

  • CAM_CART/vl/src

  • CAM_CART/hal/include

  • "/mnt/c/Program Files (x86)/Atmel/Studio/7.0/packs/atmel/SAMD21_DFP/1.3.395/samd21a/include/"

  • "/mnt/c/Program Files (x86)/Atmel/Studio/7.0/packs/arm/CMSIS/5.4.0/CMSIS/Core/Include/"

#- src/** # In simple projects, this entry often duplicates :source

:support:

  • test/support

:libraries: []

Resetting and Reinitializing everything did not help.

What else can I do?

Kind regards,

Marc

Marcelo Jo

unread,
Feb 4, 2025, 8:24:06 AMFeb 4
to throwth...@googlegroups.com
Are you using the new yml file? Is the mock enabled?

--
You received this message because you are subscribed to the Google Groups "ThrowTheSwitch Forums" group.
To unsubscribe from this group and stop receiving emails from it, send an email to throwtheswitc...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/throwtheswitch/d2b6d982-eb63-4eb8-be65-7e231a04aabdn%40googlegroups.com.

Mike Karlesky

unread,
Feb 4, 2025, 9:01:13 AMFeb 4
to throwth...@googlegroups.com

Marc,

Without knowing a variety of details, it's quite difficult to even guess as to the problem.

Could you kindly reply with three attachments? Please enable verbose logging with --verbosity debug and capture a log file using either the log file command line option or shell redirection. Send that log file. Please also attach your project configuration file. Please attach your test file.

If these contain sensitive information, feel free to anonymize or cut out sections. If anonymizing is too much work, we'll need to figure out another option.

On Tue, Feb 4, 2025 at 2:43 AM 'Marc Palmer' via ThrowTheSwitch Forums <throwth...@googlegroups.com> wrote:
--

Mark Vander Voord

unread,
Feb 4, 2025, 9:17:32 AMFeb 4
to throwth...@googlegroups.com
Marc:

I notice that only your test file and the test file runner are being built. Possibly this is because you've already built this test and so it just rebuilt things that changed, OR it's a clue as to what is wrong.

Your test file specifies what files to compile and link by either or both of two methods:

 - It includes the header of the same name, like "a.h" will cause Ceedling to seek, compile, and link "a.c" if it exists
 - It specifies a test file using our macro TEST_SOURCE_FILE("a.c")

You need to use one of these two methods for EACH file that you need linked. Since you said that it worked for 0.31 but not for 1.0.1, one possibility is that you were using the old macro and that you haven't updated it to TEST_SOURCE_FILE.

It's also possible that we have a problem with our preprocessing still (this was the reason 1.0.1 came out so quickly after 1.0.0). If this is the case, we're going to need to know more details.

I was typing this as Michael sent his response. I'll send it anyway, as it provides some things to check yourself. If the stuff above fails, we really could use the information Michael requested.

Mark
Reply all
Reply to author
Forward
0 new messages