summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Grigo <agrigo2001@yahoo.com.au>2020-11-27 14:13:08 +1100
committerJoonas Niilola <juippis@gentoo.org>2020-12-03 09:32:12 +0200
commit406cafd8aab1d7d2a166513504800a57396d9bcd (patch)
tree92a4c6277ea80270e28cc1e99881c6d622d71326 /media-gfx/blender
parentmedia-gfx/blender: Use subslot binder for media-libs/osl (diff)
downloadgentoo-406cafd8aab1d7d2a166513504800a57396d9bcd.tar.gz
gentoo-406cafd8aab1d7d2a166513504800a57396d9bcd.tar.bz2
gentoo-406cafd8aab1d7d2a166513504800a57396d9bcd.zip
media-gfx/blender: Set Build Type for Blender
Blender requires that the build type is set to None, Debug, Release, RelWithDebInfo or MinSizeRel. This requires it to be overridden. If this is not done, then it is set to Gentoo by cmake.eclass, and the scripts in CMakeLists fail to set one of DEBUG or NDEBUG. In blender 2.91, this results in not defining GPU_vertex_buffer._data_end, but also attempting to execute an assert which requires it to be defined. Setting CMAKE_BUILD_TYPE to Release resolves the issue by setting NDEBUG to prevent compilation of the assert, and unsetting DEBUG so that the _data_end is not compiled. This means that the patch to prevent the compilation of the assert is no longer required. Older version of blender in the tree also have the same requirement for the value of CMAKE_BUILD_TYPE, but so far compiled correctly even when it was set to Gentoo. Signed-off-by: Adrian Grigo <agrigo2001@yahoo.com.au> Package-Manager: Portage-3.0.9, Repoman-3.0.2 Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'media-gfx/blender')
-rw-r--r--media-gfx/blender/blender-2.83.4-r1.ebuild2
-rw-r--r--media-gfx/blender/blender-2.90.1-r1.ebuild2
-rw-r--r--media-gfx/blender/blender-2.91.0.ebuild4
-rw-r--r--media-gfx/blender/files/blender-2.91.0-define-data-end.patch14
4 files changed, 5 insertions, 17 deletions
diff --git a/media-gfx/blender/blender-2.83.4-r1.ebuild b/media-gfx/blender/blender-2.83.4-r1.ebuild
index 055f713caf71..f28ba088062c 100644
--- a/media-gfx/blender/blender-2.83.4-r1.ebuild
+++ b/media-gfx/blender/blender-2.83.4-r1.ebuild
@@ -114,6 +114,8 @@ BDEPEND="
nls? ( sys-devel/gettext )
"
+CMAKE_BUILD_TYPE="Release"
+
blender_check_requirements() {
[[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
diff --git a/media-gfx/blender/blender-2.90.1-r1.ebuild b/media-gfx/blender/blender-2.90.1-r1.ebuild
index 04d9740cdfc4..7c7ab67c366e 100644
--- a/media-gfx/blender/blender-2.90.1-r1.ebuild
+++ b/media-gfx/blender/blender-2.90.1-r1.ebuild
@@ -114,6 +114,8 @@ BDEPEND="
nls? ( sys-devel/gettext )
"
+CMAKE_BUILD_TYPE="Release"
+
blender_check_requirements() {
[[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
diff --git a/media-gfx/blender/blender-2.91.0.ebuild b/media-gfx/blender/blender-2.91.0.ebuild
index fbb40039d4f8..495bfc89e174 100644
--- a/media-gfx/blender/blender-2.91.0.ebuild
+++ b/media-gfx/blender/blender-2.91.0.ebuild
@@ -118,9 +118,7 @@ BDEPEND="
nls? ( sys-devel/gettext )
"
-PATCHES=(
- "${FILESDIR}/${P}-define-data-end.patch"
-)
+CMAKE_BUILD_TYPE="Release"
blender_check_requirements() {
[[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
diff --git a/media-gfx/blender/files/blender-2.91.0-define-data-end.patch b/media-gfx/blender/files/blender-2.91.0-define-data-end.patch
deleted file mode 100644
index 99705adae25c..000000000000
--- a/media-gfx/blender/files/blender-2.91.0-define-data-end.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-diff -Naur a/source/blender/gpu/GPU_vertex_buffer.h b/source/blender/gpu/GPU_vertex_buffer.h
---- a/source/blender/gpu/GPU_vertex_buffer.h 2020-11-26 16:36:36.226883721 +1100
-+++ b/source/blender/gpu/GPU_vertex_buffer.h 2020-11-26 16:38:08.691212985 +1100
-@@ -118,7 +118,10 @@
- {
- unsigned char *data = a->data;
- a->data += a->stride;
-+#ifdef DEBUG
-+ /* Assert only compiles if _data_end exists */
- BLI_assert(data < a->_data_end);
-+#endif
- return (void *)data;
- }
-