Build error, Can't open header file. What am I missing?
Posted: 20 Dec 2014 02:01
I'm new to MikroC Pro for 8051, and before I purchase it I just wanted to test some of my own basic code.
The included example codes, without header file references, do work perfectly. I want to use code created in Keil, with header files, in MikroC.
But when I Build projects, I receive "1 304 error: Can't open include file " 8051.h", and no Hex file is created.
(Same problem with reg51.h, reg52.h, several others.)
I have the header file listed in the Project Manager under Header Files.
The error message log contents are:
0 122 Compilation Started __Lib_Delays.c
418 123 Compiled Successfully __Lib_Delays.c
0 122 Compilation Started __Lib_GlcdFonts.c
496 123 Compiled Successfully __Lib_GlcdFonts.c
1 304 error: Can't open include file " 8051.h" #include< 8051.h> 1 error in preprocessor. C:\Documents and Settings\Ed.XPWS02\Desktop\BlinkLED5\BlinkLED5.c
0 122 Compilation Started BlinkLED5.c
2 325 Too many initializers BlinkLED5.c
0 102 Finished (with errors): 21 Dec 2014, 09:34:49 BlinkLED5.mcp51
Any guidance appreciated.
How can I correct this?
The included example codes, without header file references, do work perfectly. I want to use code created in Keil, with header files, in MikroC.
But when I Build projects, I receive "1 304 error: Can't open include file " 8051.h", and no Hex file is created.
(Same problem with reg51.h, reg52.h, several others.)
I have the header file listed in the Project Manager under Header Files.
The error message log contents are:
0 122 Compilation Started __Lib_Delays.c
418 123 Compiled Successfully __Lib_Delays.c
0 122 Compilation Started __Lib_GlcdFonts.c
496 123 Compiled Successfully __Lib_GlcdFonts.c
1 304 error: Can't open include file " 8051.h" #include< 8051.h> 1 error in preprocessor. C:\Documents and Settings\Ed.XPWS02\Desktop\BlinkLED5\BlinkLED5.c
0 122 Compilation Started BlinkLED5.c
2 325 Too many initializers BlinkLED5.c
0 102 Finished (with errors): 21 Dec 2014, 09:34:49 BlinkLED5.mcp51
Any guidance appreciated.
How can I correct this?