[vtkusers] compilation of VTK6.1 with Qt5-enabled - Policy CMP0040 is not set....
David E DeMarle
dave.demarle at kitware.com
Mon Nov 3 10:54:47 EST 2014
I think the means that that there is a new behavior in cmake 3.0.2 which
the older vtk 6.2 release code isn't entirely happy with.
Besides Gib's point, adding a line like the following to the top level
CMakeLists.txt should address the warning.
if(POLICY CMP0040)
cmake_policy(SET CMP0040 OLD)
endif()
Updating the CMake script inside VTK's hdf5 to have an existing target is a
better fix.
David E DeMarle
Kitware, Inc.
R&D Engineer
21 Corporate Drive
Clifton Park, NY 12065-8662
Phone: 518-881-4909
On Sat, Nov 1, 2014 at 2:15 AM, Gib Bogle <g.bogle at auckland.ac.nz> wrote:
> They look to me like warnings, not errors. Is the build successful?
>
> Gib
> ------------------------------
> *From:* vtkusers [vtkusers-bounces at vtk.org] on behalf of Sam Raby [
> rabysam28 at gmail.com]
> *Sent:* Saturday, 1 November 2014 6:32 p.m.
> *To:* vtkusers at vtk.org
> *Subject:* [vtkusers] compilation of VTK6.1 with Qt5-enabled - Policy
> CMP0040 is not set....
>
> I am compiling VTK 6.1 from [1] with Qt enabled (Qt 5.3.2 from [2])
> using cmake 3.0.2 from [3]. My OS is Ubuntu 12.04.
>
> I am running the following command [4] for ccmake:
>
> cd /path/to/VTK-Release-build
> ccmake -DVTK_QT_VERSION:STRING=5 \
> -DQT_QMAKE_EXECUTABLE:PATH=/path/to/qt5.2.1-install/5.2.1/gcc_64/bin/qmake \
> -DVTK_Group_Qt:BOOL=ON \
> -DCMAKE_PREFIX_PATH:PATH=/path/to/qt.5.2.1-install/5.2.1/gcc_64/lib/cmake \
> -DBUILD_SHARED_LIBS:BOOL=ON
> /path/to/VTK
>
>
> but I'm getting the following error:
>
> *(ADD_CUSTOM_COMMAND):*
> *Policy CMP0040 is not set: The target in the TARGET signature of*
> *add_custom_command() must exist. Run "cmake --help-policy CMP0040" for **policy
> details. Use the cmake_policy command to set the policy and*
> *suppress this warning.*
>
> *The target name*
>
> *"/home/torabi/local2/VTK/VTK-6.1.0-build/ThirdParty/hdf5/vtkhdf5/H5Edefin.h"*
> *is unknown in this context.*
> *This warning is for project developers. Use -Wno-dev to suppress it.*
>
> Would you please hint me how to tackle this error?
>
> Thanks
> -S
>
> [1] http://www.vtk.org/files/release/6.1/VTK-6.1.0.tar.gz
> [2]
> http://download.qt-project.org/official_releases/online_installers/qt-opensource-linux-x64-1.6.0-5-online.run
> [3] http://www.cmake.org/files/v3.0/cmake-3.0.2.tar.gz
> [4] http://www.vtk.org/Wiki/VTK/Building/Linux#Qt5
>
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20141103/aaf6dfca/attachment.html>
More information about the vtkusers
mailing list