-
Notifications
You must be signed in to change notification settings - Fork 70
Open
Description
Issue
The template offers good support for C projects and attempts to include C++ projects as well.
Unfortunately, when using C++ files, the rules.mk fails to include C++ standard library -lstdc++ which can result in undefined reference to various objects.
Fix
You can add a few lines to rules.mk to check for CXXFILES and add the -lstdc++ if necessary.
Example Fix
100 100 LDLIBS += -Wl,--start-group -lc -lgcc -lnosys -Wl,--end-group
101 101
102 + ifneq ($(strip $(CXXFILES)),)
103 + LDLIBS += -lstdc++
104 + endif
105 +
102 106 # Burn in legacy hell fortran modula pascal yacc idontevenwat
Metadata
Metadata
Assignees
Labels
No labels