He reinstalado todo de nuevo. Al intentar compilar ahora me pasa esto:
Parece que no encuentra el fichero de cabecera 18f26k20.h
¿ como le indico donde está??
make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf
make[1]: Entering directory 'C:/Users/Lenovo M92p/MPLABXProjects/test.X'
make -f nbproject/Makefile-default.mk dist/default/production/test.X.production.hex
make[2]: Entering directory 'C:/Users/Lenovo M92p/MPLABXProjects/test.X'
gnumkdir -p build/default/production
gnumkdir -p dist/default/production
"C:\PROGRA~2\PICC\CCSCON.exe" out="build/default/production" newfile.c +FH +DF +CC +Y=9 +EA +DF +LN +T +A +M +J +EA +Z -P #__18F26K20=1
make[2]: *** [build/default/production/newfile.o] Error 1
make[1]: *** [.build-conf] Error 2
make: *** [.build-impl] Error 2
C:\Users\Lenovo M92p\MPLABXProjects\test.X\newfile.c:1:8: Error#18 File can not be opened
Not in ";\18f26k20.h"
Not in local "18f26k20.h"
Not in local "C:\Users\Lenovo M92p\MPLABXProjects\test.X\18f26k20.h"
Not in last "18f26k20.h"
Not in project "C:\Users\Lenovo M92p\MPLABXProjects\test.X\18f26k20.h"
C:\Users\Lenovo M92p\MPLABXProjects\test.X\newfile.c:2:9: Error#128 A #DEVICE required before this line
C:\Users\Lenovo M92p\MPLABXProjects\test.X\newfile.c:3:7: Error#128 A #DEVICE required before this line
C:\Users\Lenovo M92p\MPLABXProjects\test.X\newfile.c:6:2: Error#128 A #DEVICE required before this line
C:\Users\Lenovo M92p\MPLABXProjects\test.X\newfile.c:6:33: Error#28 Expecting an identifier Bad SFR name
C:\Users\Lenovo M92p\MPLABXProjects\test.X\newfile.c:7:2: Error#12 Undefined identifier
6 Errors, 0 Warnings.
Build Failed.
nbproject/Makefile-default.mk:111: recipe for target 'build/default/production/newfile.o' failed
make[2]: Leaving directory 'C:/Users/Lenovo M92p/MPLABXProjects/test.X'
nbproject/Makefile-default.mk:90: recipe for target '.build-conf' failed
make[1]: Leaving directory 'C:/Users/Lenovo M92p/MPLABXProjects/test.X'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
BUILD FAILED (exit value 2, total time: 390ms)