Hello, it is possible to have the option for cmake system?<br><br>Thanks<br><br><div><span class="gmail_quote">2007/12/16, Campbell Barton &lt;<a href="mailto:ideasman42@gmail.com">ideasman42@gmail.com</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Revision: 12908<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&amp;root=bf-blender&amp;revision=12908">http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&amp;root=bf-blender&amp;revision=12908
</a><br>Author:&nbsp;&nbsp; campbellbarton<br>Date:&nbsp;&nbsp;&nbsp;&nbsp; 2007-12-16 07:50:49 +0100 (Sun, 16 Dec 2007)<br><br>Log Message:<br>-----------<br>* Added an option not to compile the 2.4x api (WITH_PYAPI_V24X for Makefiles and WITH_BF_PYAPI_V24X for scons)
<br>* ghash wasnt being set to null when python stopped and was segfaulting on exit<br><br>Modified Paths:<br>--------------<br>&nbsp;&nbsp;&nbsp;&nbsp;trunk/blender/source/blender/python/BPY_interface.c<br>&nbsp;&nbsp;&nbsp;&nbsp;trunk/blender/source/blender/python/Makefile
<br>&nbsp;&nbsp;&nbsp;&nbsp;trunk/blender/source/blender/python/SConscript<br>&nbsp;&nbsp;&nbsp;&nbsp;trunk/blender/source/nan_definitions.mk<br>&nbsp;&nbsp;&nbsp;&nbsp;trunk/blender/tools/btools.py<br><br>Modified: trunk/blender/source/blender/python/BPY_interface.c<br>===================================================================
<br>--- trunk/blender/source/blender/python/BPY_interface.c 2007-12-16 05:46:24 UTC (rev 12907)<br>+++ trunk/blender/source/blender/python/BPY_interface.c 2007-12-16 06:50:49 UTC (rev 12908)<br>@@ -75,7 +75,9 @@<br> #include &quot;api2_5x/bpy.h&quot; /* for the new &quot;bpy&quot; module */
<br><br> /* old 2.4x api */<br>+#ifdef WITH_PYAPI_V24X<br> #include &quot;api2_4x/Blender.h&quot;<br>+#endif<br><br> /*these next two are for pyconstraints*/<br> #include &quot;api2_5x/IDProp.h&quot;<br>@@ -319,8 +321,10 @@
<br>&nbsp;&nbsp;* support for packages here e.g. import `package.module` */<br><br> static struct _inittab BPyInittab_Modules[] = {<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&quot;bpy&quot;, m_bpy_init},<br>+#ifdef WITH_PYAPI_V24X<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{&quot;Blender&quot;, V24_M_Blender_Init},
<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&quot;bpy&quot;, m_bpy_init},<br>+#endif<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{NULL, NULL}<br> };<br><br>@@ -396,9 +400,9 @@<br> void BPY_idhash_remove(ID *id)<br> {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;GHash *hash = idhash__internal(id);<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (!hash) /* TODO - Dont allow invalid hashes at all*/
<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (hash==NULL)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return;<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf(&quot;remove hash %s\n&quot;, id-&gt;name);<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //printf(&quot;remove hash %s\n&quot;, id-&gt;name);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;BLI_ghash_remove(hash, id, NULL, NULL);
<br> }<br><br>@@ -412,10 +416,10 @@<br> {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;GHash *hash = idhash__internal(id);<br><br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (!hash) /* TODO - Dont allow invalid hashes */<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (hash==NULL)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return;<br><br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf(&quot;invalidate hash %s\n&quot;, id-&gt;name);
<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //printf(&quot;invalidate hash %s\n&quot;, id-&gt;name);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;BLI_ghash_remove(hash, id, NULL, genlib_invalidate);<br><br> }<br>@@ -424,7 +428,7 @@<br> void BPY_idhash_add(void *value)<br> {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ID *id = ((BPyGenericLibObject *)value)-&gt;id;
<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf(&quot;adding hash %s\n&quot;, id-&gt;name);<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //printf(&quot;adding hash %s\n&quot;, id-&gt;name);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;BLI_ghash_insert(idhash__internal(id), (void *)id, (void *)value);<br> }<br> /* END OF BPY ID HASH */
<br>@@ -536,10 +540,10 @@<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;EXPP_Library_Close(&nbsp;&nbsp;);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;// free id hashes<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_text, NULL, NULL);<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_scene, NULL, NULL);<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_group, NULL, NULL);
<br>-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_object, NULL, NULL);<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_text, NULL, NULL);&nbsp;&nbsp;&nbsp;&nbsp;bpy_idhash_text = NULL;<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_scene, NULL, NULL);&nbsp;&nbsp; bpy_idhash_scene = NULL;
<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_group, NULL, NULL);&nbsp;&nbsp; bpy_idhash_group = NULL;<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLI_ghash_free(bpy_idhash_object, NULL, NULL);&nbsp;&nbsp;bpy_idhash_object = NULL;<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return;<br> }<br><br>Modified: trunk/blender/source/blender/python/Makefile
<br>===================================================================<br>--- trunk/blender/source/blender/python/Makefile&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2007-12-16 05:46:24 UTC (rev 12907)<br>+++ trunk/blender/source/blender/python/Makefile&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2007-12-16 06:50:49 UTC (rev 12908)
<br>@@ -32,6 +32,11 @@<br> # Bounces make to subdirectories.<br><br> SOURCEDIR = source/blender/python<br>-DIRS = api2_4x api2_5x<br><br>+DIRS = api2_5x<br>+<br>+ifeq ($(WITH_PYAPI_V24X), true)<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; DIRS += api2_4x<br>
+endif<br>+<br> include nan_subdirs.mk<br><br>Modified: trunk/blender/source/blender/python/SConscript<br>===================================================================<br>--- trunk/blender/source/blender/python/SConscript&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2007-12-16 05:46:24 UTC (rev 12907)
<br>+++ trunk/blender/source/blender/python/SConscript&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2007-12-16 06:50:49 UTC (rev 12908)<br>@@ -1,9 +1,9 @@<br> #!/usr/bin/python<br> Import (&#39;env&#39;)<br><br>-sources = Split(&#39;BPY_interface.c BPY_menus.c&#39;) + 
env.Glob(&#39;api2_5x/*.c&#39;) + env.Glob(&#39;api2_4x/*.c&#39;)<br>+sources = Split(&#39;BPY_interface.c BPY_menus.c&#39;) + env.Glob(&#39;api2_5x/*.c&#39;)<br><br>-incs = &#39;api2_5x api2_4x ../blenkernel ../blenlib ../blenloader&#39;
<br>+incs = &#39;api2_5x ../blenkernel ../blenlib ../blenloader&#39;<br> incs += &#39; ../render/extern/include ../radiosity/extern/include&#39;<br> incs += &#39; ../makesdna #intern/guardedalloc #intern/bmfont ../imbuf ../include&#39;
<br> incs += &#39; &#39; + env[&#39;BF_PYTHON_INC&#39;]<br>@@ -23,4 +23,9 @@<br> if env[&#39;WITH_BF_FFMPEG&#39;] == 1:<br>&nbsp;&nbsp;&nbsp;&nbsp; defs.append(&#39;WITH_FFMPEG&#39;)<br><br>+if env[&#39;WITH_BF_PYAPI_V24X&#39;]==1:<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
defs.append(&#39;WITH_PYAPI_V24X&#39;)<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sources += env.Glob(&#39;api2_4x/*.c&#39;)<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; incs += &#39; api2_4x&#39;<br>+<br> env.BlenderLib ( libname=&#39;blender_python&#39;, sources = Split(sources), includes = Split(incs), defines = defs, libtype=[&#39;core&#39;,&#39;game2&#39;], priority = [60,115] )
<br><br>Modified: trunk/blender/source/nan_definitions.mk<br>===================================================================<br>--- trunk/blender/source/nan_definitions.mk&nbsp;&nbsp;&nbsp;&nbsp; 2007-12-16 05:46:24 UTC (rev 12907)<br>+++ trunk/blender/source/nan_definitions.mk&nbsp;&nbsp;&nbsp;&nbsp; 2007-12-16 06:50:49 UTC (rev 12908)
<br>@@ -112,7 +112,8 @@<br><br>&nbsp;&nbsp;&nbsp;&nbsp; export WITH_OPENEXR ?= true<br>&nbsp;&nbsp;&nbsp;&nbsp; export WITH_DDS ?= true<br>-<br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; export WITH_PYAPI_V24X ?= true<br>+<br>&nbsp;&nbsp;&nbsp;&nbsp; ifeq ($(OS),windows)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;export NAN_WINTAB ?= $(LCGDIR)/wintab
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ifeq ($(FREE_WINDOWS), true)<br><br>Modified: trunk/blender/tools/btools.py<br>===================================================================<br>--- trunk/blender/tools/btools.py&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2007-12-16 05:46:24 UTC (rev 12907)
<br>+++ trunk/blender/tools/btools.py&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2007-12-16 06:50:49 UTC (rev 12908)<br>@@ -46,7 +46,7 @@<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &#39;WITH_BF_QUICKTIME&#39;, &#39;BF_QUICKTIME&#39;, &#39;BF_QUICKTIME_INC&#39;, &#39;BF_QUICKTIME_LIB&#39;, &#39;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&#39;, &#39;FFMPEG includes&#39;, &#39;&#39;),<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (&#39;BF_FFMPEG_LIBPATH&#39;, &#39;FFMPEG library path&#39;, &#39;&#39;),<br><br>+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(BoolOption(&#39;WITH_BF_PYAPI_V24X&#39;, &#39;Compile Blender 
2.4x python api if true&#39;, &#39;true&#39;)),<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (BoolOption(&#39;WITH_BF_JPEG&#39;, &#39;Use JPEG if true&#39;, &#39;true&#39;)),<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (&#39;BF_JPEG&#39;, &#39;JPEG base path&#39;, &#39;&#39;),<br><br>
<br>_______________________________________________<br>Bf-blender-cvs mailing list<br><a href="mailto:Bf-blender-cvs@blender.org">Bf-blender-cvs@blender.org</a><br><a href="http://lists.blender.org/mailman/listinfo/bf-blender-cvs">
http://lists.blender.org/mailman/listinfo/bf-blender-cvs</a><br></blockquote></div><br>