Results 1 to 5 of 5

Thread: Environment variables in project .includes?

  1. #1

    Default Environment variables in project .includes?

    How do I reference environment variables in my project's .includes file? For the environment variable "SDK" I've tied %SDK% and $SDK. How do I reference it?

  2. #2
    Join Date
    Jun 2007
    Location
    Massachusetts, USA
    Posts
    24
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Environment variables in project .includes?

    Try
    Qt Code:
    1. $$(var)
    To copy to clipboard, switch view to plain text mode 
    .

  3. #3

    Default Re: Environment variables in project .includes?

    That doesn't work either. This is what I tried:

    Qt Code:
    1. $$(CC_VC2010)/VC/atlmfc/include
    To copy to clipboard, switch view to plain text mode 

  4. #4
    Join Date
    Jun 2007
    Location
    Massachusetts, USA
    Posts
    24
    Thanks
    2
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Environment variables in project .includes?

    I added this to my .pro file:
    Qt Code:
    1. message(QTDIR %QTDIR% $QTDIR $$(QTDIR))
    To copy to clipboard, switch view to plain text mode 
    which resulted in this output:
    Qt Code:
    1. Project MESSAGE: QTDIR %QTDIR% $QTDIR C:/Qt/2009.03/qt
    To copy to clipboard, switch view to plain text mode 
    This shows $$(var) worked for me. Maybe I misunderstood what you mean by ".includes file".

  5. #5

    Default Re: Environment variables in project .includes?

    I don't know if it's different from a normal project. I have a file that was created with my makefile import project that is (projectname).includes which allows QT Creator to find directories used for code completion and syntax checking.

Similar Threads

  1. Translation tools problems
    By MarkoSan in forum Qt Tools
    Replies: 23
    Last Post: 22nd August 2010, 01:43
  2. Eclipse question
    By MarkoSan in forum General Discussion
    Replies: 5
    Last Post: 18th November 2008, 09:38
  3. problem with indexes
    By MarkoSan in forum Qt Programming
    Replies: 5
    Last Post: 10th December 2007, 15:55
  4. Accessing Environment Variables
    By mhoover in forum Qt Programming
    Replies: 6
    Last Post: 21st September 2006, 16:05

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.