aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Kortkamp <tobik@FreeBSD.org>2018-07-09 12:08:09 +0000
committerTobias Kortkamp <tobik@FreeBSD.org>2018-07-09 12:08:09 +0000
commitc0156644ae7d372f51a1e298ec82952d41fda8d3 (patch)
tree4130167b1a77a8d53d14b33dc4987a80b6d888ca
parent2c9a1b098aacb1c2a1120a4e8a6eae5d08b13c96 (diff)
downloadports-c0156644ae7d372f51a1e298ec82952d41fda8d3.tar.gz
ports-c0156644ae7d372f51a1e298ec82952d41fda8d3.zip
Notes
-rw-r--r--x11-clocks/glclock/files/patch-GLObject.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/x11-clocks/glclock/files/patch-GLObject.cpp b/x11-clocks/glclock/files/patch-GLObject.cpp
new file mode 100644
index 000000000000..5a8ec51c574e
--- /dev/null
+++ b/x11-clocks/glclock/files/patch-GLObject.cpp
@@ -0,0 +1,15 @@
+GLObject.cpp:843:22: error: non-constant-expression cannot be narrowed from type 'double' to 'GLfloat' (aka 'float') in initializer list [-Wc++11-narrowing]
+ GLfloat lamb[4] = { color[0] * 0.1, color[1] * 0.1, color[2] * 0.1, 1.0f } ;
+ ^~~~~~~~~~~~~~
+
+--- GLObject.cpp.orig 2018-07-09 11:47:42 UTC
++++ GLObject.cpp
+@@ -840,7 +840,7 @@ void SetDirectionalLight(GLenum light, GLfloat pos[4],
+ GLfloat amb, GLfloat specularFlag, GLfloat bright, GLfloat *modulate)
+ {
+ GLfloat color[4] = { colorRGBA[0], colorRGBA[1], colorRGBA[2], 1.0f } ; // colorRGBA[3] } ;
+- GLfloat lamb[4] = { color[0] * 0.1, color[1] * 0.1, color[2] * 0.1, 1.0f } ;
++ GLfloat lamb[4] = { color[0] * 0.1f, color[1] * 0.1f, color[2] * 0.1f, 1.0f } ;
+ static GLfloat u_pos[4] ;
+ static GLfloat spec[4] = { 0.0f, 0.0f, 0.0f, 1.0f } ;
+