Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Forum Updated on Feb 6th

    MOC Compiler does not read Visual Studio Variables like $(ProjectName)

    Tools
    1
    1
    1333
    Loading More Posts
    • 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.
    • W
      wamo last edited by

      Hello i am having trouble to integrate the moc compiler of Qt 4.8 into visual studio 2010. The general idea about Visual Studio variables is to use them as often to make a better project code and reduce maintenance. Unfortunately the moc compiler does not read any of these variables. The result is that it may generate its files in wrong directories.
      .
      Example Project File:
      ARCHITECTURE_PATH = msw/vc/$${LITERAL_DOLLAR}(PlatformToolset)/$${LITERAL_DOLLAR}(PlatformName)/$${LITERAL_DOLLAR}(Configuration)
      .
      What should it generate? (To follow the VS rules)
      Win32 + Debug + VS2010 = msw/vc/v100/Win32/Debug
      Win64 + Release + VS2011 = msw/vc/v110/x64/Release
      .
      One Code to rule them (configurations) all !!! But sadly not with MOC :(
      .
      The result of the moc compiler will be everytime: "msw/vc" and nothing more. This means i have to generate a new line for each difference, because i cannot use these variables.
      .
      Any Idea how to solve this in a more smart way?

      1 Reply Last reply Reply Quote 0
      • First post
        Last post