Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Qmake producing win solution with absolute path
Forum Updated to NodeBB v4.3 + New Features

Qmake producing win solution with absolute path

Scheduled Pinned Locked Moved Qt Creator and other tools
5 Posts 3 Posters 2.9k 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.
  • D Offline
    D Offline
    DavidCasper
    wrote on last edited by
    #1

    I am using qmake to generate a windows solution file. It is doing this, but the solution (.sln) file is containing absolute paths on the machine it was generated rather than relative paths. How do I stop it doing this, they need to be relative paths.

    My .pro is very simple:
    @
    TEMPLATE=subdirs
    include(system.pri)

    The .pri just contains entries like this:
    SUBDIRS += ntv4/example/ntv4init/ntv4init.pro
    SUBDIRS += ntv4/example/ntv4burn/ntv4burn.pro
    @
    But the solution contains:
    @
    Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ntv4init", "D:/work/d61dd4c5a2fb0db2/sdk/ntv4/example/ntv4init\ntv4init.vcproj", "{6594B07E-B513-3EB3-B693-157195F096A0}"
    EndProject
    Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ntv4burn", "D:/work/d61dd4c5a2fb0db2/sdk/ntv4/example/ntv4burn\ntv4burn.vcproj", "{6632FA0D-A904-36CB-A18E-64543ADE2AF2}"
    EndProject
    @
    Help would be appreciated.....
    David

    [code tags added, koahnig]

    1 Reply Last reply
    0
    • M Offline
      M Offline
      Muby
      wrote on last edited by
      #2

      Ive got the same problem anyo got idea ?

      Thanks

      1 Reply Last reply
      0
      • D Offline
        D Offline
        DavidCasper
        wrote on last edited by
        #3

        What I did in the end was write a little C++ program that went in there and cleaned up the paths. (You could use perl or python, etc) My program also put in the dependencies which I couldn't seem to force qmake to produce. However, word of caution, unlike the vcproj files which are XML, the sln files are really pure text files which are extremely sensitive to whitespace. If you mess with the fille you must get the line endings and whitespace exactly right in the new file you make. Good Luck Muby

        1 Reply Last reply
        0
        • M Offline
          M Offline
          Muby
          wrote on last edited by
          #4

          Thx for you tooltip David, but I really need to get an answer from QT, because, it was working on my computer before and one day, it became absolute path. It's very strange, and I need to understand.

          Hope to get more help from QT developper.

          Thx

          R 1 Reply Last reply
          0
          • M Muby

            Thx for you tooltip David, but I really need to get an answer from QT, because, it was working on my computer before and one day, it became absolute path. It's very strange, and I need to understand.

            Hope to get more help from QT developper.

            Thx

            R Offline
            R Offline
            Rimon Chen
            wrote on last edited by
            #5

            @Muby just read the source files in src/qtbase/qmake and modify what you want, and re-compile the qmake.exe

            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