After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 721617 - Improve on How the MSVC Project Files are Generated
Improve on How the MSVC Project Files are Generated
Status: RESOLVED FIXED
Product: gdk-pixbuf
Classification: Platform
Component: general
git master
Other All
: Normal normal
: ---
Assigned To: gdk-pixbuf-maint
gdk-pixbuf-maint
Depends on:
Blocks:
 
 
Reported: 2014-01-06 09:55 UTC by Fan, Chun-wei
Modified: 2015-09-17 01:45 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Use Python to generate the Visual C++ Projects (26.98 KB, patch)
2014-01-06 09:59 UTC, Fan, Chun-wei
none Details | Review
Build: Add Autotools Module used to Generate the full Project Files from the Templates (5.53 KB, patch)
2015-09-16 14:16 UTC, Fan, Chun-wei
committed Details | Review
Build: Clean Up Visual Studio Projects Generation (13.96 KB, patch)
2015-09-16 14:19 UTC, Fan, Chun-wei
committed Details | Review

Description Fan, Chun-wei 2014-01-06 09:55:57 UTC
Hi,

The current approach used (dating back to the time when Tor maintained the Windows port) uses autotools scripts to generate the Visual C++ projects for building the GDK-Pixbuf DLL.  While this would work, it would have the following disadvantages:

-They can add clutter to the autotools files, especially when there are multiple
 parts to a project.
-A bash-style shell+automake is required to test any changes made here, which is 
 hard to obtain on Windows (as one needs to install GTK-Doc, which is pretty hard 
 on Windows), and is not that easy to maintain, and there needs to  be filters to 
 filter out platform-specific code (usually *nix code) that won't work on Windows.

So, I think it might be a good idea to switch to Python to read the autotools files to get the necessary source to be built on Windows/MSVC, which:

-Makes everything needed for the creation of Visual C++ project files go under 
 build, removing clutter from the main Makefile.am's
-This can be run on Windows with a standard Python 2.x/3.x installation, and can 
 still be quite easily invoked for 'make dist'.  This does add a Python dependency
 for 'make dist', but AFAIK it would be okay as normally the intropsection files
 will be built as well (which is a Python 2.6+ script).
-More easily maintained and tested, due to the above reason.
Comment 1 Fan, Chun-wei 2014-01-06 09:59:15 UTC
Created attachment 265423 [details] [review]
Use Python to generate the Visual C++ Projects

Hi,

Here's my patch to update the method to generate the Visual C++ build files.  This also makes the listing of "installation" of headers done automatically with the Python scripts (and hence 'make dist').

With blessings, thank you!
Comment 2 Fan, Chun-wei 2015-09-16 14:16:43 UTC
Created attachment 311459 [details] [review]
Build: Add Autotools Module used to Generate the full Project Files from the Templates

Hi,

This adds a common autotools module that can be included by gdk-pixbuf/Makefile.am which can be used to generate the full project files from the templates, which:

-Helps to clean up that Makefile.am a bit.
-Enables make -jN dist to work.
Comment 3 Fan, Chun-wei 2015-09-16 14:19:41 UTC
Created attachment 311461 [details] [review]
Build: Clean Up Visual Studio Projects Generation

Hi,

This makes use of the autotools module (in attachment 311459 [details] [review]), so that the autotools files are cleaned up a bit, with the ability to do 'make -jN dist'.  Another advantage to this is that the list of headers is also handled automatically during 'make dist', so that the headers "installation" would be less prone to breakage during a development cycle.

With blessings, thank you!
Comment 4 Ignacio Casal Quinteiro (nacho) 2015-09-16 20:54:49 UTC
Review of attachment 311459 [details] [review]:

On this file I really miss a comment pointing to the main project i.e glib to keep it in sync... Apart from that sure go ahead.
Comment 5 Ignacio Casal Quinteiro (nacho) 2015-09-16 20:55:30 UTC
Review of attachment 311461 [details] [review]:

Sure push it. You are the maintainer anyway.
Comment 6 Ignacio Casal Quinteiro (nacho) 2015-09-16 20:55:55 UTC
Review of attachment 311461 [details] [review]:

Maybe fix the commit message to have your real name and email.
Comment 7 Fan, Chun-wei 2015-09-17 01:44:56 UTC
Hi Nacho,

Thanks for reviewing the items here, I have pushed the patches as follows:
-Attachment 311459 [details] (With comment pointing to GLib added): 2f5b3a4
-Attachment 311461 [details] (With name and e-mail corrected): 03cdbb9

I also removed the stale items that were superseded by the commits in this bug, in 65ec7f3.

Sorry, I forgot to add the bug link to attachment 311461 [details] [review].

With blessings, thank you!