Bug 17675 - Split WebCore.vcproj into Generic and CG-specific projects
Summary: Split WebCore.vcproj into Generic and CG-specific projects
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 523.x (Safari 3)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on: 17683
Blocks:
  Show dependency treegraph
 
Reported: 2008-03-04 17:01 PST by Brent Fulgham
Modified: 2008-03-09 13:28 PDT (History)
3 users (show)

See Also:


Attachments
Modify Project files (and add new project) (52.98 KB, patch)
2008-03-04 17:07 PST, Brent Fulgham
no flags Details | Formatted Diff | Diff
Revision 1 based on aroben's comments (42.02 KB, patch)
2008-03-04 17:46 PST, Brent Fulgham
no flags Details | Formatted Diff | Diff
Revision 2 based on arboen's comments (52.56 KB, patch)
2008-03-05 12:10 PST, Brent Fulgham
aroben: review-
Details | Formatted Diff | Diff
New Visual Studio property file (430 bytes, application/xml)
2008-03-05 12:11 PST, Brent Fulgham
no flags Details
Revision 3 based on aroben's comments. (52.12 KB, patch)
2008-03-05 15:55 PST, Brent Fulgham
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brent Fulgham 2008-03-04 17:01:09 PST
This is the first part of a series of changes to support Cairo (and perhaps other) forms of Windows-based WebKit builds.

The idea is to move the CoreGraphics-specific pieces of WebCore into a separate library which will be linked to WebKit.  This allows us to create a Cairo-specific library for WebCore, which can be linked to WebKit (instead of the CG-library) for users who wish to build with Cairo.
Comment 1 Brent Fulgham 2008-03-04 17:07:43 PST
Created attachment 19538 [details]
Modify Project files (and add new project)

Patch to break of CoreGraphics-specific portions of WebCore into a new WebCoreCG project, and updates to other project files as needed to support a correct build of WebKit.dll.
Comment 2 Adam Roben (:aroben) 2008-03-04 17:15:53 PST
Comment on attachment 19538 [details]
Modify Project files (and add new project)

In general I think this is a good direction for us to move in.

It looks like your new project file has the same post-build event as WebCore.vcproj (i.e., copying all of WebCore's headers into $WebKitOutputDir). How do we decide which project is responsible for copying which headers? Maybe WebCore.vcproj should be responsible for all headers?
Comment 3 Brent Fulgham 2008-03-04 17:46:52 PST
Created attachment 19540 [details]
Revision 1 based on aroben's comments

* Removed accidentally-copied post-build step from all targets.
* Removed accidental svn:execute bit on project file.
Comment 4 Adam Roben (:aroben) 2008-03-04 17:51:00 PST
Comment on attachment 19540 [details]
Revision 1 based on aroben's comments

Looks like this version adds WinLauncher.vcproj to WebKit.sln -- is that intentional?

What can we do to make sure WebCore.vcproj and WebCoreCG.vcproj always have the same preprocessor macros defined?
Comment 5 Brent Fulgham 2008-03-04 20:43:07 PST
(In reply to comment #4)
> (From update of attachment 19540 [details] [edit])
> Looks like this version adds WinLauncher.vcproj to WebKit.sln -- is that
> intentional?

I hadn't realized I left this in, but as I think about it -- I would like to leave it in.  I like being able to fire off WinLauncher to test stuff, and e-mail from other users indicate people are confused that it doesn't get built.

> What can we do to make sure WebCore.vcproj and WebCoreCG.vcproj always have the
> same preprocessor macros defined?

Hrm.  Good question; I was going to blithely comment that they share config.h, but of course you are talking about the defines in the project settings.  I'm not sure.

Comment 6 Brent Fulgham 2008-03-05 09:30:23 PST
(In reply to comment #5)
> (In reply to comment #4)
> > What can we do to make sure WebCore.vcproj and WebCoreCG.vcproj always
> > have the same preprocessor macros defined?
> 
> Hrm.  Good question; I was going to blithely comment that they share config.h,
> but of course you are talking about the defines in the project settings.  I'm
> not sure.

After pinging some knowledgeable Visual Studio people, I am told that there is no mechanical way to do so.

The only thing I can think of is to place things like this in a file like 'config.h' so that they are always included.

Otherwise, we have to manually keep them in sync, which is not much worse than the current situation with JavaScriptCore/WebCore/WebKit projects.

Comment 7 Adam Roben (:aroben) 2008-03-05 09:34:10 PST
(In reply to comment #6)
> (In reply to comment #5)
> > (In reply to comment #4)
> > > What can we do to make sure WebCore.vcproj and WebCoreCG.vcproj always
> > > have the same preprocessor macros defined?
> > 
> > Hrm.  Good question; I was going to blithely comment that they share config.h,
> > but of course you are talking about the defines in the project settings.  I'm
> > not sure.
> 
> After pinging some knowledgeable Visual Studio people, I am told that there is
> no mechanical way to do so.
> 
> The only thing I can think of is to place things like this in a file like
> 'config.h' so that they are always included.
> 
> Otherwise, we have to manually keep them in sync, which is not much worse than
> the current situation with JavaScriptCore/WebCore/WebKit projects.

Maybe we could make some more .vsprops files that only deal with the preprocessor macros?
Comment 8 Brent Fulgham 2008-03-05 12:10:21 PST
Created attachment 19552 [details]
Revision 2 based on arboen's comments

* Make use of webcore.vsprop file to hold preprocessor macros needed by WebCore and WebCoreCG.
Comment 9 Brent Fulgham 2008-03-05 12:11:29 PST
Created attachment 19553 [details]
New Visual Studio property file

New visual studio property file that holds common preprocessor defines needed in WebCore, WebCoreCG, and the forthcoming WebCoreCairo projects.
Comment 10 Adam Roben (:aroben) 2008-03-05 14:44:51 PST
Comment on attachment 19552 [details]
Revision 2 based on arboen's comments

I think we should put webcore.vsprops right next to WebCore.vcproj instead of beneath $WebKitLibrariesDir, since it's not being shared between projects outside of WebCore.

I think we should add WinLauncher to the solution in a separate patch.

Other than that, looks good!
Comment 11 Brent Fulgham 2008-03-05 15:55:37 PST
Created attachment 19562 [details]
Revision 3 based on aroben's comments.

* Reverted addition of WinLauncher from WebKit.sln.
* Moved webcore.vsprops to WebCore/WebCore.vcproj directory
* Updated references to webcore.vsprops to point to new location
Comment 12 Brent Fulgham 2008-03-05 15:56:14 PST
Comment on attachment 19553 [details]
New Visual Studio property file

Now part of main patch.
Comment 13 Brent Fulgham 2008-03-07 11:35:21 PST
sfalken reported (and I can confirm) that it *is* possible to exclude files based on project settings.  So this issue is effectively moot.

Closing as 'wontfix', since it's not needed.  See http://bugs.webkit.org/show_bug.cgi?id=17300 for the true solution.
Comment 14 Adam Roben (:aroben) 2008-03-09 13:28:31 PDT
Comment on attachment 19562 [details]
Revision 3 based on aroben's comments.

Clearing review flag to get this out of the review queue.