RESOLVED WORKSFORME 38421
[Qt] Add an option to generate VC project files
https://bugs.webkit.org/show_bug.cgi?id=38421
Summary [Qt] Add an option to generate VC project files
Laszlo Gombos
Reported 2010-05-01 08:05:40 PDT
To improve life using VC with QtWebKit it would be beneficial to have an option to create VC project files instead of nmake Makefiles from .pro files. Simply passing "-t vc" option to qmake at top level (for WebKit.pro) does not seems to work as "-t vc" option does not seems to work for "subdirs" template (that is used by WebKit.pro).
Attachments
proposed change (3.28 KB, patch)
2010-05-01 08:38 PDT, Laszlo Gombos
no flags
Laszlo Gombos
Comment 1 2010-05-01 08:38:34 PDT
Created attachment 54853 [details] proposed change This solution should work from standalone QtWebKit builds as well. This generates individual VC project files for all binaries but does not (yet) enable autogenerating a "master" VC project file. The best way to take advantage of this patch is to open the generated QtLauncher project file and add jscore and QtWebKit projects to it manually (and define the dependencies) - works great for me.
Kenneth Rohde Christiansen
Comment 2 2010-05-01 08:46:10 PDT
(In reply to comment #0) > To improve life using VC with QtWebKit It this for Window or Symbian?
Simon Hausmann
Comment 3 2010-05-02 13:56:57 PDT
(In reply to comment #0) > To improve life using VC with QtWebKit it would be beneficial to have an option > to create VC project files instead of nmake Makefiles from .pro files. Simply > passing "-t vc" option to qmake at top level (for WebKit.pro) does not seems to > work as "-t vc" option does not seems to work for "subdirs" template (that is > used by WebKit.pro). I'm a little bit surprised by this. I admit that when I've built WebKit with VC in the past I've only done it from WebCore.pro, but in general qmake -tp vc should work with subdirs since vcsubdirs in generators/win32/msvc_project.cpp creates a VC solution (sln) file. In Qt for example we have projects.pro in the topleve that creates projects.sln, which loads all Qt subdirs (libraries, examples, tools, etc.) as one gigantic solution VC and allows building the entire beast :) So what was the problem you ran into when using qmake -tp vc?
Simon Hausmann
Comment 4 2010-05-02 13:57:22 PDT
(In reply to comment #2) > (In reply to comment #0) > > To improve life using VC with QtWebKit > > It this for Window or Symbian? This is for Windows only.
Laszlo Gombos
Comment 5 2010-05-03 07:06:36 PDT
webkit>qmake -r -t vc WebKit.pro Unable to generate makefile for: WebKit.pro I'm getting the same error with tests.pro, but WebCore.pro works. I agree it would be better to fix qmake if that is an option. My Qt version is 4.6.2.
Simon Hausmann
Comment 6 2010-05-03 07:46:51 PDT
(In reply to comment #5) > webkit>qmake -r -t vc WebKit.pro > Unable to generate makefile for: WebKit.pro > > I'm getting the same error with tests.pro, but WebCore.pro works. > > I agree it would be better to fix qmake if that is an option. My Qt version is > 4.6.2. Note the subtle but important difference: qmake -t vc versus qmake -tp vc ;) You want -tp to add vc as _prefix_ in front of all templates, so that subdirs becomes vcsubdirs.
Laszlo Gombos
Comment 7 2010-05-03 11:23:47 PDT
Comment on attachment 54853 [details] proposed change Simon, thanks for the help. Clearing r? flag as with the proper syntax this seems to work in qmake without changing the existing .pr* files. Keeping the bug open to see if special attention is needed for the scripts under WebKitTool/Scripts for VC support. Taking a second look, i think this part of the Qt documentation mislead me - http://doc.trolltech.com/4.6/qmake-variable-reference.html#template. It seems that vcsubdirs is missing from this list. How do we get that fixed ?
Simon Hausmann
Comment 8 2010-05-06 05:55:13 PDT
Qt commit 6629adee4741c3a72a83316671331ac996d046a5 extends the qmake docs for this :)
Note You need to log in before you can comment on or make changes to this bug.