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. How to change location of generated mocing files?
Forum Updated to NodeBB v4.3 + New Features

How to change location of generated mocing files?

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 719 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.
  • H Offline
    H Offline
    henryli
    wrote on last edited by
    #1

    Hi,

    I tried to migrate QT4 project to the latest version (QT5) and I am coming cross a problem.

    The generated mocing files always include "stdx.h" that is not in the file folder of generated files. The solution is I have to copy "std" to the target file folder. Is there way to change mocing settting so that the mocing file is generated automatically incude the as followings

    #include "../../stdafx.h"

    Instead of

    #include "stdafx.h"

    I am using VS2013 and converted the project to QT add-in project.

    Anyone can give me a hint?

    Thanks!

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      You can use -f option of MOC. I am not sure if that is doable using qmake.

      In any case, stdafx.h should be in your system environment, without any need to copy it anythere.

      You can also tell qmake to generate MOC files somewhere using MOC_DIR variable.

      (Z(:^

      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