bayfere.blogg.se

Cmake install file
Cmake install file












cmake install file

Note also that the -DCMAKE_INSTALL_PREFIX flag will change the location where the Python plugins are installed, so you may need to change the Python module search path via the PYTHONPATH environment variable. See also below for how to change the installation directories for Octave, Matlab, and Guile plugins, if you are installing those. However, now when you compile code using NLopt, you will need to tell the compiler where to find the NLopt header files (using -I) and libraries (using -L) with something like: cc -I$HOME/install/include myprogram.c -L$HOME/install/lib -lnlopt -lm -o myprogram This will create the directories $HOME/install/lib etcetera and install NLopt into them. You would do: cmake -DCMAKE_INSTALL_PREFIX=$HOME/install. You can do this using the CMAKE_INSTALL_PREFIX variable of the cmake utility.įor example, suppose that you want to install into the install subdirectory of your home directory ( $HOME). You may wish to install NLopt in a directory other than /usr/local, especially if you do not have administrator access to your machine.

cmake install file

In the following, we describe a few details of this installation process, including how to change the installation location. Then install the NLopt libraries and header files via: sudo make installīy default, this installs the NLopt shared library ( libnlopt.so) in /usr/local/lib and the NLopt header file ( nlopt.h) in /usr/local/include, as well manual pages and a few other files. In particular, NLopt uses the standard CMake cmake build system, which means that you compile it via: mkdir build

cmake install file

It doesn't require any particular packages to be installed except for a C compiler, although you need to have Octave and/or Matlab installed if you want to install the Octave and/or Matlab plugins, respectively. The installation of NLopt is fairly standard and straightforward, at least on Unix-like systems (GNU/Linux is fine).














Cmake install file