-
Notifications
You must be signed in to change notification settings - Fork 52
Open
Description
Ошибка при попытке собрать под Orange Pi Zero2.
OS: Ubuntu 20.04 (4.9.170.7)
root@orangepizero2:~/co2mon/build# cmake ..
-- The C compiler identification is GNU 9.4.0
-- The CXX compiler identification is GNU 9.4.0
-- 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
-- Detecting C compile features
-- Detecting C compile features - 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
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1")
-- Checking for one of the modules 'hidapi-libusb;hidapi'
-- Looking for libusb_strerror
-- Looking for libusb_strerror - not found
-- Configuring done
-- Generating done
-- Build files have been written to: /root/co2mon/build
root@orangepizero2:~/co2mon/build# make
Scanning dependencies of target co2mon
[ 25%] Building C object libco2mon/CMakeFiles/co2mon.dir/src/co2mon.c.o
/root/co2mon/libco2mon/src/co2mon.c: In function ‘co2mon_open_device’:
/root/co2mon/libco2mon/src/co2mon.c:59:39: warning: implicit declaration of function ‘hid_get_device_info’ [-Wimplicit-function-declaration]
59 | struct hid_device_info *hdi = hid_get_device_info(dev);
| ^~~~~~~~~~~~~~~~~~~
/root/co2mon/libco2mon/src/co2mon.c:59:39: warning: initialization of ‘struct hid_device_info *’ from ‘int’ makes pointer from integer without a cast [-Wint-conversion]
[ 50%] Linking C static library libco2mon.a
[ 50%] Built target co2mon
Scanning dependencies of target co2mond
[ 75%] Building C object co2mond/CMakeFiles/co2mond.dir/src/main.c.o
[100%] Linking C executable co2mond
/usr/bin/ld: ../libco2mon/libco2mon.a(co2mon.c.o): in function `co2mon_open_device':
co2mon.c:(.text+0x114): undefined reference to `hid_get_device_info'
collect2: error: ld returned 1 exit status
make[2]: *** [co2mond/CMakeFiles/co2mond.dir/build.make:85: co2mond/co2mond] Error 1
make[1]: *** [CMakeFiles/Makefile2:142: co2mond/CMakeFiles/co2mond.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
Metadata
Metadata
Assignees
Labels
No labels