r46961 - in /packages/morse/trunk/debian: changelog patches/bump-max-blender-version.patch patches/drop-link_append.patch patches/series

sylvestre at users.alioth.debian.org sylvestre at users.alioth.debian.org
Sun Dec 21 20:49:30 UTC 2014


Author: sylvestre
Date: Sun Dec 21 20:49:29 2014
New Revision: 46961

URL: http://svn.debian.org/wsvn/debian-science/?sc=1&rev=46961
Log:
Allow running with Blender 2.72. (Closes: #771132)

Added:
    packages/morse/trunk/debian/patches/bump-max-blender-version.patch
    packages/morse/trunk/debian/patches/drop-link_append.patch
Modified:
    packages/morse/trunk/debian/changelog
    packages/morse/trunk/debian/patches/series

Modified: packages/morse/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/debian-science/packages/morse/trunk/debian/changelog?rev=46961&op=diff
==============================================================================
--- packages/morse/trunk/debian/changelog	(original)
+++ packages/morse/trunk/debian/changelog	Sun Dec 21 20:49:29 2014
@@ -1,3 +1,10 @@
+morse-simulator (1.2.1-2) unstable; urgency=medium
+
+  [ Tobias Hansen ]
+  * Allow running with Blender 2.72. (Closes: #771132)
+
+ -- Sylvestre Ledru <sylvestre at debian.org>  Sun, 21 Dec 2014 19:10:50 +0100
+
 morse-simulator (1.2.1-1) unstable; urgency=medium
 
   * New upstream release

Added: packages/morse/trunk/debian/patches/bump-max-blender-version.patch
URL: http://svn.debian.org/wsvn/debian-science/packages/morse/trunk/debian/patches/bump-max-blender-version.patch?rev=46961&op=file
==============================================================================
--- packages/morse/trunk/debian/patches/bump-max-blender-version.patch	(added)
+++ packages/morse/trunk/debian/patches/bump-max-blender-version.patch	Sun Dec 21 20:49:29 2014
@@ -0,0 +1,24 @@
+From 35c9b53d03b5df6c1c66e0d3265235092774c225 Mon Sep 17 00:00:00 2001
+From: Pierrick Koch <pierrick.koch at gmail.com>
+Date: Wed, 24 Sep 2014 14:07:53 +0200
+Subject: [PATCH] [bin] bump blender max version
+
+tested with:
+http://download.blender.org/release/Blender2.72/blender-2.72-RC1-linux-glibc211-x86_64.tar.bz2
+---
+ bin/morse.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/bin/morse.in b/bin/morse.in
+index 022ece5..b28e01b 100755
+--- a/bin/morse.in
++++ b/bin/morse.in
+@@ -44,7 +44,7 @@ except ImportError as exn:
+ #Blender version must be egal or bigger than...
+ MIN_BLENDER_VERSION = "2.62"
+ #Blender version must be smaller than...
+-STRICT_MAX_BLENDER_VERSION = "2.72"
++STRICT_MAX_BLENDER_VERSION = "2.73"
+ 
+ #Unix-style path to the MORSE default scene and templates, within the prefix
+ DEFAULT_SCENE_PATH = "share/morse/data/morse_default.blend"

Added: packages/morse/trunk/debian/patches/drop-link_append.patch
URL: http://svn.debian.org/wsvn/debian-science/packages/morse/trunk/debian/patches/drop-link_append.patch?rev=46961&op=file
==============================================================================
--- packages/morse/trunk/debian/patches/drop-link_append.patch	(added)
+++ packages/morse/trunk/debian/patches/drop-link_append.patch	Sun Dec 21 20:49:29 2014
@@ -0,0 +1,64 @@
+From db937ea839121cd44762342c6833d4e8610a1911 Mon Sep 17 00:00:00 2001
+From: Pierrick Koch <pierrick.koch at gmail.com>
+Date: Mon, 15 Sep 2014 10:11:38 +0200
+Subject: [PATCH] [builder] link_append dropped in 2.71.6
+
+---
+ src/morse/builder/abstractcomponent.py | 12 ++++++++----
+ src/morse/builder/bpymorse.py          |  8 +++++++-
+ 2 files changed, 15 insertions(+), 5 deletions(-)
+
+--- a/src/morse/builder/abstractcomponent.py
++++ b/src/morse/builder/abstractcomponent.py
+@@ -633,19 +633,23 @@
+                              "or default path, typically $PREFIX/share/morse/data)."% (component, looked_dirs))
+                 raise FileNotFoundError("%s '%s' not found"%(self.__class__.__name__, component))
+ 
+-        if not objects: # link_append all objects from blend file
++        if not objects: # append all objects from blend file
+             objects = bpymorse.get_objects_in_blend(filepath)
+ 
+         if prefix: # filter (used by PassiveObject)
+             objects = [obj for obj in objects if obj.startswith(prefix)]
+ 
+-        # Format the objects list for link_append
++        # Format the objects list to append
+         objlist = [{'name':obj} for obj in objects]
+ 
+         bpymorse.deselect_all()
+         # Append the objects to the scene, and (auto)select them
+-        bpymorse.link_append(directory=filepath + '/Object/', link=False,
+-                             autoselect=True, files=objlist)
++        if bpymorse.version() >= (2, 71, 6):
++            bpymorse.append(directory=filepath + '/Object/',
++                            autoselect=True, files=objlist)
++        else:
++            bpymorse.link_append(directory=filepath + '/Object/', link=False,
++                                 autoselect=True, files=objlist)
+ 
+         return bpymorse.get_selected_objects()
+ 
+--- a/src/morse/builder/bpymorse.py
++++ b/src/morse/builder/bpymorse.py
+@@ -32,6 +32,8 @@
+ add_controller = empty_method
+ add_actuator = empty_method
+ link_append = empty_method
++link = empty_method # 2.71.6
++append = empty_method # 2.71.6
+ collada_import = empty_method
+ add_object = empty_method
+ add_empty = empty_method
+@@ -60,7 +62,11 @@
+     add_sensor = bpy.ops.logic.sensor_add
+     add_controller = bpy.ops.logic.controller_add
+     add_actuator = bpy.ops.logic.actuator_add
+-    link_append = bpy.ops.wm.link_append
++    if bpy.app.version >= (2, 71, 6):
++        link = bpy.ops.wm.link
++        append = bpy.ops.wm.append
++    else: # link_append dropped in 2.71.6
++        link_append = bpy.ops.wm.link_append
+     collada_import = bpy.ops.wm.collada_import
+     add_object = bpy.ops.object.add
+     if bpy.app.version >= (2, 65, 0):

Modified: packages/morse/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/debian-science/packages/morse/trunk/debian/patches/series?rev=46961&op=diff
==============================================================================
--- packages/morse/trunk/debian/patches/series	(original)
+++ packages/morse/trunk/debian/patches/series	Sun Dec 21 20:49:29 2014
@@ -1 +1,3 @@
 
+drop-link_append.patch
+bump-max-blender-version.patch




More information about the debian-science-commits mailing list