Project Link: https://github.com/stytim/k4a-calibration
I want to run the project but it can't compile
Error message
[ 33%] Building CXX object CMakeFiles/calib_k4a.dir/src/camera_extrinsics.cpp.o
/home/ccnam/Downloads/k4a-calibration/src/camera_extrinsics.cpp: In member function ‘bool ExtrinsicsCalibration::CalculateExtrinsics(const std::vector<FrameInfo>&, std::vector<AlignmentTransform>&)’:
/home/ccnam/Downloads/k4a-calibration/src/camera_extrinsics.cpp:213:51: error: ‘cv::Ptr<cv::aruco::Dictionary> cv::aruco::Board::dictionary’ is protected within this context
cv::aruco::detectMarkers(gray, board->dictionary, markerCorners, markerIds, params);
^~~~~~~~~~
In file included from /usr/local/include/opencv4/opencv2/aruco_detector.hpp:6:0,
from /usr/local/include/opencv4/opencv2/aruco.hpp:7,
from /usr/local/include/opencv4/opencv2/aruco/charuco.hpp:9,
from /home/ccnam/Downloads/k4a-calibration/include/camera_extrinsics.hpp:11,
from /home/ccnam/Downloads/k4a-calibration/src/camera_extrinsics.cpp:1:
/usr/local/include/opencv4/opencv2/aruco/board.hpp:89:29: note: declared protected here
CV_PROP Ptr<Dictionary> dictionary;
^~~~~~~~~~
CMakeFiles/calib_k4a.dir/build.make:75: recipe for target 'CMakeFiles/calib_k4a.dir/src/camera_extrinsics.cpp.o' failed
make[2]: *** [CMakeFiles/calib_k4a.dir/src/camera_extrinsics.cpp.o] Error 1
CMakeFiles/Makefile2:82: recipe for target 'CMakeFiles/calib_k4a.dir/all' failed
make[1]: *** [CMakeFiles/calib_k4a.dir/all] Error 2
Makefile:90: recipe for target 'all' failed
make: *** [all] Error 2
Step
git clone https://github.com/stytim/k4a-calibration.git
cd k4a-calibration
mkdir build && cd build
cmake ..
make
Environment
Ubuntu 18.04
Change it to board->getDictionary(). When you use project dependencies with newer versions then you need to deal with the involved changes.
Related
I am trying to build this github repository: https://github.com/socketio/socket.io-client-cpp
It is dependant on this repository https://github.com/zaphoyd/websocketpp
I got a few downloads while trying to build both and solved most with downloading libboost-dev and a few other libraries but i got an error that i can't seem to solve:
/home/ktbm/socket.io-client-cpp/src/internal/sio_client_impl.cpp: In member function ‘sio::client_impl::context_ptr sio::client_impl::on_tls_init(websocketpp::connection_hdl)’:
/home/ktbm/socket.io-client-cpp/src/internal/sio_client_impl.cpp:586:83: error: ‘tls’ is not a member of ‘asio::ssl::context’
context_ptr ctx = context_ptr(new asio::ssl::context(asio::ssl::context::tls));
^~~
CMakeFiles/sioclient_tls.dir/build.make:110: recipe for target 'CMakeFiles/sioclient_tls.dir/src/internal/sio_client_impl.cpp.o' failed
make[2]: *** [CMakeFiles/sioclient_tls.dir/src/internal/sio_client_impl.cpp.o] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/sioclient_tls.dir/all' failed
make[1]: *** [CMakeFiles/sioclient_tls.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
I haven't found anyone with a similar problem and i am not sure which library causes this issue, probably an old asio library but could also be a boost error
I am trying to install OpenOnload on an AWS server running Ubuntu server 18.04.3. I downloaded the DEB release package from version 7.1.0.265 (the latest) from here: https://support.solarflare.com/index.php/component/cognidox/?view=categories&id=361
and then extract out of it just the folder \onload_7.1.0.265-debiansource.tgz\onload_7.1.0.265.orig.tar.gz and untar that. Then I can run
$ ./scripts/onload_install
as per the instructions in the README file. On Ubuntu 20 on my local machine this all worked and installed OpenOnload fine but on an AWS server instance this error is thrown:
onload_install: Building Onload.
Build tree made for linux as x86_64_linux-4.15.0-1057-aws
make: Entering directory '/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws'
# Build both autocompat.h files: linux_net and linux_affinity.
make -C driver/linux_net
make[1]: Entering directory '/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net'
make -C /usr/src/linux-headers-4.15.0-1057-aws CC="cc" M=$(pwd)
make[2]: Entering directory '/usr/src/linux-headers-4.15.0-1057-aws'
/home/ubuntu/onload-7.1.0.265/src/driver/linux_net/Makefile:61: SFE4001/Falcon is no longer supported
CHK /home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/autocompat.h
UPD /home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/autocompat.h
CHK /home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/config.h
UPD /home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/config.h
CC [M] /home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.o
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c: In function ‘efx_init_struct’:
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c:5225:2: error: implicit declaration of function ‘efx_mtd_free’; did you mean ‘efx_mtd_probe’? [-Werror=implicit-function-declaration]
efx_mtd_free(efx);
^~~~~~~~~~~~
efx_mtd_probe
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c:5224:1: warning: label ‘fail’ defined but not used [-Wunused-label]
fail:
^~~~
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c: In function ‘efx_fini_struct’:
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c:5247:9: error: ‘struct efx_nic’ has no member named ‘mtd_struct’
if (efx->mtd_struct) {
^~
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c:5248:6: error: ‘struct efx_nic’ has no member named ‘mtd_struct’
efx->mtd_struct->efx = NULL;
^~
/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.c:5249:6: error: ‘struct efx_nic’ has no member named ‘mtd_struct’
efx->mtd_struct = NULL;
^~
cc1: some warnings being treated as errors
scripts/Makefile.build:330: recipe for target '/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.o' failed
make[3]: *** [/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net/efx.o] Error 1
Makefile:1580: recipe for target '_module_/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net' failed
make[2]: *** [_module_/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net] Error 2
make[2]: Leaving directory '/usr/src/linux-headers-4.15.0-1057-aws'
/home/ubuntu/onload-7.1.0.265/src/driver/linux_net/Makefile:300: recipe for target 'modules' failed
make[1]: *** [modules] Error 2
make[1]: Leaving directory '/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws/driver/linux_net'
../../src/mmake.mk:57: recipe for target 'all' failed
make: *** [all] Error 2
make: Leaving directory '/home/ubuntu/onload-7.1.0.265/build/x86_64_linux-4.15.0-1057-aws'
onload_build: ERROR: Failed to build driver components.
onload_install: ERROR: Build failed. Not installing.
Could this be due to incompatibility with some specific features on AWS? I checked the version compatibility for the downloaded source and it says compatible with Ubuntu server 18.04. Any ideas on how to fix it would be greatly appreciated!
Based on the comments.
The solution was to use Onload-7.0.0.176 instead of Onload-7.1.0.265.
Seems version Onload-7.1.0.265 has some compilation bugs on Ubuntu 18.04.
I am following this guide to install gRPC using CMake. First, it is actually not usable from a CMake project without tweaking the CMake command according to this other post. So I did, the configuration part works. When I run make though, it fails like this
In file included from /mnt/c/Program Files/grpc/include/ares.h:22:0,
from /mnt/c/Users/j*****/sources/grpc/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.cc:23:
/mnt/c/Program Files/grpc/include/ares_build.h:26:12: fatal error: winsock2.h: No such file or directory
# include <winsock2.h>
^~~~~~~~~~~~
compilation terminated.
CMakeFiles/grpc.dir/build.make:4768: recipe for target 'CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.cc.o' failed
make[2]: *** [CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver.cc.o] Error 1
[ 85%] Building CXX object CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper_fallback.cc.o
make[2]: *** Waiting for unfinished jobs....
In file included from /mnt/c/Program Files/grpc/include/ares.h:22:0,
from /mnt/c/Users/j*****/sources/grpc/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc:23:
/mnt/c/Program Files/grpc/include/ares_build.h:26:12: fatal error: winsock2.h: No such file or directory
# include <winsock2.h>
^~~~~~~~~~~~
compilation terminated.
CMakeFiles/grpc.dir/build.make:4794: recipe for target 'CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc.o' failed
make[2]: *** [CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc.o] Error 1
In file included from /mnt/c/Program Files/grpc/include/ares.h:22:0,
from /mnt/c/Users/j*****/sources/grpc/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc:29:
/mnt/c/Program Files/grpc/include/ares_build.h:26:12: fatal error: winsock2.h: No such file or directory
# include <winsock2.h>
^~~~~~~~~~~~
compilation terminated.
CMakeFiles/grpc.dir/build.make:4820: recipe for target 'CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc.o' failed
make[2]: *** [CMakeFiles/grpc.dir/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc.o] Error 1
CMakeFiles/Makefile2:702: recipe for target 'CMakeFiles/grpc.dir/all' failed
make[1]: *** [CMakeFiles/grpc.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
Am I supposed to install something that is not documented ?
I am new to Google's protocol buffers and I am having trouble with cross-compiling it for arm. I am not able to find any concrete solutions to my problem using google.
The steps I am following:
./autogen.sh
./configure
make -s && make install
./configure --host=arm-linux-gnueabi CC=arm-linux-gnueabi-gcc --prefix=/opt/poky/1.7/sysroots/cortexa9hf-vfp-neon-poky-linux-gnueabi/usr/ --with-protoc=/usr/local/bin/protoc
make
I get an error when I run make.
google/protobuf/stubs/common.cc:55:2: error: #error "No suitable threading library available."
#error "No suitable threading library available."
^
Makefile:3956: recipe for target 'google/protobuf/stubs/common.lo' failed
make[2]: *** [google/protobuf/stubs/common.lo] Error 1
make[2]: Leaving directory '/home/protobuf/protobuf/src'
Makefile:1544: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/protobuf/protobuf'
Makefile:1451: recipe for target 'all' failed
make: *** [all] Error 2
Any help would be much appreciated.
I built omniORB-4.2.1 by VS2013+Cygwin(0.9.1-1) on Windows7 32bit.
I placed omniORB under C drive.
Then I tried to build SALOME-KERNEL by MinGW and got following error message related to omniORB.
[5%] Building CXX object idl/CMakeFiles/SalomeIDLKernel.dir/SALOME_ExceptionSK
.cc.obj
In file included from C:/omniORB-4.2.1/include/omniORB4/CORBA.h:221:0,
from c:/src/salome7/buildKernel/idl/SALOME_Exception.hh:6,
from c:/src/salome7/buildKernel/idl/SALOME_ExceptionSK.cc:3:
C:/omniORB-4.2.1/include/omniORB4/dynAny.h:151:47: error: 'CORBA::LongDoubleSeq'
has not been declared
virtual void insert_longdouble_seq(CORBA::LongDoubleSeq& value) = 0;
^
C:/omniORB-4.2.1/include/omniORB4/dynAny.h:171:20: error: 'LongDoubleSeq' in nam
espace 'CORBA' does not name a type
virtual CORBA::LongDoubleSeq* get_longdouble_seq() = 0;
^
idl/CMakeFiles/SalomeIDLKernel.dir/build.make:333: recipe for target `idl/CMakeF
iles/SalomeIDLKernel.dir/SALOME_ExceptionSK.cc.obj' failed
make[2]: *** [idl/CMakeFiles/SalomeIDLKernel.dir/SALOME_ExceptionSK.cc.obj] Erro
r 1
CMakeFiles/Makefile2:86: recipe for target `idl/CMakeFiles/SalomeIDLKernel.dir/a
ll' failed
make[1]: *** [idl/CMakeFiles/SalomeIDLKernel.dir/all] Error 2
Makefile:127: recipe for target `all' failed
make: *** [all] Error 2
Does anyone know how to this problem?
SALOME? omniORB? Which is the matter?