math.h does not work with -std=c89 or c90 or gnu90

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Low

      The attached test case is a simple program with two C files that each #include <math.h>.

      A minimal build works fine ...

      % tiarmclang -mcpu=cortex-m0 main.c test_func.c -Wl,-c
      

      Add the option -std=c89 ...

      % tiarmclang -mcpu=cortex-m0 -std=c89 main.c test_func.c -Wl,-c
      error: symbol "__fpclassify" redefined: first defined in
         "C:\Users\name\AppData\Local\Temp\main-732cf4.o"; redefined in
         "C:\Users\name\AppData\Local\Temp\test_func-179c46.o"
      error: symbol "__fpclassifyf" redefined: first defined in
         "C:\Users\name\AppData\Local\Temp\main-732cf4.o"; redefined in
         "C:\Users\name\AppData\Local\Temp\test_func-179c46.o"
      
      <Many similar errors skipped over>
      
      error: errors encountered during linking; "a.out" not built
      tiarmclang: error: tiarmlnk command failed with exit code 1 (use -v to see invocation)
      

      A similar result is seen with -std=c90 or -std=gnu90.

            Assignee:
            TI User
            Reporter:
            TI User
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

                Connection: Intermediate to External PROD System
                EXTSYNC-2902 - math.h does not work with -std=c89 ...
                SYNCHRONIZED
                • Last Sync Date: