Skip to main content
Guido Körber
Associate III
January 29, 2018
Question

AC6 assembly .ifdef not working?

  • January 29, 2018
  • 4 replies
  • 942 views
Posted on January 29, 2018 at 16:35

Seems like no matter what I try the .ifdef does not work. It always takes the default path.

This happens with a symbol defined in the make settings as well as with symbols defined in any other way, including .equ and .set

    This topic has been closed for replies.

    4 replies

    Andrew Neil
    Super User
    January 29, 2018
    Posted on January 29, 2018 at 18:56

    Have you tried the specific AC6 forum?

    http://www.openstm32.org/forum7

     
    A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
    Tesla DeLorean
    Guru
    January 29, 2018
    Posted on January 29, 2018 at 19:00

    Try looking at the .LST and .MAP type files to check if the symbols your want are visible. I'd inspect the .OBJ (.O) files too, some command line stuff usually gets in them.

    Try using the GNU/GAS outside of AC6 make sure it is not something specific to the chain, or makefile, etc.

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    Guido Körber
    Associate III
    January 30, 2018
    Posted on January 30, 2018 at 14:51

    This happens with symbols visible in the .map file as well as some not visible there. I even tried using a label that I used for memory access a few lines down in the code. Same result, .ifdef used the default path and the memory access worked.

    Guido Körber
    Associate III
    February 1, 2018
    Posted on February 01, 2018 at 15:33

    Problem solved. When using '.S' as file type the C pre processor goes through the file. That way I moved the defines and ifdefs to the C pre processor.