patrickfrey / strus

Library implementing the storage and the query evaluation for a text search engine. It uses on a key value store database interface to store its data. Currently there exists an implementation based on the google LevelDB library.
http://www.project-strus.net
Mozilla Public License 2.0
47 stars 1 forks source link

cmake relocation fails #68

Closed andreasbaumann closed 8 years ago

andreasbaumann commented 8 years ago

Installing into /opt/strus with -DCMAKE_INSTALL_PREFIX=/opt/strus fails.

The probing of the strus packages works, I see:

-- Setting strusbase prefix path to /opt/strus
-- Set strusbase include directories to /opt/strus/include
-- Set strusbase linking directories to /opt/strus/lib/strus

but not one variable is actually used in the CMake files:

[ 53%] Building CXX object src/queryproc/utils/CMakeFiles/queryproc_utils.dir/positionWindow.cpp.o
cd /home/build/strus/build/src/queryproc/utils && /usr/bin/c++    -I/home/build/strus/include -I/home/build/strus/src/queryproc/utils  -std=c++98  -Wall -pedantic -g -Wfatal-errors -fvisibility=hidden -fPIC -O3 -O3 -DNDEBUG   -o CMakeFiles/queryproc_utils.dir/positionWindow.cpp.o -c /home/build/strus/src/queryproc/utils/positionWindow.cpp
In file included from /home/build/strus/src/queryproc/utils/positionWindow.cpp:8:0:
/home/build/strus/src/queryproc/utils/positionWindow.hpp:12:31: fatal error: strus/base/stdint.h: No such file or directory
 #include "strus/base/stdint.h"

for instance ../src/queryproc/utils/CMakeLists.txt:

include_directories(
  "${Boost_INCLUDE_DIRS}"
  "${PROJECT_SOURCE_DIR}/include"
  "${PROJECT_SOURCE_DIR}/src/queryproc/utils"
)

The variables strusbase_INCLUDE_DIRS and strusbase_LIBRARY_DIRS should be added everywhere where needed.

andreasbaumann commented 8 years ago

And if a standard path is found it must NOT be included in find_strus_package.cmake..

andreasbaumann commented 8 years ago

For testing we should install strusBase, strus, strusAnalyzer, etc. in seprate directories: /opt/strusBase, /opt/strus, /opt/strusAnalyzer, etc. Otherwise we cannot be sure we got all the places right where the vairables have to be set. But this also means that the find_package mechanism has to be improved (for instance adding cmake variables where we can set the directories by hand).

andreasbaumann commented 8 years ago

This bug applies to other repos? Checking..