Hot!MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler

Author
aschen0866
Super Member
  • Total Posts : 4355
  • Reward points : 0
  • Joined: 2006/01/08 22:18:32
  • Location: San Diego
  • Status: offline
2018/07/07 12:46:18 (permalink)
0

MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler

The generated make file uses -mcpu=$(MP_PROCESSOR_OPTION) to specify the processor type. However, XC8 v2.00 doesn't seem to recognize this option, hence giving error

(902) no chip name specified; use "PICC --CHIPINFO" to see available chip names

If the same project  built within MPLABX v4.15, which still uses the old --chip=$(MP_PROCESSOR_OPTION), then the project builds successfully with v2.00.
 
Is this a IDE/compiler bug or am I missing anything in the project settings?
 
#1

5 Replies Related Threads

    davekw7x
    Entropy++
    • Total Posts : 1504
    • Reward points : 0
    • Joined: 2012/01/16 12:01:07
    • Location: Left Coast, USA
    • Status: offline
    Re: MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler 2018/07/08 00:43:47 (permalink)
    +6 (6)
    aschen0866
    ...error
     
    (902) no chip name specified; use "PICC --CHIPINFO" to see available chip names
     
     



    I get this error when it is using xc8 rather than xc8-cc.  (That's xc8.exe, xc8-cc.exe for Windows users)
    Go to Tools->Options->Embedded->Build Tools and look at the Compiler and Assembler settings for XC8 (v2.00).  If they are for xc8, change them to xc8-cc.  (You might try clicking the "Remove" button for XC8 (v2.00) and then clicking the "Scan for Build Tools" to see if it will come up with xc8-cc on its own.  If not, make the changes manually.)
     
    You may have to change the Standard setting in the Project->XC8 Global Options box to C90 and back to c99 to see the effect of the new setting when you re-compile.  (Maybe even exit the IDE and restart.)
     
    Bottom line: Once I got it to use xc8-cc, things went smoothly.
     
    Regards,

    Dave
    post edited by davekw7x - 2018/07/08 01:02:52

    Sometimes I just can't help myself...
    #2
    aschen0866
    Super Member
    • Total Posts : 4355
    • Reward points : 0
    • Joined: 2006/01/08 22:18:32
    • Location: San Diego
    • Status: offline
    Re: MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler 2018/07/08 06:49:58 (permalink)
    0
    davekw7x
     
    Go to Tools->Options->Embedded->Build Tools and look at the Compiler and Assembler settings for XC8 (v2.00).  If they are for xc8, change them to xc8-cc.  ...


    Thanks. That fixes the problem.
    #3
    Antonio_2706
    Starting Member
    • Total Posts : 68
    • Reward points : 0
    • Joined: 2016/07/07 06:45:37
    • Location: 0
    • Status: offline
    Re: MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler 2018/08/15 09:14:46 (permalink)
    0
    Hello Guys, 
    I have the same problem 
     
    I manage to change the XC8 with XC8-cc. I have also closed and restart. I still have the problem
     
    However i can not do this  Project->XC8 Global Options box to C90 and back to c99 to see the effect of the new setting when you re-compile.  (Maybe even exit the IDE and restart.)
     
    Thank you for your help 
    Cordially 
    Antonio 
    #4
    mbrowning
    Just a Member
    • Total Posts : 1073
    • Reward points : 0
    • Joined: 2005/03/16 14:32:56
    • Location: Melbourne, FL
    • Status: online
    Re: MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler 2018/08/15 10:48:17 (permalink)
    +2 (2)
    Antonio_2706
    However i can not do this  Project->XC8 Global Options box to C90 and back to c99 to see the effect of the new setting when you re-compile.  (Maybe even exit the IDE and restart.)

    Which version of MPLAB-X are you using? Prior to 4.20 this option box isn't available.
     

    Go Navy! Beat Army!
    #5
    Antonio_2706
    Starting Member
    • Total Posts : 68
    • Reward points : 0
    • Joined: 2016/07/07 06:45:37
    • Location: 0
    • Status: offline
    Re: MPLABX v4.20 + XC8 v2.00: -mcpu option doesn't seem to be recognized by the compiler 2018/08/16 01:42:43 (permalink)
    0
    Hello I am using 5.0 too and It works now I changed from 99 to 90. 
     
    Thanks 
    Antonio 
    #6
    Jump to:
    © 2018 APG vNext Commercial Version 4.5