cmake failed to configure due to GL.h - cmake

I am trying to build cmake 3.10.2 from source.
I already have cmake installed but an older version so I am running
cmake .
make
make install
but the machine I am on doesn't have gl and cmake fails on missing gl/gl.h is there a way to not require gl.h?

Related

Use CMake binares to build cpp projects without installing CMake

I want to use specific version of CMake 3.19.0 for Ubuntu 14.04 (32-bits) without installing CMake (use only binaries).
I tried to build CMake 3.19.0 on my test machine. It builded and installed successfully. In install_manifest.txt I see lot of files that were installed on my test system.
So, I tried to copy only installed binaries from /usr/local/bin/ (this is default path where CMake binaries were installed) and paste it to another machine that doesn't know about CMake. I paste 3 binaries: cmake, ctest, cpack to /usr/local/bin/.
If I run which cmake it shows path:
/usr/local/bin/cmake
If I run cmake --verison it shows:
CMake Error: Could not find CMAKE_ROOT !!!
CMake has most likely not been installed correctly.
Modules directory not found in
/usr/local/share/cmake-3.19
cmake version 3.19.0
CMake suite maintained and supported by Kitware (kitware.com/cmake).
It looks like CMake needs some modules that I haven't copied yet. I tried to build my cpp project and it shows me:
CMake Error: Could not find CMAKE_ROOT !!!
CMake has most likely not been installed correctly.
Modules directory not found in
/usr/local/share/cmake-3.19
CMake Error: Error executing cmake::LoadCache(). Aborting.
What are the minimum required modules needed for stable building? And where I should copy it?
Just copied builded Modules and Templates directories from cmake-3.19.0 build directory to /usr/local/share/cmake-3.19

cmake 3.12 version installation on RHEL 7

I had cmake 3.9 version on my RHEL 7.6 system. But for some development work, i need 3.12 version.
I downloaded the https://cmake.org/files/v3.12/cmake-3.12.2.tar.gz. Untarred the tar file and
Executed the commands trying to install it. But I am getting errors in each of the below case.
Can anyone please let me know if you have any idea to fix it and get the latest version?
1st trial
./bootstrap --prefix=$HOME
make;make install
CMake Error at cmake_install.cmake:82 (file):
file failed to open for writing (Permission denied):
/workspace/poomanju/_cmake_build/cmake-3.12.2/install_manifest.txt
2nd trial
./bootstrap
make;make install.
3rd trial
./configure
make;make install
I tried the command being root. It seems the installation completes successfully. But when I come out of root privilege and view the version as regular user, I see the version is still 3.9.
bash-4.2$ /usr/local/bin/cmake --version
cmake version 3.12.2
CMake suite maintained and supported by Kitware (kitware.com/cmake).
bash-4.2$ which cmake
/usr/local/bin/cmake
bash-4.2$ cmake --version
CMake Error: Could not find CMAKE_ROOT !!!
CMake has most likely not been installed correctly.
Modules directory not found in
/usr/local/share/cmake-3.9
cmake version 3.9.6
CMake suite maintained and supported by Kitware (kitware.com/cmake).

cmake version in catkin_make different from global cmake version?

I'm trying to build some package in ROS using catkin.
When I run catkin_make in the top level directory, I got complaint about cmake version:
CMake Error at /usr/lib/x86_64-linux-gnu/cmake/ignition-math4/ignition-math4-config.cmake:26 (cmake_minimum_required):
CMake 3.5.1 or higher is required. You are running version 3.3.2
Then I updated my cmake version, and also modified the path. I verified that the version of cmake is now 3.15:
~/catkin_ws$ cmake --version
cmake version 3.15.0
CMake suite maintained and supported by Kitware (kitware.com/cmake).
when I go back and try catkin_make again, the problem still remains.
I suppose that catkin has defined its own path or environment variable somewhere and are using cmake from a different place, but I couldn't figure out how to change it. Any suggestions? Thanks in advance.
--Kevin
you could remove .catkin_tools from your working directory, and redo the initialization of catkin:
source /opt/ros/<your-ros-development>/setup.bash
and
catkin init
if your environment setup is correct, that should do the trick.

cmake 3.11 installation in solaris11

I am new to solaris 11 machine. I have a vitual box and I can only interact via command promt. I am trying to install cmake 3.11 version. I tried downloading cmake source code and building it. But failed at one point where in code uses c++11 and the our gcc compiler is not able to compile it.
It will be very greatfull if anyone can give me steps for installing and using cmake in solaris11.
Thanks in advance.
Solaris 11 offers a cmake package in its package repos, so pkg install cmake as root should do it.

installation of cmake on debian 8

I tried to install mcsema on my debian linux but I am stopped by error
Cmake 3.1 or higher is required. You are running 3.0.2. On debian this is the only version could be installed by apt-get install. Building CMake from sources, I get several errors as well. Does anyone know how to install the latest version of Cmake on Debian 8?
Download latests cmake release and follow the README.rst instructions:
UNIX/Mac OSX/MinGW/MSYS/Cygwin ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
You need to have a compiler and a make installed. Run the
bootstrap script you find in the source directory of CMake. You
can use the --help option to see the supported options. You may
use the --prefix=<install_prefix> option to specify a custom
installation directory for CMake. You can run the bootstrap script
from within the CMake source directory or any other build directory of
your choice. Once this has finished successfully, run make and
make install. In summary::
$ ./bootstrap && make && make install