Discussion:
[PIC] MPLABX makefile weirdness on #include
Electron
2017-11-01 16:34:47 UTC
Permalink
Hello,
I am new to MPLABX (so far MPLAB v8.92 was all that I needed, but my
new project needs a PIC32 that is supported only in MPLABX), I've
struggled a bit but I start to appreciate the new IDE.
However, I've encountered a very annoying problem. In my C source I have
some #include depending on some #if conditions. MPLABX stops with the
makefile error "No rule to make target". A workaround is to clean the
project every time before a new (Debug so far) build, but it's very
annoying. I've tried a lot of things, adding the file into the IDE's
project Source and/or Header Files, and other attemps, but they all
failed.
One thing is for sure, if I "manually" (i.e. copy and paste) include
the files, instead of using #include, the problem disappears. But can't
MPLABX stop bothering and let me use the preprocessor the way I want?
If I want to conditionally #include a file, that's a preprocessor thing,
it shouldn't interfere the way it does.
Could you suggest me a fix to make it behave the way I wish? Thank you.
MPLABX version is the latest (v4.01).

Kind regards,
Mario
--
http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive
View/change your membership options at
http://mailman.mit.edu/mailman/listinfo/piclist
Loading...