Bug 240187 - science/ncnn: cmake fails to find the library
Summary: science/ncnn: cmake fails to find the library
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Yuri Victorovich
URL: https://github.com/Tencent/ncnn/issue...
Keywords: needs-patch
Depends on:
Blocks:
 
Reported: 2019-08-29 11:56 UTC by Jan Beich
Modified: 2019-10-07 08:56 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (yuri)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Beich freebsd_committer freebsd_triage 2019-08-29 11:56:14 UTC
$ pkg install ncnn cmake
$ echo 'find_package(ncnn REQUIRED)' >CMakeLists.txt
$ cmake -Wno-dev .
[...]
CMake Error at /usr/local/lib/cmake/ncnn/ncnn.cmake:79 (message):
  The imported target "ncnn" references the file

     "/usr/local/lib/lib/libncnn.a"

  but this file does not exist.  Possible reasons include:

  * The file was deleted, renamed, or moved to another location.

  * An install or uninstall procedure did not complete successfully.

  * The installation package was faulty and contained

     "/usr/local/lib/cmake/ncnn/ncnn.cmake"

  but not all the files it references.

Call Stack (most recent call first):
  /usr/local/lib/cmake/ncnn/ncnnConfig.cmake:16 (include)
  CMakeLists.txt:1 (find_package)
Comment 1 Jan Beich freebsd_committer freebsd_triage 2019-09-02 05:31:18 UTC
Maybe update. ArchLinux has more recent snapshot which isn't affected.
https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=ncnn-git
Comment 2 commit-hook freebsd_committer freebsd_triage 2019-09-02 05:59:41 UTC
A commit references this bug:

Author: yuri
Date: Mon Sep  2 05:58:59 UTC 2019
New revision: 510759
URL: https://svnweb.freebsd.org/changeset/ports/510759

Log:
  science/ncnn: Update 20190611-40-gd3be711 -> 20190611-113-g46e7ac7

  PR:		240187
  Suggested by:	jbeich

Changes:
  head/science/ncnn/Makefile
  head/science/ncnn/distinfo
  head/science/ncnn/pkg-plist
Comment 3 Adriaan de Groot freebsd_committer freebsd_triage 2019-09-23 18:17:40 UTC
Looks like this one might be closed?
Comment 4 Adriaan de Groot freebsd_committer freebsd_triage 2019-10-07 08:56:35 UTC
Based on this test:

[adridg@beastie /tmp/derp]$ cat CMakeLists.txt 
cmake_minimum_required(VERSION 3.13 FATAL_ERROR)
project(pr240187)
find_package(ncnn REQUIRED)
add_executable(pr240187 main.c)
target_link_libraries(pr240187 ncnn)



[adridg@beastie /tmp/derp]$ cmake .
-- The C compiler identification is Clang 8.0.1
-- The CXX compiler identification is Clang 8.0.1
-- 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 OpenMP_C: -fopenmp=libomp (found version "3.1") 
-- Found OpenMP_CXX: -fopenmp=libomp (found version "3.1") 
-- Found OpenMP: TRUE (found version "3.1")  
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/derp



[adridg@beastie /tmp/derp]$ make
Scanning dependencies of target pr240187
[ 50%] Building C object CMakeFiles/pr240187.dir/main.c.o
[100%] Linking CXX executable pr240187
[100%] Built target pr240187



Closing as "fixed".