0

Trying to install libzippp library in this project is not working for some reason, here is my project's CMakeLists.txt:

CMakeLists.txt

cmake_minimum_required(VERSION 2.8)
project(startProject)
set(Leptonica_DIR /Users/alejandrocamba/Documents/leptonica/build)

find_package(OpenCV REQUIRED)
find_package(Leptonica REQUIRED)
find_package(Tesseract REQUIRED)
find_package(libzippp 3.0 REQUIRED)

set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED True)

include_directories(${OpenCV_INCLUDE_DIRS})
include_directories(${Leptonica_INCLUDE_DIRS})
include_directories(${Tesseract_INCLUDE_DIRS})

add_executable(startProject main.cpp)
target_link_libraries(startProject libzipp::libzipp)
target_link_libraries(startProject ${OpenCV_LIBS})
target_link_libraries(startProject ${Tesseract_LIBRARIES})

I'm getting the error:

ld: library not found for -llibzipp::libzipp

I have followed the instructions and i cloned the repository and successfully installed it, so if i do make install i get:

enter image description here

But i can't seem to find a way to use it on my project, i need help to make get it working on my project!

Alejandro Camba
  • 978
  • 10
  • 25
  • See the example CMake [file](https://github.com/ctabin/libzippp/blob/5106b5104fc72fb771d378b436e872c861cc9f3c/tests/exampleProject/CMakeLists.txt) in the repo. You need 3 p's. – Kevin Jul 17 '20 at 18:51

1 Answers1

1

Need more p: the proper target name for link with is libzippp::libzippp.

The project's README wrongly suggests to use libzipp::libzipp.

Tsyvarev
  • 60,011
  • 17
  • 110
  • 153