[glibmm/glibmm-2-64] NMake Makefiles: Clean up building tests and examples



commit b08a8dd556e6dcc3ed1970ec684ad1ddeb9dd364
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Tue Jun 16 11:00:15 2020 +0800

    NMake Makefiles: Clean up building tests and examples
    
    Instead of hand-written rules, just make use of what we have to generate the
    rules on the fly for most of the tests and examples, since the rules are more
    or less the same for each of the test and example programs.  We only need to
    single-out the ones that aren't buildable under Windows and those that have
    multiple programs under each directory, as opposed to one example/test program
    per directory.
    
    Even for those directories that have multiple example programs, we can pretty
    easily generate the rules for them.
    
    Also remove repeated parts that were added by accident.
    
    This can shrink the NMake Makefiles by a bit.

 MSVC_NMake/Makefile.vc           |  15 ++--
 MSVC_NMake/build-rules-msvc.mak  | 149 ++-------------------------------------
 MSVC_NMake/create-lists-msvc.mak |  46 ++++--------
 MSVC_NMake/generate-msvc.mak     |   2 +-
 4 files changed, 29 insertions(+), 183 deletions(-)
---
diff --git a/MSVC_NMake/Makefile.vc b/MSVC_NMake/Makefile.vc
index 7eeba8f2..2a431e83 100644
--- a/MSVC_NMake/Makefile.vc
+++ b/MSVC_NMake/Makefile.vc
@@ -29,17 +29,22 @@ VALID_MSC = TRUE
 
 !if "$(VALID_MSC)" == "TRUE"
 
-# Include the Makefile portion to convert the source and header lists
-# into the lists we need for compilation and introspection
-!include create-lists-msvc.mak
 
 !ifdef GENERATE_VERSIONED_FILES
 !include pkg-ver.mak
 !endif
 
-all: $(GIOMM_LIB) $(GLIBMM_EXTRA_DEFS_GEN_LIB) $(glibmm_ex) $(giomm_ex) all-build-info
+all: $(GIOMM_LIB) $(GLIBMM_EXTRA_DEFS_GEN_LIB) examples all-build-info
+
+# Include the Makefile portion to convert the source and header lists
+# into the lists we need for compilation and introspection
+!include create-lists-msvc.mak
+
+examples: $(glibmm_examples) vs$(VSVER)\$(CFG)\$(PLAT)\gschema.compiled
 
-tests: $(glibmm_tests) $(giomm_tests) all-build-info
+tests: $(glibmm_tests) all-build-info
+       @echo To run the tests, note the test program executables correspond to the
+       @echo various directories in ^$(srcroot)/tests in vs$(VSVER)\$(CFG)\$(PLAT).
 
 # Include the build rules for sources, DLLs and executables
 !include generate-msvc.mak
diff --git a/MSVC_NMake/build-rules-msvc.mak b/MSVC_NMake/build-rules-msvc.mak
index 3b3d836e..5b281b8f 100644
--- a/MSVC_NMake/build-rules-msvc.mak
+++ b/MSVC_NMake/build-rules-msvc.mak
@@ -113,136 +113,7 @@ $(giomm_OBJS)
 # <<
 #      @-if exist $@.manifest mt /manifest $@.manifest /outputresource:$@;1
 
-# For the buildable glibmm examples
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-compose.exe: ..\examples\compose\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-dispatcher2.exe: ..\examples\thread\dispatcher2.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-keyfile.exe: ..\examples\keyfile\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-markup.exe: ..\examples\markup\parser.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-options.exe: ..\examples\options\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-properties.exe: ..\examples\properties\properties_example.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-regex.exe: ..\examples\regex\main.cc $(GLIBMM_LIB)
-
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-compose.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-dispatcher2.exe    \
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-keyfile.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-markup.exe \
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-options.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-properties.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex-regex.exe:
-       @if not exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex $(MAKE) -f Makefile.vc CFG=$(CFG) 
vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex
-       $(CXX) $(GLIBMM_EX_CFLAGS) $(CFLAGS) /Fo$(@D)\glibmm-ex\ /Fd$(@D)\glibmm-ex\ $** /link $(LDFLAGS) 
$(GLIBMM_EX_LIBS) /out:$@
-
-# For the buildable giomm examples
-
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-dbus-client_bus_listnames.exe: ..\examples\dbus\client_bus_listnames.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-dbus-session_bus_service.exe: ..\examples\dbus\session_bus_service.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-dbus-server_without_bus.exe: ..\examples\dbus\server_without_bus.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-network-resolver.exe: ..\examples\network\resolver.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-network-socket-client.exe: ..\examples\network\socket-client.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-network-socket-server.exe: ..\examples\network\socket-server.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-settings.exe: ..\examples\settings\settings.cc $(GIOMM_LIB)
-
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-dbus-client_bus_listnames.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-dbus-session_bus_service.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-dbus-server_without_bus.exe \
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-network-resolver.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-network-socket-client.exe   \
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-network-socket-server.exe   \
-vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-settings.exe:
-       @if not exist vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex $(MAKE) -f Makefile.vc CFG=$(CFG) 
vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex
-       @if "$@" == "vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex-settings.exe" $(MAKE) -f Makefile.vc CFG=$(CFG) 
vs$(VSVER)\$(CFG)\$(PLAT)\gschema.compiled
-       $(CXX) $(GIOMM_EX_CFLAGS) $(CFLAGS) /Fo$(@D)\giomm-ex\ /Fd$(@D)\giomm-ex\ $** /link $(LDFLAGS) 
$(GIOMM_EX_LIBS) /out:$@
-
-# For building the glibmm tests
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_base64.exe: ..\tests\glibmm_base64\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_binding.exe: ..\tests\glibmm_binding\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_bool_arrayhandle.exe: ..\tests\glibmm_bool_arrayhandle\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_bool_vector.exe: ..\tests\glibmm_bool_vector\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_btree.exe: ..\tests\glibmm_btree\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_buildfilename.exe: ..\tests\glibmm_buildfilename\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_bytearray.exe: ..\tests\glibmm_bytearray\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_date.exe: ..\tests\glibmm_date\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_mainloop.exe: ..\tests\glibmm_mainloop\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_nodetree.exe: ..\tests\glibmm_nodetree\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_object.exe: ..\tests\glibmm_object\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_objectbase.exe: ..\tests\glibmm_objectbase\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_objectbase_move.exe: ..\tests\glibmm_objectbase_move\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_object_move.exe: ..\tests\glibmm_object_move\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_refptr.exe: ..\tests\glibmm_refptr\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_refptr_sigc_bind.exe: ..\tests\glibmm_refptr_sigc_bind\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_compose.exe: ..\tests\glibmm_ustring_compose\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_format.exe: ..\tests\glibmm_ustring_format\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_make_valid.exe: ..\tests\glibmm_ustring_make_valid\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_sprintf.exe: ..\tests\glibmm_ustring_sprintf\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_value.exe: ..\tests\glibmm_value\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_valuearray.exe: ..\tests\glibmm_valuearray\main.cc $(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_variant.exe: ..\tests\glibmm_variant\main.cc $(GLIBMM_LIB)
-
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_base64.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_binding.exe      \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_bool_arrayhandle.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_bool_vector.exe  \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_btree.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_buildfilename.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_bytearray.exe    \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_date.exe \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_interface_move.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_mainloop.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_nodetree.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_object.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_objectbase.exe   \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_objectbase_move.exe      \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_object_move.exe  \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_refptr.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_refptr_sigc_bind.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_compose.exe      \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_format.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_make_valid.exe   \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_ustring_sprintf.exe      \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_value.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_valuearray.exe   \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_variant.exe:
-       @if not exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests $(MAKE) -f Makefile.vc CFG=$(CFG) 
vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests
-       $(CXX) $(GLIBMM_EX_CFLAGS) $(CFLAGS) /Fo$(@D)\glibmm-tests\ /Fd$(@D)\glibmm-tests\ $** /link 
$(LDFLAGS) $(GLIBMM_EX_LIBS) /out:$@
-
-# For giomm tests
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_asyncresult_sourceobject.exe: 
..\tests\giomm_asyncresult_sourceobject\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_ioerror.exe: ..\tests\giomm_ioerror\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_ioerror_and_iodbuserror.exe: 
..\tests\giomm_ioerror_and_iodbuserror\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_listmodel.exe: ..\tests\giomm_listmodel\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_memoryinputstream.exe: ..\tests\giomm_memoryinputstream\main.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_simple.exe: ..\tests\giomm_simple\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_stream_vfuncs.exe: ..\tests\giomm_stream_vfuncs\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_tls_client.exe: ..\tests\giomm_tls_client\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_interface_implementation.exe: 
..\tests\glibmm_interface_implementation\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_null_containerhandle.exe: ..\tests\glibmm_null_containerhandle\main.cc 
$(GLIBMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_null_vectorutils.exe: ..\tests\glibmm_null_vectorutils\main.cc 
$(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_vector.exe: ..\tests\glibmm_vector\main.cc $(GIOMM_LIB)
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_weakref.exe: ..\tests\glibmm_weakref\main.cc $(GLIBMM_LIB)
-
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_asyncresult_sourceobject.exe      \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_ioerror.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_ioerror_and_iodbuserror.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_listmodel.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_memoryinputstream.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_simple.exe        \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_stream_vfuncs.exe \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-giomm_tls_client.exe    \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_interface_implementation.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_null_containerhandle.exe \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_null_vectorutils.exe     \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_vector.exe       \
-vs$(VSVER)\$(CFG)\$(PLAT)\test-glibmm_weakref.exe:
-       @if not exist vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests $(MAKE) -f Makefile.vc CFG=$(CFG) 
vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests
-       $(CXX) $(GIOMM_EX_CFLAGS) $(CFLAGS) /Fo$(@D)\giomm-tests\ /Fd$(@D)\giomm-tests\ $** /link $(LDFLAGS) 
$(GIOMM_EX_LIBS) /out:$@
-
 clean:
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.exe
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.dll
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.pdb
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.ilk
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.exp
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.lib
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.exe
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.dll
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.pdb
@@ -251,38 +122,30 @@ clean:
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\*.lib
        @-del ..\tools\generate_wrap_init.pl
        @-del ..\tools\gmmproc
+       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests del /f /q 
vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests\*.obj
+       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests del /f /q 
vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests\*.pdb
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\gschemas.compiled
+       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-examples\*.obj
+       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-examples\*.pdb
        @-del vs$(VSVER)\$(CFG)\$(PLAT)\glib-extra-defs-gen\*.pdb
        @-del vs$(VSVER)\$(CFG)\$(PLAT)\glib-extra-defs-gen\*.obj
-       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests\*.obj
-       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests\*.pdb
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex\*.obj
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex\*.pdb
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\*.def
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\*.res
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\*.obj
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\*.pdb
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\*.cc
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\private\*.h
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\giomm\*.h
-       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests del /f /q 
vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests\*.obj
-       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests del /f /q 
vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests\*.pdb
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex\*.obj
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex\*.pdb
-       @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\*.def
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\*.res
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\*.obj
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\*.pdb
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\*.cc
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\private\*.h
        @-del /f /q vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\*.h
-       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests rd vs$(VSVER)\$(CFG)\$(PLAT)\giomm-tests
+       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests rd vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests
+       @-rd vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-examples
        @-rd vs$(VSVER)\$(CFG)\$(PLAT)\glib-extra-defs-gen
-       @-rd vs$(VSVER)\$(CFG)\$(PLAT)\giomm-ex
        @-rd vs$(VSVER)\$(CFG)\$(PLAT)\giomm\private
        @-rd vs$(VSVER)\$(CFG)\$(PLAT)\giomm
-       @-if exist vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests rd vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-tests
-       @-rd vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-ex
        @-rd vs$(VSVER)\$(CFG)\$(PLAT)\glibmm\private
        @-rd vs$(VSVER)\$(CFG)\$(PLAT)\glibmm
 
diff --git a/MSVC_NMake/create-lists-msvc.mak b/MSVC_NMake/create-lists-msvc.mak
index b0ce441c..6731eb2c 100644
--- a/MSVC_NMake/create-lists-msvc.mak
+++ b/MSVC_NMake/create-lists-msvc.mak
@@ -93,58 +93,36 @@ glibmm_files_extra_ph_int = $(glibmm_files_extra_ph:/=\)
 !if [call create-lists.bat footer glibmm.mak]
 !endif
 
-!if [call create-lists.bat header glibmm.mak glibmm_ex]
-!endif
-
-# We skip building the following examples:
-# child_watch, iochannel_stream: Builds on *NIX only
-# thread\dispatcher.cc: Not C++-17 compliant
-!if [for %e in (compose dispatcher2 keyfile markup options properties regex) do @call create-lists.bat file 
glibmm.mak vs^$(VSVER)\^$(CFG)\^$(PLAT)\glibmm-ex-%e.exe]
-!endif
-
-!if [call create-lists.bat footer glibmm.mak]
-!endif
-
-!if [call create-lists.bat header glibmm.mak giomm_ex]
-!endif
-
-!if [for %e in (resolver socket-client socket-server) do @call create-lists.bat file glibmm.mak 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\giomm-ex-network-%e.exe]
-!endif
-
-!if [for %e in (settings) do @call create-lists.bat file glibmm.mak 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\giomm-ex-%e.exe]
-!endif
-
-!if [for %e in (client_bus_listnames session_bus_service server_without_bus) do @call create-lists.bat file 
glibmm.mak vs^$(VSVER)\^$(CFG)\^$(PLAT)\giomm-ex-dbus-%e.exe]
+!if [for %d in ($(PREFIX)) do @echo PREFIX_REAL=%~dpnd>>glibmm.mak]
 !endif
 
-!if [call create-lists.bat footer glibmm.mak]
+!if [echo.>>glibmm.mak]
 !endif
 
-!if [call create-lists.bat header glibmm.mak glibmm_tests]
+# We skip building the following examples/tests:
+# child_watch, iochannel_stream: Builds on *NIX only
+!if [for %d in (examples tests) do @call create-lists.bat header glibmm.mak glibmm_%d & @(for /f %t in ('dir 
/ad /b ..\%d') do @if not "%t" == "child_watch" if not "%t" == "dbus" if not "%t" == "iochannel_stream" if 
not "%t" == "network" if not "%t" == "thread" call create-lists.bat file glibmm.mak 
vs$(VSVER)\$(CFG)\$(PLAT)\%t.exe) & @call create-lists.bat footer glibmm.mak]
 !endif
 
-# Skip the following:
-# glibmm_interface_implementation, glibmm_null_vectorutils, glibmm_vector: Are actually using giomm
-# glibmm_interface_move: Relies on g_autoptr_*()
-!if [for /f %d in ('dir /ad /b ..\tests\glibmm_*') do @if not "%d" == "glibmm_interface_implementation" if 
not "%d" == "glibmm_interface_move" if not "%d" == "glibmm_null_vectorutils" if not "%d" == "glibmm_vector" 
@call create-lists.bat file glibmm.mak vs^$(VSVER)\^$(CFG)\^$(PLAT)\test-%d.exe]
+!if [for %t in (dbus network thread) do @for %s in (..\examples\%t\*.cc) do @echo glibmm_examples = 
^$(glibmm_examples) vs^$(VSVER)\^$(CFG)\^$(PLAT)\%~ns.exe>>glibmm.mak]
 !endif
 
-!if [call create-lists.bat footer glibmm.mak]
+!if [echo.>>glibmm.mak]
 !endif
 
-!if [call create-lists.bat header glibmm.mak giomm_tests]
+!if [for %d in (examples tests) do @for /f %t in ('dir /ad /b ..\%d') do @if not "%t" == "child_watch" if 
not "%t" == "dbus" if not "%t" == "iochannel_stream" if not "%t" == "network" if not "%t" == "thread" for %s 
in (..\%d\%t\*.cc) do @echo vs^$(VSVER)\^$(CFG)\^$(PLAT)\glibmm-%d\%t-%~ns.obj: %s>>glibmm.mak & @echo. if 
not exist ^$(@D)\ md ^$(@D)>>glibmm.mak & @echo.     ^$(CXX) ^$(GLIBMM_EX_CFLAGS) ^$(CFLAGS) 
/Fo^$(@D)\%t-%~ns.obj /Fd^$(@D)\ ^$** /c>>glibmm.mak & @echo.>>glibmm.mak]
 !endif
 
-!if [for /f %d in ('dir /ad /b ..\tests\giomm_*') do @call create-lists.bat file glibmm.mak 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\test-%d.exe]
+!if [for %t in (dbus network thread) do @for %s in (..\examples\%t\*.cc) do @echo 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\glibmm-examples\%t-%~ns.obj: %s>>glibmm.mak & @echo. if not exist ^$(@D)\ md 
^$(@D)>>glibmm.mak & @echo.        ^$(CXX) ^$(GLIBMM_EX_CFLAGS) ^$(CFLAGS) /Fo^$(@D)\%t-%~ns.obj /Fd^$(@D)\ 
^$** /c>>glibmm.mak & @echo.>>glibmm.mak]
 !endif
 
-!if [for %d in (interface_implementation null_vectorutils vector) do @call create-lists.bat file glibmm.mak 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\test-glibmm_%d.exe]
+!if [for %d in (examples tests) do @for /f %t in ('dir /ad /b ..\%d') do @if not "%t" == "child_watch" if 
not "%t" == "dbus" if not "%t" == "iochannel_stream" if not "%t" == "network" if not "%t" == "thread" call 
create-lists.bat header glibmm.mak %t_OBJS & @(for %s in (..\%d\%t\*.cc) do @call create-lists.bat file 
glibmm.mak vs$(VSVER)\$(CFG)\$(PLAT)\glibmm-%d\%t-%~ns.obj) & @call create-lists.bat footer glibmm.mak]
 !endif
 
-!if [call create-lists.bat footer glibmm.mak]
+!if [for %d in (examples tests) do @for /f %t in ('dir /ad /b ..\%d') do @if not "%t" == "child_watch" if 
not "%t" == "dbus" if not "%t" == "iochannel_stream" if not "%t" == "network" if not "%t" == "thread" echo 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\%t.exe: ^$(GIOMM_LIB) ^$(GLIBMM_LIB) ^$(%t_OBJS)>>glibmm.mak & @echo.        
link ^$(LDFLAGS) ^$** ^$(GIO_LIBS) ^$(LIBSIGC_LIB) /out:^$@>>glibmm.mak & @echo.>>glibmm.mak]
 !endif
 
-!if [for %d in ($(PREFIX)) do @echo PREFIX_REAL=%~dpnd>>glibmm.mak]
+!if [for %t in (dbus network thread) do @for %s in (..\examples\%t\*.cc) do @echo 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\%~ns.exe: ^$(GIOMM_LIB) ^$(GLIBMM_LIB) 
vs^$(VSVER)\^$(CFG)\^$(PLAT)\glibmm-examples\%t-%~ns.obj>>glibmm.mak & @echo.    link ^$(LDFLAGS) ^$** 
^$(GIO_LIBS) ^$(LIBSIGC_LIB) /out:^$@>>glibmm.mak & @echo.>>glibmm.mak]
 !endif
 
 !include glibmm.mak
diff --git a/MSVC_NMake/generate-msvc.mak b/MSVC_NMake/generate-msvc.mak
index 528ed585..65c41d67 100644
--- a/MSVC_NMake/generate-msvc.mak
+++ b/MSVC_NMake/generate-msvc.mak
@@ -17,7 +17,7 @@ vs$(VSVER)\$(CFG)\$(PLAT)\glib-extra-defs-gen:
 
 # Compile schema for giomm settings example
 vs$(VSVER)\$(CFG)\$(PLAT)\gschema.compiled: ..\examples\settings\org.gtkmm.demo.gschema.xml
-       $(GLIB_COMPILE_SCHEMAS) --targetdir=vs$(VSVER)\$(CFG)\$(PLAT) ..\examples\settings
+       $(GLIB_COMPILE_SCHEMAS) --targetdir=$(@D) $(**D)
 
 # Generate wrap_init.cc files
 


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