gocv icon indicating copy to clipboard operation
gocv copied to clipboard

Error installing OpenCV libtbb2 and libdc1394-22-dev not found

Open maydersonmellops opened this issue 5 months ago • 1 comments

Error installing OpenCV

Description

I had a problem installing OpenCV in Docker using the golang:1.21 image, some libs were not found:

Makefile line 21

DEBS=unzip wget build-essential cmake curl git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev libtbb2 libtbb-dev libjpeg-dev libpng-dev libtiff-dev libdc1394-22-dev

libtbb2 and libdc1394-22-dev They were unable to be installed, so I replaced these packages and managed to successfully build OpenCV

Original package New package
libtbb2 libtbbmalloc2
libdc1394-22-dev libdc1394-dev

I applied these changes to the OpenCV installation step in Docker.

# Install OpenCV
RUN git clone https://github.com/hybridgroup/gocv.git && \
  cd gocv && \
  awk '{gsub(/libtbb2/, "libtbbmalloc2"); gsub(/libdc1394-22-dev/, "libdc1394-dev"); print}' Makefile > Makefile.tmp && \
  mv Makefile.tmp Makefile && \
  make install && \
  cd .. && \
  rm -rf gocv

Steps to Reproduce

  1. git clone https://github.com/hybridgroup/gocv.git
  2. cd gocv
  3. make install

Your Environment

  • Operating System and version: Mac OS M1 Pro
  • OpenCV version used: 4.8.1
  • How did you install OpenCV? From gocv
  • GoCV version used: 0.35.0
  • Go version: 1.21
  • Did you run the env.sh or env.cmd script before trying to go run or go build? No

maydersonmellops avatar Jan 25 '24 18:01 maydersonmellops