win32/vs8/grammar.vcproj: Error out with a warning if glib-genmarshal.exe is not...
authorMarcus Granado <mrc.gran@gmail.com>
Sun, 15 Oct 2006 12:47:13 +0000 (12:47 +0000)
committerTim-Philipp Müller <tim@centricular.net>
Sun, 15 Oct 2006 12:47:13 +0000 (12:47 +0000)
Original commit message from CVS:
Patch by: Marcus Granado  <mrc dot gran at gmail com>
* win32/vs8/grammar.vcproj:
Error out with a warning if glib-genmarshal.exe is not in path,
instead of creating bogus gstmarshal.[ch] files. Fixes #361720.

ChangeLog
win32/vs8/grammar.vcproj

index e339366..40010df 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2006-10-15  Tim-Philipp Müller  <tim at centricular dot net>
+
+       Patch by: Marcus Granado  <mrc dot gran at gmail com>
+
+       * win32/vs8/grammar.vcproj:
+         Error out with a warning if glib-genmarshal.exe is not in path,
+         instead of creating bogus gstmarshal.[ch] files. Fixes #361720.
+
 2006-10-13  Wim Taymans  <wim@fluendo.com>
 
        * gst/gstsegment.c: (gst_segment_set_seek):
index 34b28db..a6db0b6 100644 (file)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="windows-1251"?>
 <VisualStudioProject
        ProjectType="Visual C++"
-       Version="8,00"
+       Version="8.00"\r
        Name="grammar"
        ProjectGUID="{6D7EB3D4-7E91-4D98-80EA-28A8F2E365F7}"
        RootNamespace="grammar"
                                >
                                <Tool
                                        Name="VCCustomBuildTool"
-                                       CommandLine="if exist ..\..\gst\gstmarshal.c goto HEADER&#x0D;&#x0A;echo #include &quot;glib-object.h&quot; &gt; gstmarshal.c.tmp&#x0D;&#x0A;echo #include &quot;gstmarshal.h&quot; &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;glib-genmarshal --body --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;move gstmarshal.c.tmp ..\..\gst\gstmarshal.c&#x0D;&#x0A;:HEADER&#x0D;&#x0A;if exist ..\..\gst\gstmarshal.h goto END&#x0D;&#x0A;echo #include &quot;gst/gstconfig.h&quot; &gt; gstmarshal.h.tmp&#x0D;&#x0A;glib-genmarshal --header --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.h.tmp&#x0D;&#x0A;move gstmarshal.h.tmp ..\..\gst\gstmarshal.h&#x0D;&#x0A;:END&#x0D;&#x0A;"
+                                       CommandLine="glib-genmarshal &gt; NUL 2&gt; NUL&#x0D;&#x0A;if %errorlevel% == 9009 goto NOGLIBGENMARSHAL &#x0D;&#x0A;rem resets errorlevel to 0 because it is 1 now:&#x0D;&#x0A;dir &gt; NUL&#x0D;&#x0A;&#x0D;&#x0A;if exist ..\..\gst\gstmarshal.c goto HEADER&#x0D;&#x0A;echo #include &quot;glib-object.h&quot; &gt; gstmarshal.c.tmp&#x0D;&#x0A;echo #include &quot;gstmarshal.h&quot; &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;glib-genmarshal --body --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;move gstmarshal.c.tmp ..\..\gst\gstmarshal.c&#x0D;&#x0A;:HEADER&#x0D;&#x0A;if exist ..\..\gst\gstmarshal.h goto END&#x0D;&#x0A;echo #include &quot;gst/gstconfig.h&quot; &gt; gstmarshal.h.tmp&#x0D;&#x0A;glib-genmarshal --header --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.h.tmp&#x0D;&#x0A;move gstmarshal.h.tmp ..\..\gst\gstmarshal.h&#x0D;&#x0A;goto END&#x0D;&#x0A;&#x0D;&#x0A;:NOGLIBGENMARSHAL&#x0D;&#x0A;echo ERROR %errorlevel%&#x0D;&#x0A;echo ### YOU DO NOT HAVE GLIB-GENMARSHAL.EXE IN YOUR PATH.&#x0D;&#x0A;echo ### INSTALL GLIB-DEV AND/OR MAKE SURE IT IS IN YOUR PATH!&#x0D;&#x0A;&#x0D;&#x0A;:END&#x0D;&#x0A;&#x0D;&#x0A;"\r
                                        Outputs="gstmarshal.tmp"
                                />
                        </FileConfiguration>
                                >
                                <Tool
                                        Name="VCCustomBuildTool"
-                                       CommandLine="if exist ..\..\gst\gstmarshal.c goto HEADER&#x0D;&#x0A;echo #include &quot;glib-object.h&quot; &gt; gstmarshal.c.tmp&#x0D;&#x0A;echo #include &quot;gstmarshal.h&quot; &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;glib-genmarshal --body --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;move gstmarshal.c.tmp ..\..\gst\gstmarshal.c&#x0D;&#x0A;:HEADER&#x0D;&#x0A;if exist ..\..\gst\gstmarshal.h goto END&#x0D;&#x0A;echo #include &quot;gst/gstconfig.h&quot; &gt; gstmarshal.h.tmp&#x0D;&#x0A;glib-genmarshal --header --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.h.tmp&#x0D;&#x0A;move gstmarshal.h.tmp ..\..\gst\gstmarshal.h&#x0D;&#x0A;:END&#x0D;&#x0A;"
+                                       CommandLine="glib-genmarshal &gt; NUL 2&gt; NUL&#x0D;&#x0A;if %errorlevel% == 9009 goto NOGLIBGENMARSHAL &#x0D;&#x0A;rem resets errorlevel to 0 because it is 1 now:&#x0D;&#x0A;dir &gt; NUL&#x0D;&#x0A;&#x0D;&#x0A;if exist ..\..\gst\gstmarshal.c goto HEADER&#x0D;&#x0A;echo #include &quot;glib-object.h&quot; &gt; gstmarshal.c.tmp&#x0D;&#x0A;echo #include &quot;gstmarshal.h&quot; &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;glib-genmarshal --body --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.c.tmp&#x0D;&#x0A;move gstmarshal.c.tmp ..\..\gst\gstmarshal.c&#x0D;&#x0A;:HEADER&#x0D;&#x0A;if exist ..\..\gst\gstmarshal.h goto END&#x0D;&#x0A;echo #include &quot;gst/gstconfig.h&quot; &gt; gstmarshal.h.tmp&#x0D;&#x0A;glib-genmarshal --header --prefix=gst_marshal ..\..\gst\gstmarshal.list &gt;&gt; gstmarshal.h.tmp&#x0D;&#x0A;move gstmarshal.h.tmp ..\..\gst\gstmarshal.h&#x0D;&#x0A;goto END&#x0D;&#x0A;&#x0D;&#x0A;:NOGLIBGENMARSHAL&#x0D;&#x0A;echo ERROR %errorlevel%&#x0D;&#x0A;echo ### YOU DO NOT HAVE GLIB-GENMARSHAL.EXE IN YOUR PATH.&#x0D;&#x0A;echo ### INSTALL GLIB-DEV AND/OR MAKE SURE IT IS IN YOUR PATH!&#x0D;&#x0A;&#x0D;&#x0A;:END&#x0D;&#x0A;&#x0D;&#x0A;"\r
                                        Outputs="gstmarshal.tmp"
                                />
                        </FileConfiguration>