FreeBSD Bugzilla – Attachment 189528 Details for
Bug 225006
graphics/libgltf: fails to build with clang 6.0 (blocks 113 ports)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
ugly fix
gltf.c++11.diff (text/plain), 1.85 KB, created by
Jan Beich
on 2018-01-08 17:04:13 UTC
(
hide
)
Description:
ugly fix
Filename:
MIME Type:
Creator:
Jan Beich
Created:
2018-01-08 17:04:13 UTC
Size:
1.85 KB
patch
obsolete
>From 9eb1d8ffbcc7d5753c0d2f616d53d2384803aa28 Mon Sep 17 00:00:00 2001 >From: Jan Beich <jbeich@FreeBSD.org> >Date: Mon, 8 Jan 2018 14:23:58 +0000 >Subject: [PATCH] graphics/libgltf: unbreak build with Clang 6 (C++14 by > default) > >Shaders.cpp:178:13: error: non-constant-expression cannot be narrowed from type 'size_t' (aka 'unsigned int') to 'GLint' (aka 'int') in initializer list [-Wc++11-narrowing] > strlen("#version 130\n"), > ^~~~~~~~~~~~~~~~~~~~~~~~ >Shaders.cpp:178:13: note: insert an explicit cast to silence this issue > strlen("#version 130\n"), > ^~~~~~~~~~~~~~~~~~~~~~~~ > static_cast<GLint>( ) > >Reported by: antoine (via bug 224669) >--- > graphics/libgltf/files/patch-src_Shaders.cpp | 19 +++++++++++++++++++ > 1 file changed, 19 insertions(+) > create mode 100644 graphics/libgltf/files/patch-src_Shaders.cpp > >diff --git a/graphics/libgltf/files/patch-src_Shaders.cpp b/graphics/libgltf/files/patch-src_Shaders.cpp >new file mode 100644 >index 000000000000..e22d8ea40868 >--- /dev/null >+++ b/graphics/libgltf/files/patch-src_Shaders.cpp >@@ -0,0 +1,19 @@ >+Shaders.cpp:178:13: error: non-constant-expression cannot be narrowed from type 'size_t' (aka 'unsigned int') to 'GLint' (aka 'int') in initializer list [-Wc++11-narrowing] >+ strlen("#version 130\n"), >+ ^~~~~~~~~~~~~~~~~~~~~~~~ >+Shaders.cpp:178:13: note: insert an explicit cast to silence this issue >+ strlen("#version 130\n"), >+ ^~~~~~~~~~~~~~~~~~~~~~~~ >+ static_cast<GLint>( ) >+ >+--- src/Shaders.cpp.orig 2014-10-01 18:31:43 UTC >++++ src/Shaders.cpp >+@@ -175,7 +175,7 @@ bool ShaderProgram::compileShader(const char* pShader, >+ }; >+ >+ const GLint aSizes[] = { >+- strlen("#version 130\n"), >++ static_cast<GLint>(strlen("#version 130\n")), >+ iGLSize, >+ }; >+
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 225006
: 189528