Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 20 Jun 2018 09:27:51 +0000 (UTC)
From:      Adriaan de Groot <adridg@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r472860 - head/math/vtk6/files
Message-ID:  <201806200927.w5K9Rp9Q009100@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: adridg
Date: Wed Jun 20 09:27:51 2018
New Revision: 472860
URL: https://svnweb.freebsd.org/changeset/ports/472860

Log:
  Fix build of math/vtk6 with Clang6 on -CURRENT.
  
  The definition of NULL has changed in C++, and conversions have
  gotten stricter, so using NULL where you mean 0 (or false) is
  no longer an option. Detected by fallout from updating CMake 3.12.
  
  No PORTREVISION bump because everywhere where it compiled previously
  sees no change, and where it didn't compile before it does now
  with the same result.
  
  Reported by:	tcberner

Added:
  head/math/vtk6/files/patch-Rendering_OpenGL_vtkXOpenGLRenderWindow.cxx   (contents, props changed)

Added: head/math/vtk6/files/patch-Rendering_OpenGL_vtkXOpenGLRenderWindow.cxx
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/math/vtk6/files/patch-Rendering_OpenGL_vtkXOpenGLRenderWindow.cxx	Wed Jun 20 09:27:51 2018	(r472860)
@@ -0,0 +1,40 @@
+--- Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx.orig	2015-03-03 20:37:14 UTC
++++ Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx
+@@ -386,7 +386,7 @@ XVisualInfo *vtkXOpenGLRenderWindow::Get
+ 
+ vtkXOpenGLRenderWindow::vtkXOpenGLRenderWindow()
+ {
+-  this->ParentId = static_cast<Window>(NULL);
++  this->ParentId = static_cast<Window>(0);
+   this->ScreenSize[0] = 0;
+   this->ScreenSize[1] = 0;
+   this->OwnDisplay = 0;
+@@ -394,8 +394,8 @@ vtkXOpenGLRenderWindow::vtkXOpenGLRender
+   this->ForceMakeCurrent = 0;
+   this->UsingHardware = 0;
+   this->DisplayId = static_cast<Display *>(NULL);
+-  this->WindowId = static_cast<Window>(NULL);
+-  this->NextWindowId = static_cast<Window>(NULL);
++  this->WindowId = static_cast<Window>(0);
++  this->NextWindowId = static_cast<Window>(0);
+   this->ColorMap = static_cast<Colormap>(0);
+   this->OwnWindow = 0;
+ 
+@@ -776,7 +776,7 @@ void vtkXOpenGLRenderWindow::DestroyWind
+   if (this->OwnWindow && this->DisplayId && this->WindowId)
+     {
+     XDestroyWindow(this->DisplayId,this->WindowId);
+-    this->WindowId = static_cast<Window>(NULL);
++    this->WindowId = static_cast<Window>(0);
+     }
+ 
+   // if we create the display, we'll delete it
+@@ -1168,7 +1168,7 @@ void vtkXOpenGLRenderWindow::WindowRemap
+ 
+   // set the default windowid
+   this->WindowId = this->NextWindowId;
+-  this->NextWindowId = static_cast<Window>(NULL);
++  this->NextWindowId = static_cast<Window>(0);
+ 
+   // set everything up again
+   this->Initialize();



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201806200927.w5K9Rp9Q009100>