This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Where is SdkDir defined?

Hello,

I run a project in SES 4.30c with nRF5 SDK. I just got my computer updated by our IT-department, and now I get a compilation error on my first #include :-) I still have all include directories in "Options - Code - Preprocessor - User Include Directories". The paths that start with "$(ProjectDir)" seem to work, but those that start with "$(SdkDir)" don't. I have been searching for where SdkDir is defined, but haven't found it. Can I check SdkDir, and change it? Where is it defined?

Best regards,
Lars

Parents
  • Hello Lars,

    'ProjectDir' is one of the predefined variables SES uses - it's set automatically based on the location of your *.emProject file. But "SdkDir" must be a user defined variable, and I guess it must have gotten deleted during the system update for some reason.

    You can define the "SdkDir" path in your project settings by adding it as a macro to the "common Solution" as shown below.

    Adding the macro by editing the *.emProject file

    <configuration
        Name="Debug"
        c_preprocessor_definitions="DEBUG; DEBUG_NRF"
        gcc_optimization_level="None" />
    <configuration
        Name="Common"
        macros="SdkDir=../nRF5_SDK_17.0.2" <-- Insert correct SDK path here
    </solution>

    Or through the SES UI

    Best regards,

    Vidar

  • Hello Vidar,

    Great, thanks! It solved the problem :-) But I discovered that it is important to use front-slash instead of back-slash (which I got when I copied the path from Windows explorer). And there must be no quotation mark around the path.

    Best regards,

    Lars

Reply Children
Related