[gtk/msvcproj-git: 12/18] generate-msvc.mak: Add rules to copy the static VS2010 projects




commit d21115cb90cc48fd3faa11d475eed43c89ad1d16
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Thu Aug 4 12:56:53 2022 +0800

    generate-msvc.mak: Add rules to copy the static VS2010 projects
    
    ... for VS2012~2022, so that they can be ready for use to build with later
    Visual Studio versions.

 win32/config-msvc.mak.in | 27 +++++++++++++++++++++++
 win32/generate-msvc.mak  | 56 ++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 83 insertions(+)
---
diff --git a/win32/config-msvc.mak.in b/win32/config-msvc.mak.in
index 0ca74c24ac..88e5245673 100644
--- a/win32/config-msvc.mak.in
+++ b/win32/config-msvc.mak.in
@@ -127,6 +127,33 @@ GTK_PREPROCESSOR_FLAGS =   \
         /DGDK_DISABLE_DEPRECATED       \
         /DISOLATION_AWARE_ENABLED
 
+GTK3_VS10_STATIC_PROJS =       \
+       vs10\gtk+.sln   \
+       vs10\gtk-builder-tool.vcxproj   \
+       vs10\gtk-encode-symbolic-svg.vcxproj    \
+       vs10\gtk-query-settings.vcxproj \
+       vs10\gtk-update-icon-cache.vcxproj      \
+       vs10\gtk3-demo-application.vcxproj      \
+       vs10\gtk3-icon-browser.vcxproj  \
+       vs10\gtk3-install.vcxproj       \
+       vs10\gtk3-introspect.vcxproj    \
+       vs10\gtk3-prebuild.vcxproj      \
+       vs10\gtk3-widget-factory.vcxproj        \
+       vs10\gtk-builder-tool.vcxproj.filters   \
+       vs10\gtk-encode-symbolic-svg.vcxproj.filters    \
+       vs10\gtk-query-settings.vcxproj.filters \
+       vs10\gtk-update-icon-cache.vcxproj.filters      \
+       vs10\gtk3-demo-application.vcxproj.filters      \
+       vs10\gtk3-icon-browser.vcxproj.filters  \
+       vs10\gtk3-widget-factory.vcxproj.filters
+
+GTK3_VS11_STATIC_PROJS = $(GTK3_VS10_STATIC_PROJS:vs10\=vs11\)
+GTK3_VS12_STATIC_PROJS = $(GTK3_VS10_STATIC_PROJS:vs10\=vs12\)
+GTK3_VS14_STATIC_PROJS = $(GTK3_VS10_STATIC_PROJS:vs10\=vs14\)
+GTK3_VS15_STATIC_PROJS = $(GTK3_VS10_STATIC_PROJS:vs10\=vs15\)
+GTK3_VS16_STATIC_PROJS = $(GTK3_VS10_STATIC_PROJS:vs10\=vs16\)
+GTK3_VS17_STATIC_PROJS = $(GTK3_VS10_STATIC_PROJS:vs10\=vs17\)
+
 GDK_VS9_PROJ = gdk-3.vcproj
 GDK_VS1X_PROJ = $(GDK_VS9_PROJ:.vcproj=.vcxproj)
 GDK_VS1X_PROJ_FILTERS = $(GDK_VS9_PROJ:.vcproj=.vcxproj.filters)
diff --git a/win32/generate-msvc.mak b/win32/generate-msvc.mak
index f412ee8563..0984d94592 100644
--- a/win32/generate-msvc.mak
+++ b/win32/generate-msvc.mak
@@ -619,6 +619,62 @@ vs9\$(DEMO_VS9_PROJ) vs10\$(DEMO_VS1X_PROJ):
        @echo Copying $< to $@...
        @copy $< $@
 
+{vs10\}.sln{vs11\}.sln:
+       @echo Copying and updating $< for VS2012...
+       @$(PYTHON) replace.py -a=replace-str -i=$< -o=$@.tmp    \
+       --instring="Format Version 11.00" --outstring="Format Version 12.00"
+       @$(PYTHON) replace.py -a=replace-str -i=$@.tmp -o=$@    \
+       --instring="# Visual Studio 2010" --outstring="# Visual Studio 2012"
+       @del $@.tmp
+
+{vs10\}.sln{vs12\}.sln:
+       @echo Copying and updating $< for VS2013...
+       @$(PYTHON) replace.py -a=replace-str -i=$< -o=$@.tmp    \
+       --instring="Format Version 11.00" --outstring="Format Version 12.00"
+       @$(PYTHON) replace.py -a=replace-str -i=$@.tmp -o=$@    \
+       --instring="# Visual Studio 2010" --outstring="# Visual Studio 2013"
+       @del $@.tmp
+
+{vs10\}.sln{vs14\}.sln:
+       @echo Copying and updating $< for VS2015...
+       @$(PYTHON) replace.py -a=replace-str -i=$< -o=$@.tmp    \
+       --instring="Format Version 11.00" --outstring="Format Version 12.00"
+       @$(PYTHON) replace.py -a=replace-str -i=$@.tmp -o=$@    \
+       --instring="# Visual Studio 2010" --outstring="# Visual Studio 14"
+       @del $@.tmp
+
+{vs10\}.sln{vs15\}.sln:
+       @echo Copying and updating $< for VS2017...
+       @$(PYTHON) replace.py -a=replace-str -i=$< -o=$@.tmp    \
+       --instring="Format Version 11.00" --outstring="Format Version 12.00"
+       @$(PYTHON) replace.py -a=replace-str -i=$@.tmp -o=$@    \
+       --instring="# Visual Studio 2010" --outstring="# Visual Studio 15"
+       @del $@.tmp
+
+{vs10\}.sln{vs16\}.sln:
+       @echo Copying and updating $< for VS2019...
+       @$(PYTHON) replace.py -a=replace-str -i=$< -o=$@.tmp    \
+       --instring="Format Version 11.00" --outstring="Format Version 12.00"
+       @$(PYTHON) replace.py -a=replace-str -i=$@.tmp -o=$@    \
+       --instring="# Visual Studio 2010" --outstring="# Visual Studio 16"
+       @del $@.tmp
+
+{vs10\}.sln{vs17\}.sln:
+       @echo Copying and updating $< for VS2022...
+       @$(PYTHON) replace.py -a=replace-str -i=$< -o=$@.tmp    \
+       --instring="Format Version 11.00" --outstring="Format Version 12.00"
+       @$(PYTHON) replace.py -a=replace-str -i=$@.tmp -o=$@    \
+       --instring="# Visual Studio 2010" --outstring="# Visual Studio 17"
+       @del $@.tmp
+
+copy-update-static-projects:   \
+$(GTK3_VS11_STATIC_PROJS)      \
+$(GTK3_VS12_STATIC_PROJS)      \
+$(GTK3_VS14_STATIC_PROJS)      \
+$(GTK3_VS15_STATIC_PROJS)      \
+$(GTK3_VS16_STATIC_PROJS)      \
+$(GTK3_VS17_STATIC_PROJS)
+
 .\vs$(VSVER)\$(CFG)\$(PLAT)\bin\de.gresource.xml: ..\gtk\emoji\gresource.xml.in
 .\vs$(VSVER)\$(CFG)\$(PLAT)\bin\es.gresource.xml: ..\gtk\emoji\gresource.xml.in
 .\vs$(VSVER)\$(CFG)\$(PLAT)\bin\fr.gresource.xml: ..\gtk\emoji\gresource.xml.in


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]