Hi!
Please add a "-D option flag" for the gcc call, to check/detect the RAM size of MCU.
e.g.: On arduino uno: -DRAMSIZE=2048 maximum_data_size=2048
Best regards