Page 1 of 1

Support C99

Posted: Fri Jun 07, 2013 3:44 pm
by eugenskt
Hello,

Does Erika support C99?

When I use this cflag:

Code: Select all

CFLAGS = "-Xdialect-c99";
I get following errors:

Code: Select all

CC    eecfg.c
"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu_os.h", line 183: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200z7_resumeIRQ(EE_FREG msr)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu_os.h", line 196: error (etoa:4080): a storage class may not be specified here
  __asm static EE_FREG EE_e200z7_suspendIRQ(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu_os.h", line 216: error (etoa:4080): a storage class may not be specified here
  __asm static EE_FREG EE_e200z7_isIRQEnabled(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu_os.h", line 240: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200z7_switch_to_user_mode(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu_os.h", line 248: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200z7_switch_to_supervisor_mode(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\mcu/freescale_mpc5644a/inc/MPC5644A.h", line 1169: error (etoa:4618): struct or union declares no named members
              } B;
              ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\mcu/freescale_mpc5644a/inc/MPC5644A.h", line 3157: error (etoa:4618): struct or union declares no named members
                  } B;
                  ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\mcu/freescale_mpc5644a/inc/MPC5644A.h", line 3164: error (etoa:4618): struct or union declares no named members
                  } B;
                  ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\mcu/freescale_mpc5644a/inc/MPC5644A.h", line 3178: error (etoa:4618): struct or union declares no named members
                  } B;
                  ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 133: error (etoa:4080): a storage class may not be specified here
  __asm static EE_UREG EE_e200zx_get_tcr(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 139: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200zx_set_tcr(EE_UREG val)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 146: error (etoa:4080): a storage class may not be specified here
  __asm static EE_UREG EE_e200zx_get_tsr(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 152: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200zx_set_tsr(EE_UREG val)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 159: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200zx_set_dec(EE_UREG val)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 166: error (etoa:4080): a storage class may not be specified here
  __asm static void EE_e200zx_set_decar(EE_UREG val)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 173: error (etoa:4080): a storage class may not be specified here
  __asm static EE_UREG EE_e200zx_get_tbl(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 179: error (etoa:4080): a storage class may not be specified here
  __asm static EE_UREG EE_e200zx_get_pvr(void)
        ^

"D:\Erika\evidence\eclipse\plugins\COMEUE~4.201\ee_files\pkg\cpu/e200zx/inc/ee_cpu.h", line 446: error (etoa:4080): a storage class may not be specified here
  __asm static EE_UINT8 EE_as_raw_call_trusted_func(EE_UINT32 FunctionIndex,
        ^

18 errors detected in the compilation of "eecfg.c".
make: *** [obj/eecfg.o] Error 1
e.g. ee_cpu_os.h

Code: Select all

...
#ifdef	__DCC__
--> __asm static void EE_e200z7_resumeIRQ(EE_FREG msr) (line 183)
{
% reg msr
	mtmsr msr
...
}
Best regards, Eugen

Re: Support C99

Posted: Sat Jun 08, 2013 10:34 am
by paolo.gai
Well it seems it is the specific dialect of DCC on the way to specify asm static functions. What is the alternative naming respecting C99? (I do not have the compiler installed on my machine!)

PJ

Re: Support C99

Posted: Tue Jun 11, 2013 8:11 am
by eugenskt
Hi,

whatever reason, the this cflag enables the c++ compiler. "etoa" are the c++ compiler errors. Anyway, I think I will not need this flag anymore.
Thanks!

-Eugen