Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Specify in a .pro file that the generated Makefile should run an command?

Specify in a .pro file that the generated Makefile should run an command?

Scheduled Pinned Locked Moved QML and Qt Quick
3 Posts 3 Posters 1.9k Views
  • 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.
  • S Offline
    S Offline
    stefh
    wrote on last edited by
    #1

    Hi,

    the application I want to make depends on a header file (say version.h)
    that is generated by a command line tool (say genversion.sh)

    So I'd like the Makefile that is generated by 'qmake' to contain something like this:

    @ ($TARGET): version.h ...
    ...

    version.h:
         genversion.sh@
    

    Question: how to specify this in my .pro file?
    I could add an exec(getversion.sh) in the .pro file, but then getversion.sh is
    only called the first time when calling 'qmake', instead of during each 'make'

    Thx, br,
    Stef

    1 Reply Last reply
    0
    • L Offline
      L Offline
      lgeyer
      wrote on last edited by
      #2

      See QMAKE_EXTRA_TARGETS / QMAKE_EXTRA_COMPILERS and PRE_TARGETDEPS.

      1 Reply Last reply
      0
      • L Offline
        L Offline
        luca
        wrote on last edited by
        #3

        Check if this "thread":https://developer.qt.nokia.com/forums/viewthread/7537/ can help you...

        1 Reply Last reply
        0

        • Login

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