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

Some build rule fixes (fix use of libstdc++ and printf) #111

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

matthijskooijman
Copy link
Collaborator

These are just two minor fixes I noticed when trying a somewhat more complicated sketch using libstdc++ for SAM. One is really a fix, the other is the second half of an earlier fix by @facchinm.

This ensures some C++-specific symbols, such as
`std::_throw_bad_function_call` and probably others, are automatically
included in the link, preventing linker errors when using some standard
c++ library bits (such as `std::function`).

This follows the same change done for SAMD:

    arduino/ArduinoCore-samd#276
This define would serve to use the integer-only version of printf rather
than the default. In commit 46470a9 (Remove override printf define from
cpp receipe), this was removed from the cpp recipe, probably because
this define could cause problems in C++ code and because the Due has
plenty of memory for this.

However, this same override was still present in the c recipe, so this
introduced an inconsistency between .c and .cpp files, where they would
end up getting different versions of printf. This commit fixes this by
also removing the override for .c files.
@CLAassistant
Copy link

CLAassistant commented Apr 9, 2021

CLA assistant check
All committers have signed the CLA.

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

Successfully merging this pull request may close these issues.

2 participants