Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QtCreator: Build environment variables from script? ...
Forum Updated to NodeBB v4.3 + New Features

QtCreator: Build environment variables from script? ...

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 317 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    idlefrog
    wrote on 9 Nov 2021, 10:35 last edited by
    #1

    I have various versions of the same project, each has it's own unique set of environment variables.

    Is there a way to just point the build to a 'environment variable' script?

    Or do I have to shutdown QtCreator, set the environment, and then re-launch QtCreator from the new environment each time I want to change version?! Surely not! There must be a better way!

    I've searched high and low to find a solution but alas have advanced no further.
    Is there anyone out there with a easy solution?

    J 1 Reply Last reply 9 Nov 2021, 10:40
    0
    • I idlefrog
      9 Nov 2021, 10:35

      I have various versions of the same project, each has it's own unique set of environment variables.

      Is there a way to just point the build to a 'environment variable' script?

      Or do I have to shutdown QtCreator, set the environment, and then re-launch QtCreator from the new environment each time I want to change version?! Surely not! There must be a better way!

      I've searched high and low to find a solution but alas have advanced no further.
      Is there anyone out there with a easy solution?

      J Offline
      J Offline
      jsulm
      Lifetime Qt Champion
      wrote on 9 Nov 2021, 10:40 last edited by
      #2

      @idlefrog What you can do is to go to Build Environment in QtCreator and click on "Batch Edit..." there you can put all your environment vartiables at once.

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      I 1 Reply Last reply 9 Nov 2021, 11:05
      1
      • J jsulm
        9 Nov 2021, 10:40

        @idlefrog What you can do is to go to Build Environment in QtCreator and click on "Batch Edit..." there you can put all your environment vartiables at once.

        I Offline
        I Offline
        idlefrog
        wrote on 9 Nov 2021, 11:05 last edited by idlefrog 11 Sept 2021, 11:10
        #3

        @jsulm Didn't notice that option. It's a possibility, thanks.
        I have a bash file scripts that set only 40 variables for each project version. Although, I don't want to have to do that for every project version. e.g. v1.03.51r, v2.0.5b, and so on..

        Many thanks @jsulm ...looks like that's as good an option I'm going to find, although I may just create QtCreator launch scripts for each version. e.g. qt_launch_v1.03r.sh qt_launch_v2.0b.sh

        I appreciate your help!

        1 Reply Last reply
        0

        1/3

        9 Nov 2021, 10:35

        • Login

        • Login or register to search.
        1 out of 3
        • First post
          1/3
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved