У меня есть libeigen3 от официального установленного repo:
$ sudo apt-get install libeigen3-dev
[sudo] password for nicolas:
Reading package lists... Done
Building dependency tree
Reading state information... Done
libeigen3-dev is already the newest version (3.3~beta1-2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
это говорит, что это - 3,3 версии, как эта команда делает:
$ dpkg -s libeigen3-dev | grep 'Version'
Version: 3.3~beta1-2
Однако версия в файле /usr/lib/cmake/eigen3/Eigen3Config.cmake
установлен на:
set ( EIGEN3_VERSION_STRING "3.2.92" )
Интересно почему? И как я мог зафиксировать это, потому что мне нужен, по крайней мере, Eigen3.3 для создать другое программное обеспечение.
Можно загрузить собственный непосредственно с его основного веб-сайта:
http://eigen.tuxfamily.org/index.php?title=Main_Page
Наконец, следуйте инструкциям в INSTALL
файл:
$ cat INSTALL Installation instructions for Eigen
***********************************
Explanation before starting
***************************
Eigen consists only of header files, hence there is nothing to compile
before you can use it. Moreover, these header files do not depend on your
platform, they are the same for everybody.
Method 1. Installing without using CMake
****************************************
You can use right away the headers in the Eigen/ subdirectory. In order
to install, just copy this Eigen/ subdirectory to your favorite location.
If you also want the unsupported features, copy the unsupported/
subdirectory too.
Method 2. Installing using CMake
********************************
Let's call this directory 'source_dir' (where this INSTALL file is).
Before starting, create another directory which we will call 'build_dir'.
Do:
cd build_dir
cmake source_dir
make install
The "make install" step may require administrator privileges.
You can adjust the installation destination (the "prefix")
by passing the -DCMAKE_INSTALL_PREFIX=myprefix option to cmake, as is
explained in the message that cmake prints at the end.
Не забывайте связываться с этими новыми библиотеками в cmake для любой программы с помощью него, если они установлены параллельно от официальных!;)
sudo dpkg -i libeigen3-dev_3.3.4-4_all.deb
(или безотносительно версии Вы загрузили). Это должно работать безупречное, так как нет трудных зависимостей.