[gtk/msvcproj-demos: 1/7] MSVC Projects: Rename Makefile variable




commit 3292e9d67bd0f85f31a49e34eda1242845a7474f
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Thu May 26 16:53:34 2022 +0800

    MSVC Projects: Rename Makefile variable
    
    Use VS1X instead of VS10 in the variable names in the NMake Makefiles,
    since the VS2010 MSBuild Visual Studio project files really apply to all Visual
    Studio versions at or after VS2010.
    
    Also use variable substitution here to ease future maintenance.

 win32/config-msvc.mak.in |  4 ++--
 win32/generate-msvc.mak  | 30 +++++++++++++++---------------
 2 files changed, 17 insertions(+), 17 deletions(-)
---
diff --git a/win32/config-msvc.mak.in b/win32/config-msvc.mak.in
index c39d7170b0..26ab2186ba 100644
--- a/win32/config-msvc.mak.in
+++ b/win32/config-msvc.mak.in
@@ -120,8 +120,8 @@ GTK_PREPROCESSOR_FLAGS =    \
         /DISOLATION_AWARE_ENABLED
 
 DEMO_VS9_PROJ = gtk3-demo.vcproj
-DEMO_VS10_PROJ = gtk3-demo.vcxproj
-DEMO_VS10_PROJ_FILTERS = gtk3-demo.vcxproj.filters
+DEMO_VS1X_PROJ = $(DEMO_VS9_PROJ:.vcproj=.vcxproj)
+DEMO_VS1X_PROJ_FILTERS = $(DEMO_VS9_PROJ:.vcproj=.vcxproj.filters)
 DEMO_DEP_LIBS_NEW_PANGO=harfbuzz.lib
 DEMO_DEP_LIBS_PANGOFT2_VS1X=pangoft2-1.0.lib;harfbuzz.lib;freetype.lib
 DEMO_DEP_LIBS_PANGOFT2_VS9=$(DEMO_DEP_LIBS_PANGOFT2_VS1X:;= )
diff --git a/win32/generate-msvc.mak b/win32/generate-msvc.mak
index b4f5a69f93..4c6eb8d217 100644
--- a/win32/generate-msvc.mak
+++ b/win32/generate-msvc.mak
@@ -271,34 +271,34 @@ regenerate-demos-h-win32: ..\demos\gtk-demo\geninclude.py $(demo_actual_sources)
        @$(PYTHON) geninclude.py demos.h.win32 $(demo_sources)
        @cd ..\..\win32
        @echo Regenerating gtk3-demo VS project files...
-       @-del vs9\$(DEMO_VS9_PROJ) vs10\$(DEMO_VS10_PROJ) vs10\$(DEMO_VS10_PROJ_FILTERS)
+       @-del vs9\$(DEMO_VS9_PROJ) vs10\$(DEMO_VS1X_PROJ) vs10\$(DEMO_VS1X_PROJ_FILTERS)
        @for %%s in ($(demo_sources) gtkfishbowl.c main.c) do   \
        @echo.   ^<File RelativePath^="..\..\demos\gtk-demo\%%s" /^>>>gtk3-demo.sourcefiles & \
        @echo.   ^<ClCompile Include^="..\..\demos\gtk-demo\%%s" /^>>>gtk3-demo.vs10.sourcefiles & \
        @echo.   ^<ClCompile Include^="..\..\demos\gtk-demo\%%s"^>^<Filter^>Source 
Files^</Filter^>^</ClCompile^>>>gtk3-demo.vs10.sourcefiles.filters
        @$(CPP) /nologo /EP /I. vs9\$(DEMO_VS9_PROJ)in>$(DEMO_VS9_PROJ).tmp
        @for /f "usebackq tokens=* delims=" %%l in ($(DEMO_VS9_PROJ).tmp) do @echo %%l>>$(DEMO_VS9_PROJ).tmp1
-       @$(CPP) /nologo /EP /I. vs10\$(DEMO_VS10_PROJ)in>$(DEMO_VS10_PROJ).tmp
-       @for /f "usebackq tokens=* delims=" %%l in ($(DEMO_VS10_PROJ).tmp) do @echo 
%%l>>$(DEMO_VS10_PROJ).tmp1
-       @$(CPP) /nologo /EP /I. vs10\$(DEMO_VS10_PROJ_FILTERS)in> $(DEMO_VS10_PROJ_FILTERS).tmp
-       @for /f "usebackq tokens=* delims=" %%l in ($(DEMO_VS10_PROJ_FILTERS).tmp) do @ echo 
%%l>>vs10\$(DEMO_VS10_PROJ_FILTERS)
+       @$(CPP) /nologo /EP /I. vs10\$(DEMO_VS1X_PROJ)in>$(DEMO_VS1X_PROJ).tmp
+       @for /f "usebackq tokens=* delims=" %%l in ($(DEMO_VS1X_PROJ).tmp) do @echo 
%%l>>$(DEMO_VS1X_PROJ).tmp1
+       @$(CPP) /nologo /EP /I. vs10\$(DEMO_VS1X_PROJ_FILTERS)in> $(DEMO_VS1X_PROJ_FILTERS).tmp
+       @for /f "usebackq tokens=* delims=" %%l in ($(DEMO_VS1X_PROJ_FILTERS).tmp) do @ echo 
%%l>>vs10\$(DEMO_VS1X_PROJ_FILTERS)
        @if not "$(FONT_FEATURES_DEMO)" == ""   \
         if not "$(FONT_FEATURES_USE_PANGOFT2)" == ""   \
         ($(PYTHON) replace.py -a=replace-str -i=$(DEMO_VS9_PROJ).tmp1 -o=vs9\$(DEMO_VS9_PROJ) 
--instring="AdditionalDependencies=\"\"" 
--outstring="AdditionalDependencies=\"$(DEMO_DEP_LIBS_PANGOFT2_VS9)\"") & \
-        ($(PYTHON) replace.py -a=replace-str -i=$(DEMO_VS10_PROJ).tmp1 -o=vs10\$(DEMO_VS10_PROJ) 
--instring=">%(AdditionalDependencies)<" 
--outstring=">$(DEMO_DEP_LIBS_PANGOFT2_VS1X);%(AdditionalDependencies)<")
+        ($(PYTHON) replace.py -a=replace-str -i=$(DEMO_VS1X_PROJ).tmp1 -o=vs10\$(DEMO_VS1X_PROJ) 
--instring=">%(AdditionalDependencies)<" 
--outstring=">$(DEMO_DEP_LIBS_PANGOFT2_VS1X);%(AdditionalDependencies)<")
        @if not "$(FONT_FEATURES_DEMO)" == ""   \
         if "$(FONT_FEATURES_USE_PANGOFT2)" == ""       \
         ($(PYTHON) replace.py -a=replace-str -i=$(DEMO_VS9_PROJ).tmp1 -o=vs9\$(DEMO_VS9_PROJ) 
--instring="AdditionalDependencies=\"\"" --outstring="AdditionalDependencies=\"$(DEMO_DEP_LIBS_NEW_PANGO)\"") 
& \
-        ($(PYTHON) replace.py -a=replace-str -i=$(DEMO_VS10_PROJ).tmp1 -o=vs10\$(DEMO_VS10_PROJ) 
--instring=">%(AdditionalDependencies)<" --outstring=">$(DEMO_DEP_LIBS_NEW_PANGO);%(AdditionalDependencies)<")
-       @if "$(FONT_FEATURES_DEMO)" == "" copy $(DEMO_VS9_PROJ).tmp1 vs9\$(DEMO_VS9_PROJ) & copy 
$(DEMO_VS10_PROJ).tmp1 vs10\$(DEMO_VS10_PROJ)
+        ($(PYTHON) replace.py -a=replace-str -i=$(DEMO_VS1X_PROJ).tmp1 -o=vs10\$(DEMO_VS1X_PROJ) 
--instring=">%(AdditionalDependencies)<" --outstring=">$(DEMO_DEP_LIBS_NEW_PANGO);%(AdditionalDependencies)<")
+       @if "$(FONT_FEATURES_DEMO)" == "" copy $(DEMO_VS9_PROJ).tmp1 vs9\$(DEMO_VS9_PROJ) & copy 
$(DEMO_VS1X_PROJ).tmp1 vs10\$(DEMO_VS1X_PROJ)
        @del *vc*proj*.tmp* gtk3-demo.*sourcefiles*
-       @for %%v in (11 12 14 15 16 17) do @(copy /y vs10\$(DEMO_VS10_PROJ_FILTERS) vs%v\ & del 
vs%v\gtk3-demo.vcxproj)
-       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS10_PROJ) -o=vs11\$(DEMO_VS10_PROJ) 
--instring=">v100<" --outstring=">v110<"
-       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS10_PROJ) -o=vs12\$(DEMO_VS10_PROJ) 
--instring=">v100<" --outstring=">v120<"
-       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS10_PROJ) -o=vs14\$(DEMO_VS10_PROJ) 
--instring=">v100<" --outstring=">v140<"
-       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS10_PROJ) -o=vs15\$(DEMO_VS10_PROJ) 
--instring=">v100<" --outstring=">v141<"
-       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS10_PROJ) -o=vs16\$(DEMO_VS10_PROJ) 
--instring=">v100<" --outstring=">v142<"
-       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS10_PROJ) -o=vs17\$(DEMO_VS10_PROJ) 
--instring=">v100<" --outstring=">v143<"
+       @for %%v in (11 12 14 15 16 17) do @(copy /y vs10\$(DEMO_VS1X_PROJ_FILTERS) vs%v\ & del 
vs%v\gtk3-demo.vcxproj)
+       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS1X_PROJ) -o=vs11\$(DEMO_VS1X_PROJ) 
--instring=">v100<" --outstring=">v110<"
+       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS1X_PROJ) -o=vs12\$(DEMO_VS1X_PROJ) 
--instring=">v100<" --outstring=">v120<"
+       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS1X_PROJ) -o=vs14\$(DEMO_VS1X_PROJ) 
--instring=">v100<" --outstring=">v140<"
+       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS1X_PROJ) -o=vs15\$(DEMO_VS1X_PROJ) 
--instring=">v100<" --outstring=">v141<"
+       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS1X_PROJ) -o=vs16\$(DEMO_VS1X_PROJ) 
--instring=">v100<" --outstring=">v142<"
+       @$(PYTHON) replace.py -a=replace-str -i=vs10\$(DEMO_VS1X_PROJ) -o=vs17\$(DEMO_VS1X_PROJ) 
--instring=">v100<" --outstring=">v143<"
 
 # Remove the generated files
 clean:


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