Unable to build VTK examples - vtk

I'm having lots of difficulties just building VTK examples - can someone help please?
I've downloaded and installed VTK-9.0.1 on my ubuntu 18.04.4 system. Now I want to install and run the VTK examples at this link., so I clone that repo. Then I follow the instructions to "Build all of the examples" at this link.. So I do this:
% mkdir VTKExamples-build
% cd VTKExamples-build
% cmake ../VTKExamples
cmake outputs these messages:
-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- VTKWikiExamples: Building VTKWikiExamples stand-alone
-- VTKWikiExamples: Building VTKWikiExamples stand-alone - yes
-- VTKWikiExamples: Setting executables prefix
-- VTKWikiExamples: Setting executables prefix - no
-- VTKWikiExamples: VTK VERSION: 9.0.1(OpenGL2)
-- VTKWikiExamples: Example executables are stored in /home/oreilly/VTKExamples-build/bin
-- VTKWikiExamples: Tests will not be built
CMake Warning (dev) at /usr/local/lib/cmake/vtk-9.0/vtkModule.cmake:2847 (message):
No `MODULES` passed to `vtk_modules_autoinit`.
Call Stack (most recent call first):
src/Cxx/DataStructures/CMakeLists.txt:48 (vtk_module_autoinit)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at /usr/local/lib/cmake/vtk-9.0/vtkModule.cmake:2847 (message):
No `MODULES` passed to `vtk_modules_autoinit`.
src/Cxx/DataStructures/CMakeLists.txt:48 (vtk_module_autoinit)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at /usr/local/lib/cmake/vtk-9.0/vtkModule.cmake:2847 (message):
No `MODULES` passed to `vtk_modules_autoinit`.
Call Stack (most recent call first):
src/Cxx/DataStructures/CMakeLists.txt:48 (vtk_module_autoinit)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at /usr/local/lib/cmake/vtk-9.0/vtkModule.cmake:2847 (message):
No `MODULES` passed to `vtk_modules_autoinit`.
Call Stack (most recent call first):
src/Cxx/DataStructures/CMakeLists.txt:48 (vtk_module_autoinit)
This warning is for project developers. Use -Wno-dev to suppress it.
The "No MODULES passed to vtk_modules_autoinit" error message is repeated over 400 times, and no Makefile is generated.
What am I doing wrong???
Thanks!

Related

Install Azure IoT Edge on ubuntu 14.04?

I am following this(https://learn.microsoft.com/en-us/azure/iot-hub/iot-hub-windows-iot-edge-simulated-device#before-you-get-started) article to install Azure IoT Edge.
But when runs tools\build.cmd --disable-native-remote-modules command, it gives error.
~/iot-edge/build ~/iot-edge
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.8.4
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- CMake Install Prefix is /usr/local
-- Looking for x86_64
-- Looking for x86_64 - found
-- AIG architecture: x86_64
-- AIG architecture: x86_64
-- ctest not found...
-- Building ctest...
Submodule 'deps/ctest' (https://github.com/azure/azure-ctest) registered for path 'deps/ctest'
Cloning into 'deps/ctest'...
remote: Counting objects: 250, done.
remote: Total 250 (delta 0), reused 0 (delta 0), pack-reused 250
Receiving objects: 100% (250/250), 164.34 KiB | 0 bytes/s, done.
Resolving deltas: 100% (121/121), done.
Checking connectivity... done.
fatal: reference is not a tree: 037e318716e37eba358424380659dd1cd6d0554e
Unable to checkout '037e318716e37eba358424380659dd1cd6d0554e' in submodule path 'deps/ctest'
CMake Error at gatewayFunctions.cmake:122 (message):
Error pulling submodules: 1
Call Stack (most recent call first):
dependencies-test.cmake:9 (findAndInstall)
CMakeLists.txt:207 (include)
-- Configuring incomplete, errors occurred!
See also "/root/iot-edge/build/CMakeFiles/CMakeOutput.log".
Could you tell me, what may be the problem ?
Note that Azure IoT Edge has been updated and now is based on Docker containers and fully supports Ubuntu as a host. Check out the new docs:https://learn.microsoft.com/en-us/azure/iot-edge/how-iot-edge-works

CMake: find_library result depends on selected compiler?

I'm confused about how find_library is supposed to work, and I don't know if this could be a CMake bug, or a misuse or misconfiguration on my part. I have installed both GCC and PGI compilers, and when I try this simple CMakeLists.txt file (with both 2.8.11 and 3.5.1):
cmake_minimum_required(VERSION 2.8.11)
find_library( LIBdl dl )
message("LIBdl ${LIBdl}")
I get the following:
$ CC=gcc CXX=g++ cmake .
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.8.4
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/g++
-- Check for working CXX compiler: /usr/bin/g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
LIBdl /usr/lib/x86_64-linux-gnu/libdl.so
-- Configuring done
-- Generating done
-- Build files have been written to: /home/molcas-test/test/cmake
That's OK, but:
$ CC=pgcc CXX=pgc++ cmake .
-- The C compiler identification is PGI 17.1.0
-- The CXX compiler identification is PGI 17.1.0
-- Check for working C compiler: /opt/pgi/linux86-64/17.1/bin/pgcc
-- Check for working C compiler: /opt/pgi/linux86-64/17.1/bin/pgcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /opt/pgi/linux86-64/17.1/bin/pgc++
-- Check for working CXX compiler: /opt/pgi/linux86-64/17.1/bin/pgc++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
LIBdl LIBdl-NOTFOUND
-- Configuring done
-- Generating done
-- Build files have been written to: /home/molcas-test/test/cmake
Note dl was not found.
Leaving out either pgcc or pgc++ causes the library to be found, so it must be something in how the compilers are configured. And yet just compiling from the command line finds dl without complain:
$ pgcc -ldl hello_world.c -o hello_world
$ ./hello_world
Hello world!
So I believe something's not right if pgcc can find the library and CMake can't. I could of course set LIB=/usr/lib/x86_64-linux-gnu before running cmake, to force a search in that directory, but that doesn't feel right.
It seems the problem is with gcc. I get /lib/x86_64-linux-gnu included in CMAKE_C_IMPLICIT_LINK_DIRECTORIES, so CMAKE_LIBRARY_ARCHITECTURE is set. But with pgcc this directory is absent and CMAKE_LIBRARY_ARCHITECTURE is empty.
And the directory is missing with pgcc, because pgcc -v doesn't include a -L/lib/x86_64-linux-gnu flag, while gcc -v does. However, ld finds libraries in the directory in either case.
So CMake is not searching libraries in the same places as ld. Should it? Is there an easy way to change this, other than, e.g., manually inspecting all files in /etc/ld.so.conf.d and setting the LIB environment variable?

Compiling OpenVAS-SMB on Debian Stretch

I'm trying to build the OpenVAS-SMB plugin on Debian Stretch from source, but it fails, although it builds successfully with the same prerequisites on Debian Jessie.
CMake confirms all required dependencies before starting to build:
root#xxxx:/home/xxxx/openvas-smb-1.0.2# cmake . && make
-- The C compiler identification is GNU 6.3.0
-- The CXX compiler identification is GNU 6.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found Perl: /usr/bin/perl (found version "5.24.1")
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29")
-- Checking for module 'popt'
-- Found popt, version 1.16
-- Found Popt: /usr/lib/x86_64-linux-gnu/libpopt.so
-- Found GSSAPI: /usr/lib/x86_64-linux-gnu/libcom_err.so
-- Install prefix: /usr/local
-- Checking for module 'gnutls>=3.2.15'
-- Found gnutls, version 3.5.8
-- Checking for module 'glib-2.0'
-- Found glib-2.0, version 2.50.3
-- Found GnuTLS: /usr/lib/x86_64-linux-gnu/libgnutls.so (found version "3.5.8")
-- Looking for xmltoman...
-- Looking for xmltoman... /usr/bin/xmltoman
-- Looking for xmlmantohtml... /usr/bin/xmlmantohtml
-- Found Doxygen: /usr/bin/doxygen (found version "1.8.13")
-- Configuring done
-- Generating done
It builds samba and the libs correctly, but fails when it comes to winexe:
../samba/libsamba-static.a(kerberos.c.o): In function `kerberos_kinit_password_cc':
kerberos.c:(.text+0x124): undefined reference to `krb5_get_init_creds_opt_init'
kerberos.c:(.text+0x133): undefined reference to `krb5_get_init_creds_opt_set_default_flags'
kerberos.c:(.text+0x153): undefined reference to `krb5_get_init_creds_password'
kerberos.c:(.text+0x182): undefined reference to `krb5_cc_initialize'
kerberos.c:(.text+0x196): undefined reference to `krb5_cc_store_cred'
kerberos.c:(.text+0x1d2): undefined reference to `krb5_free_cred_contents'
kerberos.c:(.text+0x1e7): undefined reference to `krb5_free_cred_contents'
collect2: error: ld returned 1 exit status
winexe/CMakeFiles/winexe.dir/build.make:186: recipe for target 'winexe/winexe' failed
make[2]: *** [winexe/winexe] Error 1
CMakeFiles/Makefile2:145: recipe for target 'winexe/CMakeFiles/winexe.dir/all' failed
make[1]: *** [winexe/CMakeFiles/winexe.dir/all] Error 2
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2
I'm guessing that there's an issue with either heimdal-dev or the libglib2.0-dev causing this.
These are the requirements for building OpenVAS-SMB besides the typical build tools: gcc-mingw-w64 libgnutls28-dev perl-base heimdal-dev heimdal-multidev libpopt-dev libglib2.0-dev
Anyone know of any differences between the libs that could make the build fail on Stretch, but work on Jessie? Or maybe can provide a hint on how to do further troubleshooting?
Thanks!

cmake kdev-executebrowser plugin for kdevelop

I am trying to install kdev-executebrowser from https://github.com/KDE/kdev-executebrowser into kdevelop.
So I cloned the plugin from git hub and tried to cmake and got an error (please check the quote below).
I can't figure how how to solve this. Please help
I also attached my system info and hope it might help
System Info
waleed#waleed-Dell-System-Inspiron-N411Z:~/Downloads/kdev-executebrowser$
cmake .
-- The C compiler identification is GNU 5.4.0
-- The CXX compiler identification is GNU 5.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done CMake Error at /usr/share/cmake-3.5/Modules/FindKDE4.cmake:111
(message):
ERROR: cmake/modules/FindKDE4Internal.cmake not found in
/home/waleed/.kde/share/apps;/usr/share/kubuntu-default-settings/kde4-profile/default/share/apps;/usr/share/kde4/apps Call Stack (most recent call first):
CMakeLists.txt:6 (find_package)
-- Configuring incomplete, errors occurred! See also
"/home/waleed/Downloads/kdev-executebrowser/CMakeFiles/CMakeOutput.log".
FindKDE4Internal.cmake
http://packages.ubuntu.com/search?searchon=contents&keywords=FindKDE4Internal.cmake&mode=exactfilename&suite=saucy&arch=any
The missing package is usually kdelibs5-dev.

cmake error with a software bam-window software

I am trying to install the tool bam-window but I am getting cmake error. I downloaded the bam-window-master.zip in linux. The link of the tool is hosted in git https://github.com/genome-vendor/bam-window. I downloaded and follow the below commands.
unzip bam-window-master.zip
cd bam-window-master
mkdir build
cd build
cmake ..
On doing cmake .. After compiling I for a while I get an error
-- The C compiler identification is GNU 4.7.2
-- The CXX compiler identification is GNU 4.7.2
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found Git: /usr/bin/git (found version "1.7.10.4")
CMake Error at cmake/GitHelper.cmake:15 (message):
Failed to get git revision, abort: fatal: Not a git repository (or any
parent up to mount point /scratch/GT)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
!
Call Stack (most recent call first):
CMakeLists.txt:9 (get_git_version_info)
How do I get rid of this and make the installation proper?
The CMakeLists.txt for this project assumes (unfortunately) that the source code is not downloaded as a zip file, but instead cloned from github.
So instead of using "Dowload ZIP" link, just clone it using regular GIT commands:
git clone https://github.com/genome-vendor/bam-window.git

Resources