Test version : sdcc-2.8.0-rc2b-setup.exe
Define inclide xx.h as below (using for yy.c)
extern void (* P1032E)(void);
Define source xx.c as below
include "xx.h"
extern void (* P1032E)(void);
Build cmd: sdcc -mmcs51 --model-large -I"C:\Program Files\SDCC\include\mcs51" -c xx.c
Error message:
xx.C:29: error 91: extern definition for 'P1032E' mismatches with declaration.
xx.H:35: error 177: previously defined here
Try modify:
// extern void (* P1032E)(void); //modify as below
extern (* P1032E)(void); //test is ok !!!
Compatible issue:
I have try the include xx.h "extern void (* P1032E)(void);" code ok for the Borland C, Keil C, ...
Logged In: YES
user_id=1784716
Originator: YES
It is ok for that Build cmd: sdcc -mmcs51 -I"C:\Program
Files\SDCC\include\mcs51" -c xx.c
So args "--model-large" have bug for the mcs51 mode.
Logged In: YES
user_id=1784716
Originator: YES
It is ok for that Build cmd: sdcc -mmcs51 -I"C:\Program
Files\SDCC\include\mcs51" -c xx.c
So args "--model-large" have bug for the mcs51 mode.
Logged In: YES
user_id=568035
Originator: NO
The bug already existed in SDCC 2.7.0 and 2.6.0, so I don't consider it as a SDCC 2.8.0 release show stopper.
Borut
Fixed in SDCC 2.9.7 #5898.