• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. Error about Environment Variable settings

Stats

  • Locked Locked
  • Replies 17
  • Subscribers 143
  • Views 23434
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Error about Environment Variable settings

wgtkan
wgtkan over 6 years ago

Hello,

After doing an update to the new pdk I get the following error. I think It comes from my .csinit file. It is asking about the EV variable of GF_PDK_HOME not being set.

And many other errors that come from the .cdsinit.

Please see attached.

Thank you always.

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 6 years ago

    Haven't you answered your own question? It sounds as if it's expecting the UNIX $GF_PDK_HOME to be set to the location of the PDK (I assume). Because that's not set, the SKILL variable gfPdkHome is nil, which results in all those SKILL errors.

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • wgtkan
    wgtkan over 6 years ago in reply to Andrew Beckett

    Hello Andrew,

    Thank you for your prompt response.  I have set the environment variable and still coming up with an error.

    I have attached my .cdsinit and the new error screen shot.

    Thank you always for your help. my_cdsinit.docx

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • mbracht
    mbracht over 6 years ago in reply to wgtkan

    Well I might be wrong but in your .cdsinit it says:

    if(gfPdkHome = getShellEnvVar("/home/grps/ef-test/GLF8HP/130HPSIGE-8HP/")

    ...shouldn't that be getShellEnvVar("GF_PDK_HOME")

    Looks to me like you were confusing variable name and value.
    And what do you get when you type  getShellEnvVar("GF_PDK_HOME")  in the CIW ?

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • wgtkan
    wgtkan over 6 years ago in reply to mbracht

    I get nil.

    I am not familar with the skill language. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 6 years ago in reply to wgtkan

    I suspect you modified the .cdsinit file and changed the getShellEnvVar() line to have the full path rather than "GF_PDK_HOME". I think you may also have set the line that follows it - the strcat.

    If it had getShellVarVar("GF_PDK_HOME") in the .cdsinit code, you would have needed to do:

    setenv GF_PDK_HOME /path/to/wherever

    or 

    export GF_PDK_HOME=/path/to/wherever

    (first is for csh, second for ksh/bash) before you started virtuoso.

    Then the getShellEnvVar would get the path from the UNIX environment variable.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • mbracht
    mbracht over 6 years ago in reply to wgtkan

    well - it means the GF_PDK_HOME env variable is not set which is exactly your problem.
    Try:

    setShellEnvVar("GF_PDK_HOME=/home/grps/ef-test/GLF8HP/130HPSIGE-8HP/")

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • wgtkan
    wgtkan over 6 years ago in reply to Andrew Beckett

    I am using bash and I am still getting the same error. export GF_PDK_HOME=/GLF8HP/130HPSIGE-8HP/V1.8_1.1HP/ and i am putting it above the if statement and still getting the same error. What do you adsvise?

    Thanks a lot.

    Andrew Beckett said:
    export GF_PDK_HOME=/path/to/wherever
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • mbracht
    mbracht over 6 years ago in reply to wgtkan

    What Andrew meant is to set it on the Unix shell - before you launch virtuoso. That way the env variable is then inherited by virtuoso. The setShellEnvVar is a SKILL command which you need to put in your .cdsinit.
    What I don't understand is that after the export command in the bash you don't see that env variable in virtuoso. You do the export GF...=...  before you launch virtuoso don't you?

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • wgtkan
    wgtkan over 6 years ago in reply to Andrew Beckett

    I want to put the envirnonemt variable in my .cdsinit file. I did:

    setShellEnvVar("GF_PDK_HOME=/home/grps/ef-test/GLF8HP/130HPSIGE-8HP/")

    And in CIW when do:   getShellEnvVar("GF_PDK_HOME") It still comes back nil

    I am getting the same error messages as before. I don't know what I am doing wrong.

    Thank you so much. I am attaching the copy of my .cdsinit file again.

    Fullscreen cdsint.txt Download
    if(gfPdkHome = getShellEnvVar("GF_PDK_HOME=/home/grps/ef-test/GLF8HP/130HPSIGE-8HP/") then
      printf("ENV variable GF_PDK_HOME set to %s\n" gfPdkHome)
      ibmPdkPath = strcat(gfPdkHome "/../../")
    else
      warn("ENV variable GF_PDK_HOME variable not set!")
      warn("GF_PDK_HOME must be set to top level PDK directory")
      warn("PDK procedures and libraries will not be loaded!")
    )
    
    cond(
      ( index(getVersion() "6.1")
        loadContext(strcat(gfPdkHome "/DesignEnv/VirtuosoOA/context/ibmPdkProcs610.cxt"))
        hiRegTimer("ibmPdkInit()" 1))
      ( t
        warn("ibmPdkProcs file not loaded. Only version IC6.1.x supported.\n"))
    );cond
    
    load(strcat(gfPdkHome "/DesignEnv/VirtuosoOA/setup/ibmPdkBindkeys.il"))
    ;Uncomment below for CDS-type bindkeys
    ;load(strcat(gfPdkHome "/DesignEnv/ViruosoOA/setup/ibmPdkBindkeysCDS.il"))
      
    ; simulation and model library setup
    setShellEnvVar("CDS_Netlisting_Mode=Analog")
    setShellEnvVar("CDS_AUTO_64BIT=ALL")
    cdsSetNetlistMode()
      
    envSetVal("spectre.envOpts" "modelFiles" 'string
      strcat(
        gfPdkHome "/Models/Spectre/models/design.scs "
        gfPdkHome "/Models/Spectre/models/allModels.scs")
    )
    envSetVal("spectre.envOpts" "includePath" 'string strcat(gfPdkHome "/Models/Spectre/models"))
    
    envSetVal("hspice.envOpts" "modelFiles" 'string
      strcat(
        gfPdkHome "/Models/HSPICE/models/design.inv "
        gfPdkHome "/Models/HSPICE/models/allModels.inc")
    )  
    
    ; Load Calibre SKILL interface if environment var is set
    mgc_home = getShellEnvVar("MGC_HOME")
    if( mgc_home && isDir(mgc_home) && isReadable(mgc_home) then
      ; Load calibre.skl for Cadence versions 4.4 and greater
      load(strcat(mgc_home "/shared/pkgs/icv/tools/queryskl/calibre.skl"))
    else
      ; MGC_HOME is not set
      printf("Calibre SKILL interface not loaded.\n")
    )
    ; End of Calibre SKILL interface
    

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 6 years ago in reply to wgtkan

    Please pay careful attention to what we're saying. You changed the first line to:

    if(gfPdkHome = getShellEnvVar("GF_PDK_HOME=/home/grps/ef-test/GLF8HP/130HPSIGE-8HP/") then

    You're mixing the setShellEnvVar with getShellEnvVar - the getShellEnvVar call you've specified makes no sense.

    This should be:

    if(gfPdkHome = getShellEnvVar("GF_PDK_HOME") then

    I suggest you either set GF_PDK_HOME before you start virtuoso as mentioned before, or add another line before the lines above:

    setShellEnvVar("GF_PDK_HOME=/home/grps/ef-test/GLF8HP/130HPSIGE-8HP/")

    That will set it, and then the getShellEnvVar("GF_PDK_HOME") will get the variable value.

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
>

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information