spike@home:~/co2mon-master$ cmake CMakeLists.txt
-- 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
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.26")
-- checking for one of the modules 'hidapi-libusb;hidapi'
CMake Error at /usr/share/cmake-2.8/Modules/FindPkgConfig.cmake:367 (message):
None of the required 'hidapi-libusb;hidapi' found
Call Stack (most recent call first):
libco2mon/CMakeLists.txt:7 (pkg_search_module)
-- Looking for libusb_strerror
-- Looking for libusb_strerror - not found
-- checking for one of the modules 'hidapi-libusb;hidapi'
CMake Error at /usr/share/cmake-2.8/Modules/FindPkgConfig.cmake:367 (message):
None of the required 'hidapi-libusb;hidapi' found
Call Stack (most recent call first):
co2mond/CMakeLists.txt:5 (pkg_search_module)
-- Configuring incomplete, errors occurred!
See also "/home/spike/co2mon-master/CMakeFiles/CMakeOutput.log".
See also "/home/spike/co2mon-master/CMakeFiles/CMakeError.log".
spike@home:~/co2mon-master$
Determining if the libusb_strerror exist failed with the following output:
Change Dir: /home/spike/co2mon-master/CMakeFiles/CMakeTmp
Run Build Command:/usr/bin/make "cmTryCompileExec1130740830/fast"
/usr/bin/make -f CMakeFiles/cmTryCompileExec1130740830.dir/build.make CMakeFiles/cmTryCompileExec1130740830.dir/build
make[1]: Вход в каталог `/home/spike/co2mon-master/CMakeFiles/CMakeTmp'
/usr/bin/cmake -E cmake_progress_report /home/spike/co2mon-master/CMakeFiles/CMakeTmp/CMakeFiles 1
Building C object CMakeFiles/cmTryCompileExec1130740830.dir/CheckSymbolExists.c.o
/usr/bin/cc -std=c99 -o CMakeFiles/cmTryCompileExec1130740830.dir/CheckSymbolExists.c.o -c /home/spike/co2mon-master/CMakeFiles/CMakeTmp/CheckSymbolExists.c
/home/spike/co2mon-master/CMakeFiles/CMakeTmp/CheckSymbolExists.c:2:20: fatal error: libusb.h: Нет такого файла или каталога
#include <libusb.h>
^
compilation terminated.
make[1]: *** [CMakeFiles/cmTryCompileExec1130740830.dir/CheckSymbolExists.c.o] Ошибка 1
make[1]: Выход из каталога `/home/spike/co2mon-master/CMakeFiles/CMakeTmp'
make: *** [cmTryCompileExec1130740830/fast] Ошибка 2
File /home/spike/co2mon-master/CMakeFiles/CMakeTmp/CheckSymbolExists.c:
/* */
#include <libusb.h>
int main(int argc, char** argv)
{
(void)argv;
#ifndef libusb_strerror
return ((int*)(&libusb_strerror))[argc];
#else
(void)argc;
return 0;
#endif
}
AvReg - По для организации Видеонаблюдения на Linux. ДЭНСИ:КАССА - Рабочее место кассира под Linux. Терминальные решения под Linux
Консультации по установке 1с+PostgreSQL+Ubuntu.
-- checking for one of the modules 'hidapi-libusb;hidapi'
CMake Error at /usr/share/cmake-2.8/Modules/FindPkgConfig.cmake:367 (message):
None of the required 'hidapi-libusb;hidapi' found
Нет, это библиотека. Да и не проверяется наличие модулей ядра при сборке чего бы то ни было (по крайней мере я ни разу ткого не встречал). А что cmake говорит про «модули» — для него в порядке вещей.
Дополнение: при использовании cmake, чтобы не захламлять каталог с исходниками (и избежать перезаписывания файлов в случае криворукости разработчика), лучше сборку производить в подкаталоге, примерно так: mkdir build cd build cmake .. make
Собственно, в README.md ровно так и написано.
но теперь другая проблема при запуске программы выдается ошибка:
co2mond
hid_open: error
Unable to open CO2 device
hid_open: error
hid_open: error
hid_open: error
hid_open: error
hid_open: error
hid_open: error
hid_open: error
AvReg - По для организации Видеонаблюдения на Linux. ДЭНСИ:КАССА - Рабочее место кассира под Linux. Терминальные решения под Linux
Консультации по установке 1с+PostgreSQL+Ubuntu.
Спасибо. под рутом заработало...
Теперь бы еще какой-нибудь графический интерфей чтобы строил графики...
AvReg - По для организации Видеонаблюдения на Linux. ДЭНСИ:КАССА - Рабочее место кассира под Linux. Терминальные решения под Linux
Консультации по установке 1с+PostgreSQL+Ubuntu.