WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
15006
webkitdirs.pm contains too much code duplication for Qt and Gtk related stuff
https://bugs.webkit.org/show_bug.cgi?id=15006
Summary
webkitdirs.pm contains too much code duplication for Qt and Gtk related stuff
Oleg Sukhodolsky
Reported
2007-08-19 07:28:09 PDT
buildQMakeGdkProject()/buildQMakeProject() are almost identical to each other. The same is treu for isQt() and isGdk().
Attachments
refactoring of webkitdirs.pm
(7.05 KB, patch)
2007-08-19 07:38 PDT
,
Oleg Sukhodolsky
darin
: review+
Details
Formatted Diff
Diff
the patch updated to feature branch
(6.31 KB, patch)
2007-10-10 08:57 PDT
,
Oleg Sukhodolsky
darin
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Oleg Sukhodolsky
Comment 1
2007-08-19 07:38:34 PDT
Created
attachment 16021
[details]
refactoring of webkitdirs.pm To make buildQMakeGdkProject()/buildQMakeQtProject() as similar as possible I've decided to only use "qmake" for build (before gtk port tried to use qmake-qt4 first). But since it is possible now to configure qmake which will be used with "--qmake" cli option, it should not be a big problem. Also I've decided to not place the check for directory ($project) for which build is called in common area since I see no advantages from this. Note, that I have not tested this with Qt build, freyther has agreed to do this for me (thanks in advance btw :)
George Staikos
Comment 2
2007-08-19 20:26:10 PDT
I'm a bit afraid that this will limit flexibility and I don't see a good reason why they should be using the exact same codepath.
Adam Treat
Comment 3
2007-08-19 20:37:16 PDT
Would probably be good to get rid of the whitespace changes. Also, I think this patch reverts 25146 that zecke said was necessary for those folks who don't build qt directly.... no?
Oleg Sukhodolsky
Comment 4
2007-08-19 23:08:56 PDT
(In reply to
comment #2
)
> I'm a bit afraid that this will limit flexibility and I don't see a good reason > why they should be using the exact same codepath.
For now the codepaths is similar and this is the motivation for this refactoring. And the current change doesn't mean that you can not change this in future :) So the patch is to express that NOW build process for Qt port is the same as for Gtk one.
Oleg Sukhodolsky
Comment 5
2007-08-19 23:12:35 PDT
(In reply to
comment #3
)
> Would probably be good to get rid of the whitespace changes. Also, I think > this patch reverts 25146 that zecke said was necessary for those folks who > don't build qt directly.... no?
as far as I understand 25146 is about passing debug/release to qmake. If so then the patch doesn't remove it.
Holger Freyther
Comment 6
2007-08-24 07:42:36 PDT
pmax: As of now it is (almost) the same code, you get flexibility through your --qmakearg command line parameter and if you really need to add Qt specific options that doesn't make sense for Gtk+ then we are always able to separate the implementations again. I have tested the patch and WebKit/Qt continued to compile here. I agree with the change as it strives for simplification and unification.
George Staikos
Comment 7
2007-08-24 13:51:22 PDT
This still doesn't answer what the reason for the change is besides an artificial desire to have to different things use the same function even though there is potential for them to need different behavior in the near future.
Oleg Sukhodolsky
Comment 8
2007-08-24 15:37:13 PDT
(In reply to
comment #7
)
> This still doesn't answer what the reason for the change is besides an > artificial desire to have to different things use the same function even though > there is potential for them to need different behavior in the near future.
I think most likely both builds have a lot of in common: they should be able to choose qmake binary (--qmake), set some common params, read params from command line (--qmakearg), handle WEBKIT_FULLBUILD, run qmake and checks its result, and, perhaps, something else. So, current patch it attempt to write this in the code. It might be not perfect but it is good enough for current situation. Also every time someone will add something to either Qt or Gtk build, (s)he will be forced (by code) to think about adding this to another build. Does this make sense for you?
Darin Adler
Comment 9
2007-10-04 09:06:54 PDT
Comment on
attachment 16021
[details]
refactoring of webkitdirs.pm Looks good. r=me
Oleg Sukhodolsky
Comment 10
2007-10-10 08:57:53 PDT
Created
attachment 16613
[details]
the patch updated to feature branch I have update the patch so it could be easily applied to feature branch. And tested it with gtk build.
Mark Rowe (bdash)
Comment 11
2007-10-14 04:52:27 PDT
Landed in
r26586
.
George Staikos
Comment 12
2007-10-14 09:16:29 PDT
Now that this patch has gone in, please stop changing the Qt build system. It is causing major headaches for me as I have to constantly merge changes on my side. If there is a need to change the gtk build system please do it without changing the Qt one, or at least don't check it in when the Qt developers give negative review.
Mark Rowe (bdash)
Comment 13
2007-10-14 13:57:20 PDT
To be fair, you didn't give a negative review, you said you didn't see a need for the change. Others disagreed and took the time to write and review a patch. How are we to know that a patch will cause merge troubles on your private branches unless you say as much?
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug