Your message dated Sat, 27 Nov 2010 11:21:19 +0100
with message-id <[email protected]>
and subject line cmake: find_package(VTK) with additional version requirement 
fails
has caused the Debian Bug report #600889,
regarding cmake: find_package(VTK) with additional version requirement fails
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
600889: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=600889
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: cmake
Version: 2.8.2-2
Severity: normal

A line like this in CMakeLists.txt causes cmake on squeeze to fail:

FIND_PACKAGE(VTK 5.4 REQUIRED)

it won't find VTK although installed. In contrast, this one works fine:

FIND_PACKAGE(VTK REQUIRED)

both versions work on lenny (tested cmake 2.6-patch 4) -- although the
version requirement seems to have no effect (always succeeds with any
VTK).

Here is what I see on squeeze:

mich...@meiner /tmp % mkdir cmake_vtk/

mich...@meiner /tmp/cmake_vtk % rm -rf *; echo "FIND_PACKAGE(VTK 5.4 REQUIRED)" 
> CMakeLists.txt; cmake  .
...
CMake Error at /usr/share/cmake-2.8/Modules/FindVTK.cmake:136 (MESSAGE):
  VTK not found.  Set the VTK_DIR cmake cache entry to the directory
  containing VTKConfig.cmake.  This is either the root of the build tree, or
  PREFIX/lib/vtk for an installation.
Call Stack (most recent call first):
  CMakeLists.txt:1 (FIND_PACKAGE)
...
-- Configuring incomplete, errors occurred!

mich...@meiner /tmp/cmake_vtk % rm -rf *; echo "FIND_PACKAGE(VTK 5.4 REQUIRED)" 
> CMakeLists.txt; cmake  . -DVTK_DIR=/usr/lib/vtk-5.4
[SAME OUTPUT]
despite:
mich...@meiner /tmp/cmake_vtk % ls /usr/lib/vtk-5.4/VTKConfig.cmake
/usr/lib/vtk-5.4/VTKConfig.cmake

and strangely:

mich...@meiner /tmp/cmake_vtk % grep VTK_DIR CMakeCache.txt
VTK_DIR:PATH=VTK_DIR-NOTFOUND

finally:

mich...@meiner /tmp/cmake_vtk % rm -rf *; echo "FIND_PACKAGE(VTK REQUIRED)" > 
CMakeLists.txt; cmake  .
...
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/cmake_vtk
mich...@meiner /tmp/cmake_vtk % grep VTK_DIR CMakeCache.txt
VTK_DIR:PATH=/usr/lib/vtk-5.4

I guess either the documentation of find_package is wrong or something
is broken.


Thanks for your consideration,

Michael

-- System Information:
Debian Release: squeeze/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.32-5-686 (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages cmake depends on:
ii  cmake-data              2.8.2-2          CMake data files (modules, templat
ii  libarchive1             2.8.4-1          Single library to read/write tar, 
ii  libc6                   2.11.2-6         Embedded GNU C Library: Shared lib
ii  libcurl3-gnutls         7.21.0-1         Multi-protocol file transfer libra
ii  libexpat1               2.0.1-7          XML parsing C library - runtime li
ii  libgcc1                 1:4.4.5-2        GCC support library
ii  libstdc++6              4.4.5-2          The GNU Standard C++ Library v3
ii  libxmlrpc-c3            1.06.27-1.1      A lightweight RPC library based on
ii  procps                  1:3.2.8-9        /proc file system utilities
ii  zlib1g                  1:1.2.3.4.dfsg-3 compression library - runtime

cmake recommends no packages.

Versions of packages cmake suggests:
ii  gcc                           4:4.4.5-1  The GNU C compiler
ii  make                          3.81-8     An utility for Directing compilati

-- no debconf information



--- End Message ---
--- Begin Message ---
Version: 2.8.2-2

Hello Michael,
that's not a bug, but expected behaviour, therefore I'm closing this bug. For
reference I partly quote FindVTK.cmake's header here:
> # The following cache entries must be set by the user to locate VTK:
> #  VTK_DIR  - The directory containing VTKConfig.cmake.  
> #             This is either the root of the build tree,
> #             or the lib/vtk directory.  This is the 
> #             only cache entry.

One could argue whether this is a good way but any request to change
FindVTK.cmake's behaviour (that is: work (again) without VTK_DIR set) should be
made upstream at [0].

Kind regards,
Kai Wasserbäch


[0] <http://cmake.org/Bug/bug_report_page.php>



-- 

Kai Wasserbäch (Kai Wasserbaech)

E-Mail: [email protected]
Jabber (debianforum.de): Drizzt
URL: http://wiki.debian.org/C%C3%B9ran
GnuPG: 0xE1DE59D2      0600 96CE F3C8 E733 E5B6 1587 A309 D76C E1DE 59D2
(http://pgpkeys.pca.dfn.de/pks/lookup?search=0xE1DE59D2&fingerprint=on&hash=on&op=vindex)

Attachment: signature.asc
Description: OpenPGP digital signature


--- End Message ---

Reply via email to