Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] Conan package doesn't find other conan package as dependency in a yocto environment #9621

Closed
ukaiser opened this issue Sep 17, 2021 · 6 comments
Assignees

Comments

@ukaiser
Copy link

ukaiser commented Sep 17, 2021

Environment Details (include every applicable attribute)

  • Operating System+version: Ubuntu 20.04
  • Compiler+version: gcc8
  • Conan version: 1.39
  • Python version: 3.8.10

Steps to reproduce (Include if Applicable)

I'm in the process of converting a embedded linux appliaction from checked in dependencies in the repo to using conan.

conanfile.txt

[requires]
spdlog/1.8.2
sol2/3.2.3
cli11/1.9.1
argon2/20190702
nlohmann_json/3.9.1
tclap/1.2.3
botan/2.18.1
concurrentqueue/1.0.2
outcome/2.2.0
doctest/2.4.6
trompeloeil/41
concurrentqueue/1.0.2
paho-mqtt-cpp/1.2.0

[generators]
cmake


[options]
paho-mqtt-cpp:shared=False
paho-mqtt-cpp:ssl=False
botan:enable_modules=pubkey,rsa,emsa_pkcs1

The package paho-mqtt-cpp has a dependency to paho-mqtt-c.

If I now execute the command

 conan install . --profile ./scripts/gemmi.profile --install-folder build-conan --build=missing

in the yocto environment the paho-mqtt-c package gets build correctly. But while configuring the paho-mqtt-cpp package
cmake can't find the paho-mqtt-c library. See logs.

If I exceute conan install for the host system all buidls without an error.

Logs (Executed commands with output) (Include/Attach if Applicable)

Conan Logs

outcome/2.2.0: Already installed!
paho-mqtt-c/1.3.8: Copying sources to build folder
paho-mqtt-c/1.3.8: Building your package in /home/ks/.conan/data/paho-mqtt-c/1.3.8/_/_/build/b342aa74a39b756ee9c5f9913b6e686431dcfeda
paho-mqtt-c/1.3.8: Generator cmake created conanbuildinfo.cmake
paho-mqtt-c/1.3.8: Aggregating env generators
paho-mqtt-c/1.3.8: Calling build()
-- Toolchain file defaulted to '/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/cmake/OEToolchainConfig.cmake'
-- The C compiler identification is GNU 8.3.0
-- The CXX compiler identification is GNU 8.3.0
-- Check for working C compiler: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-gcc
-- Check for working C compiler: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-gcc -- 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: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-g++
-- Check for working CXX compiler: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Conan: called by CMake conan helper
-- Conan: called inside local cache
-- Conan: Adjusting output directories
-- Conan: Using cmake global configuration
-- Conan: Adjusting default RPATHs Conan policies
-- Conan: Adjusting language standard
-- Conan: Adjusting fPIC flag (ON)
-- Conan: Compiler GCC>=5, checking major version 8
-- Conan: Checking correct version: 8
-- CMake version: 3.14.1
-- CMake system name: Linux
-- Timestamp is 2021-09-17T08:53:09Z
-- Configuring done
-- Generating done
CMake Warning:
  Manually-specified variables were not used by the project:

    CMAKE_EXPORT_NO_PACKAGE_REGISTRY
    PAHO_BUILD_ASYNC


-- Build files have been written to: /home/ks/.conan/data/paho-mqtt-c/1.3.8/_/_/build/b342aa74a39b756ee9c5f9913b6e686431dcfeda
Scanning dependencies of target common_obj_static
[  3%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTProtocolClient.c.o
[  7%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTTime.c.o
[ 11%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/utf-8.c.o
[ 15%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPacket.c.o
[ 19%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Messages.c.o
[ 23%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Clients.c.o
[ 26%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Tree.c.o
[ 30%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPacketOut.c.o
[ 34%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Socket.c.o
[ 38%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Log.c.o
[ 42%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPersistence.c.o
[ 46%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Thread.c.o
[ 50%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTProtocolOut.c.o
[ 53%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPersistenceDefault.c.o
[ 57%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/SocketBuffer.c.o
[ 61%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/LinkedList.c.o
[ 65%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTProperties.c.o
[ 69%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTReasonCodes.c.o
[ 73%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Base64.c.o
[ 76%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/SHA1.c.o
[ 80%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/WebSocket.c.o
[ 84%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/StackTrace.c.o
[ 88%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Heap.c.o
[ 88%] Built target common_obj_static
Scanning dependencies of target paho-mqtt3a-static
[ 96%] Building C object source_subfolder/src/CMakeFiles/paho-mqtt3a-static.dir/MQTTAsyncUtils.c.o
[ 96%] Building C object source_subfolder/src/CMakeFiles/paho-mqtt3a-static.dir/MQTTAsync.c.o
[100%] Linking C static library ../../lib/libpaho-mqtt3a.a
[100%] Built target paho-mqtt3a-static
paho-mqtt-c/1.3.8: Package 'b342aa74a39b756ee9c5f9913b6e686431dcfeda' built
paho-mqtt-c/1.3.8: Build folder /home/ks/.conan/data/paho-mqtt-c/1.3.8/_/_/build/b342aa74a39b756ee9c5f9913b6e686431dcfeda
paho-mqtt-c/1.3.8: Generated conaninfo.txt
paho-mqtt-c/1.3.8: Generated conanbuildinfo.txt
paho-mqtt-c/1.3.8: Generating the package
paho-mqtt-c/1.3.8: Package folder /home/ks/.conan/data/paho-mqtt-c/1.3.8/_/_/package/b342aa74a39b756ee9c5f9913b6e686431dcfeda
paho-mqtt-c/1.3.8: Calling package()
paho-mqtt-c/1.3.8 package(): Packaged 1 '.html' file: notice.html
paho-mqtt-c/1.3.8 package(): Packaged 2 files: epl-v20, edl-v10
paho-mqtt-c/1.3.8 package(): Packaged 1 '.a' file: libpaho-mqtt3a.a
paho-mqtt-c/1.3.8 package(): Packaged 16 '.h' files
paho-mqtt-c/1.3.8: Package 'b342aa74a39b756ee9c5f9913b6e686431dcfeda' created
paho-mqtt-c/1.3.8: Created package revision 3424e3a82326a82c8617b3cfc2bf2b6b
tclap/1.2.3: Already installed!
trompeloeil/41: Already installed!
paho-mqtt-cpp/1.2.0: Copying sources to build folder
paho-mqtt-cpp/1.2.0: Building your package in /home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/build/898265fbf801a3f5139b4a8be70607cac1ae17dc
paho-mqtt-cpp/1.2.0: Generator cmake created conanbuildinfo.cmake
paho-mqtt-cpp/1.2.0: Generator cmake_find_package created Findeclipse-paho-mqtt-c.cmake
paho-mqtt-cpp/1.2.0: Aggregating env generators
paho-mqtt-cpp/1.2.0: Calling build()
-- Toolchain file defaulted to '/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/cmake/OEToolchainConfig.cmake'
-- The C compiler identification is GNU 8.3.0
-- The CXX compiler identification is GNU 8.3.0
-- Check for working C compiler: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-gcc
-- Check for working C compiler: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-gcc -- 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: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-g++
-- Check for working CXX compiler: /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi/arm-fslc-linux-gnueabi-g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Conan: called by CMake conan helper
-- Conan: called inside local cache
-- Conan: Adjusting output directories
-- Conan: Using cmake global configuration
-- Conan: Adjusting default RPATHs Conan policies
-- Conan: Adjusting language standard
-- Conan: Adjusting fPIC flag (ON)
-- Conan: Compiler GCC>=5, checking major version 8
-- Conan: Checking correct version: 8
-- Conan: C++ stdlib: libstdc++11
CMake Error at /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/cmake-3.14/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find PahoMqttC (missing: PAHO_MQTT_C_LIBRARIES
  PAHO_MQTT_C_INCLUDE_DIRS)
Call Stack (most recent call first):
  /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/cmake-3.14/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
  source_subfolder/cmake/FindPahoMqttC.cmake:33 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  source_subfolder/src/CMakeLists.txt:26 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/build/898265fbf801a3f5139b4a8be70607cac1ae17dc/CMakeFiles/CMakeOutput.log".
paho-mqtt-cpp/1.2.0:
paho-mqtt-cpp/1.2.0: ERROR: Package '898265fbf801a3f5139b4a8be70607cac1ae17dc' build failed
paho-mqtt-cpp/1.2.0: WARN: Build folder /home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/build/898265fbf801a3f5139b4a8be70607cac1ae17dc
ERROR: paho-mqtt-cpp/1.2.0: Error in build() method, line 85
        cmake = self._configure_cmake()
while calling '_configure_cmake', line 72
        self._cmake.configure()
        ConanException: Error 1 while executing cd '/home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/build/898265fbf801a3f5139b4a8be70607cac1ae17dc' && cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE="Debug" -DCMAKE_SYSTEM_NAME="Linux" -DCONAN_IN_LOCAL_CACHE="ON" -DCONAN_COMPILER="gcc" -DCONAN_COMPILER_VERSION="8" -DCONAN_LIBCXX="libstdc++11" -DBUILD_SHARED_LIBS="OFF" -DCMAKE_INSTALL_PREFIX="/home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/package/898265fbf801a3f5139b4a8be70607cac1ae17dc" -DCMAKE_INSTALL_BINDIR="bin" -DCMAKE_INSTALL_SBINDIR="bin" -DCMAKE_INSTALL_LIBEXECDIR="bin" -DCMAKE_INSTALL_LIBDIR="lib" -DCMAKE_INSTALL_INCLUDEDIR="include" -DCMAKE_INSTALL_OLDINCLUDEDIR="include" -DCMAKE_INSTALL_DATAROOTDIR="share" -DCONAN_CMAKE_POSITION_INDEPENDENT_CODE="ON" -DCMAKE_MODULE_PATH="/home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/build/898265fbf801a3f5139b4a8be70607cac1ae17dc" -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY="ON" -DCONAN_EXPORTED="1" -DPAHO_BUILD_DOCUMENTATION="False" -DPAHO_BUILD_SAMPLES="False" -DPAHO_BUILD_STATIC="True" -DPAHO_BUILD_SHARED="False" -DPAHO_WITH_SSL="False" -Wno-dev '/home/ks/.conan/data/paho-mqtt-cpp/1.2.0/_/_/build/898265fbf801a3f5139b4a8be70607cac1ae17dc'

ENV

ALACRITTY_LOG=/tmp/Alacritty-7415.log
COLORTERM=truecolor
COMPIZ_CONFIG_PROFILE=gnome-flashback
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
DEFAULTS_PATH=/usr/share/gconf/regolith.default.path
DESKTOP_AUTOSTART_ID=10a2c77d9833a5b5c6163185791893648500000018270016
DESKTOP_SESSION=regolith
DISPLAY=:0
GDMSESSION=regolith
GDM_LANG=en_US
GIO_LAUNCHED_DESKTOP_FILE=/usr/share/applications/regolith.desktop
GIO_LAUNCHED_DESKTOP_FILE_PID=2153
GNOME_DESKTOP_SESSION_ID=this-is-deprecated
GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
GTK_MODULES=gail:atk-bridge
HOME=/home/ks
I3SOCK=/run/user/1000/i3/ipc-socket.2219
LANG=en_US.UTF-8
LANGUAGE=en_US
LC_ADDRESS=de_DE.UTF-8
LC_IDENTIFICATION=de_DE.UTF-8
LC_MEASUREMENT=de_DE.UTF-8
LC_MONETARY=de_DE.UTF-8
LC_NAME=de_DE.UTF-8
LC_NUMERIC=de_DE.UTF-8
LC_PAPER=de_DE.UTF-8
LC_TELEPHONE=de_DE.UTF-8
LC_TIME=de_DE.UTF-8
LESS=-R
LIBVIRT_DEFAULT_URI=qemu:///system
LOGNAME=ks
LSCOLORS=Gxfxcxdxbxegedabagacad
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:
MANDATORY_PATH=/usr/share/gconf/regolith.mandatory.path
OLDPWD=/home/ks
P9K_SSH=0
P9K_TTY=old
PAGER=less
PATH=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/sbin:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/bin:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/sbin:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/../x86_64-fslcsdk-linux/bin:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-gnueabi:/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/arm-fslc-linux-musl:/home/ks/neovim/bin:/home/ks/neovim/bin:/home/ks/.cargo/bin:/home/ks/.local/bin:/home/ks/bin:/opt/GitHub Desktop:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/ks/.local/bin:/home/ks/.local/bin
PWD=/home/ks/Developer/gemmi/808_gemmi_app
QT_ACCESSIBILITY=1
QT_IM_MODULE=ibus
SESSION_MANAGER=local/ks-bionic:@/tmp/.ICE-unix/1827,unix/ks-bionic:/tmp/.ICE-unix/1827
SHELL=/usr/bin/zsh
SHLVL=4
SSH_AGENT_PID=1952
SSH_AUTH_SOCK=/run/user/1000/keyring/ssh
S_COLORS=auto
TERM=tmux-256color
TMUX=/tmp/tmux-1000/default,7475,0
TMUX_PANE=%1
USER=ks
WINDOWID=48234500
XAUTHORITY=/home/ks/.Xauthority
XDG_CONFIG_DIRS=/etc/xdg/xdg-regolith:/etc/xdg
XDG_CURRENT_DESKTOP=Regolith:GNOME-Flashback:GNOME
XDG_DATA_DIRS=/usr/share/regolith:/usr/local/share/:/usr/share/
XDG_GREETER_DATA_DIR=/var/lib/lightdm-data/ks
XDG_MENU_PREFIX=gnome-flashback-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=regolith
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session0
XDG_SESSION_TYPE=x11
XMODIFIERS=@im=ibus
ZSH=/home/ks/.oh-my-zsh
_=/usr/bin/env
_P9K_TTY=/dev/pts/2
SDKTARGETSYSROOT=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
PKG_CONFIG_SYSROOT_DIR=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
PKG_CONFIG_PATH=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi/usr/lib/pkgconfig:/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi/usr/share/pkgconfig
CONFIG_SITE=/opt/fslc-framebuffer/2.8-snapshot/site-config-cortexa9t2hf-neon-fslc-linux-gnueabi
OECORE_NATIVE_SYSROOT=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux
OECORE_TARGET_SYSROOT=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
OECORE_ACLOCAL_OPTS=-I /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/aclocal
OECORE_BASELIB=lib
OECORE_TARGET_ARCH=arm
OECORE_TARGET_OS=linux-gnueabi
CC=arm-fslc-linux-gnueabi-gcc  -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
CXX=arm-fslc-linux-gnueabi-g++  -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
CPP=arm-fslc-linux-gnueabi-gcc -E  -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
AS=arm-fslc-linux-gnueabi-as
LD=arm-fslc-linux-gnueabi-ld  --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
GDB=arm-fslc-linux-gnueabi-gdb
STRIP=arm-fslc-linux-gnueabi-strip
RANLIB=arm-fslc-linux-gnueabi-ranlib
OBJCOPY=arm-fslc-linux-gnueabi-objcopy
OBJDUMP=arm-fslc-linux-gnueabi-objdump
AR=arm-fslc-linux-gnueabi-ar
NM=arm-fslc-linux-gnueabi-nm
M4=m4
TARGET_PREFIX=arm-fslc-linux-gnueabi-
CONFIGURE_FLAGS=--target=arm-fslc-linux-gnueabi --host=arm-fslc-linux-gnueabi --build=x86_64-linux --with-libtool-sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
CFLAGS= -O2 -pipe -g -feliminate-unused-debug-types
CXXFLAGS= -O2 -pipe -g -feliminate-unused-debug-types
LDFLAGS=-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed
CPPFLAGS=
KCFLAGS=--sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
OECORE_DISTRO_VERSION=2.8-snapshot-20191120
OECORE_SDK_VERSION=2.8-snapshot
ARCH=arm
CROSS_COMPILE=arm-fslc-linux-gnueabi-
OE_CMAKE_TOOLCHAIN_FILE=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/cmake/OEToolchainConfig.cmake
OE_CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX=
OPENSSL_CONF=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/lib/ssl-1.1/openssl.cnf
OE_QMAKE_CFLAGS= -O2 -pipe -g -feliminate-unused-debug-types
OE_QMAKE_CXXFLAGS= -O2 -pipe -g -feliminate-unused-debug-types
OE_QMAKE_LDFLAGS=-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed
OE_QMAKE_CC=arm-fslc-linux-gnueabi-gcc  -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
OE_QMAKE_CXX=arm-fslc-linux-gnueabi-g++  -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
OE_QMAKE_LINK=arm-fslc-linux-gnueabi-g++  -mthumb -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi
OE_QMAKE_AR=arm-fslc-linux-gnueabi-ar
OE_QMAKE_STRIP=arm-fslc-linux-gnueabi-strip
QT_CONF_PATH=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/qt.conf
OE_QMAKE_LIBDIR_QT=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi/usr/lib
OE_QMAKE_INCDIR_QT=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi/usr/include
OE_QMAKE_MOC=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/moc
OE_QMAKE_UIC=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/uic
OE_QMAKE_RCC=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/rcc
OE_QMAKE_QDBUSCPP2XML=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/qdbuscpp2xml
OE_QMAKE_QDBUSXML2CPP=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin/qdbusxml2cpp
OE_QMAKE_QT_CONFIG=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi/usr/lib/mkspecs/qconfig.pri
OE_QMAKE_PATH_HOST_BINS=/opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/bin
QMAKESPEC=/opt/fslc-framebuffer/2.8-snapshot/sysroots/cortexa9t2hf-neon-fslc-linux-gnueabi/usr/lib/mkspecs/linux-oe-g++
@ukaiser ukaiser changed the title [bug] Conan package doesnt find other conan package as dependency in a yocto environment [bug] Conan package doesn't find other conan package as dependency in a yocto environment Sep 17, 2021
@memsharded
Copy link
Member

Hi @ukaiser

I suspect this could be something in the paho-mqtt-cpp/1.2.0 recipe, that could be failing for some cross-compile scenario. Maybe related conan-io/conan-center-index#3760?
Pinging @uilianries in case he could help here.

One of the first things that could be tried is cross-compiling that recipe for another architecture, for example, and see if the recipe in general is able to cross-compile successfully. If it does, then probably is related to "sysroot"-like specifics of the Yocto environment, and CMake using some other find module instead of the Conan generated one.

@uilianries
Copy link
Member

I agree, it should be related to cross-compiler + PahoMQTT. I would move this issue to conan-center-index.

Besides that, we need the profile used to try to reproduce. However, using the Docker image conanio/gcc9-armv7hf, all build fine. Of, course, is different from Yocto, but still is cross-building.

My full log:

Details

$ conan install paho-mqtt-cpp/1.2.0@ -o paho-mqtt-cpp:ssl=False -o paho-mqtt-cpp:shared=False --build missing --install-folder build-conan
Configuration:
[settings]
arch=armv7hf
arch_build=x86_64
build_type=Release
compiler=gcc
compiler.libcxx=libstdc++
compiler.version=9
os=Linux
os_build=Linux
[options]
paho-mqtt-cpp:shared=False
paho-mqtt-cpp:ssl=False
[build_requires]
[env]

paho-mqtt-cpp/1.2.0: Not found in local cache, looking in remotes...
paho-mqtt-cpp/1.2.0: Trying with 'conancenter'...
Downloading conanmanifest.txt completed [0.64k]
Downloading conanfile.py completed [4.78k]
Downloading conan_export.tgz completed [0.25k]
Decompressing conan_export.tgz completed [0.00k]
paho-mqtt-cpp/1.2.0: Downloaded recipe revision 0
paho-mqtt-c/1.3.8: Not found in local cache, looking in remotes...
paho-mqtt-c/1.3.8: Trying with 'conancenter'...
Downloading conanmanifest.txt completed [0.65k]
Downloading conanfile.py completed [7.35k]
Downloading conan_export.tgz completed [0.31k]
Decompressing conan_export.tgz completed [0.00k]
paho-mqtt-c/1.3.8: Downloaded recipe revision 0
Installing package: paho-mqtt-cpp/1.2.0
Requirements
paho-mqtt-c/1.3.8 from 'conancenter' - Downloaded
paho-mqtt-cpp/1.2.0 from 'conancenter' - Downloaded
Packages
paho-mqtt-c/1.3.8:816065fbcab3faf801de50ee7a0b6500c779d038 - Build
paho-mqtt-cpp/1.2.0:0a7918ae5974d9a7edd75451e937d668e278d58c - Build

Cross-build from 'Linux:x86_64' to 'Linux:armv7hf'
Installing (downloading, building) binaries...
Downloading conan_sources.tgz completed [2.94k]
Decompressing conan_sources.tgz completed [0.00k]
paho-mqtt-c/1.3.8: Configuring sources in /home/conan/.conan/data/paho-mqtt-c/1.3.8///source
Downloading v1.3.8.tar.gz completed [3451.94k]

paho-mqtt-c/1.3.8: Copying sources to build folder
paho-mqtt-c/1.3.8: Building your package in /home/conan/.conan/data/paho-mqtt-c/1.3.8///build/816065fbcab3faf801de50ee7a0b6500c779d038
paho-mqtt-c/1.3.8: Generator cmake created conanbuildinfo.cmake
paho-mqtt-c/1.3.8: Aggregating env generators
paho-mqtt-c/1.3.8: Calling build()
-- The C compiler identification is GNU 9.2.1
-- The CXX compiler identification is GNU 9.2.1
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/arm-linux-gnueabihf-gcc-9 - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/arm-linux-gnueabihf-g++-9 - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Conan: called by CMake conan helper
-- Conan: called inside local cache
-- Conan: Adjusting output directories
-- Conan: Using cmake global configuration
-- Conan: Adjusting default RPATHs Conan policies
-- Conan: Adjusting language standard
-- Conan: Adjusting fPIC flag (ON)
-- Conan: Compiler GCC>=5, checking major version 9
-- Conan: Checking correct version: 9
-- CMake version: 3.18.2
-- CMake system name: Linux
-- Timestamp is 2021-09-17T18:22:11Z
-- Configuring done
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:

CMAKE_EXPORT_NO_PACKAGE_REGISTRY
PAHO_BUILD_ASYNC

-- Build files have been written to: /home/conan/.conan/data/paho-mqtt-c/1.3.8///build/816065fbcab3faf801de50ee7a0b6500c779d038
Scanning dependencies of target common_obj_static
[ 3%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTTime.c.o
[ 11%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTProtocolClient.c.o
[ 7%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Clients.c.o
[ 15%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/utf-8.c.o
[ 19%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPacket.c.o
[ 23%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPacketOut.c.o
[ 26%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Messages.c.o
[ 30%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Tree.c.o
[ 34%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Socket.c.o
[ 38%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Log.c.o
[ 42%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPersistence.c.o
[ 46%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Thread.c.o
[ 50%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTProtocolOut.c.o
[ 53%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTPersistenceDefault.c.o
[ 57%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/SocketBuffer.c.o
[ 61%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/LinkedList.c.o
[ 65%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTProperties.c.o
[ 69%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/MQTTReasonCodes.c.o
[ 73%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Base64.c.o
[ 76%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/SHA1.c.o
[ 80%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/WebSocket.c.o
[ 84%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/StackTrace.c.o
[ 88%] Building C object source_subfolder/src/CMakeFiles/common_obj_static.dir/Heap.c.o
[ 88%] Built target common_obj_static
Scanning dependencies of target paho-mqtt3a-static
[ 96%] Building C object source_subfolder/src/CMakeFiles/paho-mqtt3a-static.dir/MQTTAsyncUtils.c.o
[ 96%] Building C object source_subfolder/src/CMakeFiles/paho-mqtt3a-static.dir/MQTTAsync.c.o
[100%] Linking C static library ../../lib/libpaho-mqtt3a.a
[100%] Built target paho-mqtt3a-static
paho-mqtt-c/1.3.8: Package '816065fbcab3faf801de50ee7a0b6500c779d038' built
paho-mqtt-c/1.3.8: Build folder /home/conan/.conan/data/paho-mqtt-c/1.3.8///build/816065fbcab3faf801de50ee7a0b6500c779d038
paho-mqtt-c/1.3.8: Generated conaninfo.txt
paho-mqtt-c/1.3.8: Generated conanbuildinfo.txt
paho-mqtt-c/1.3.8: Generating the package
paho-mqtt-c/1.3.8: Package folder /home/conan/.conan/data/paho-mqtt-c/1.3.8///package/816065fbcab3faf801de50ee7a0b6500c779d038
paho-mqtt-c/1.3.8: Calling package()
paho-mqtt-c/1.3.8 package(): Packaged 16 '.h' files
paho-mqtt-c/1.3.8 package(): Packaged 2 files: epl-v20, edl-v10
paho-mqtt-c/1.3.8 package(): Packaged 1 '.html' file: notice.html
paho-mqtt-c/1.3.8 package(): Packaged 1 '.a' file: libpaho-mqtt3a.a
paho-mqtt-c/1.3.8: Package '816065fbcab3faf801de50ee7a0b6500c779d038' created
paho-mqtt-c/1.3.8: Created package revision 60224dc5c19f67243fc35b3b5c0ecea6
Downloading conan_sources.tgz completed [4.57k]
Decompressing conan_sources.tgz completed [0.00k]
paho-mqtt-cpp/1.2.0: Configuring sources in /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///source
Downloading v1.2.0.tar.gz completed [211.03k]

paho-mqtt-cpp/1.2.0: Copying sources to build folder
paho-mqtt-cpp/1.2.0: Building your package in /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///build/0a7918ae5974d9a7edd75451e937d668e278d58c
paho-mqtt-cpp/1.2.0: Generator cmake_find_package created Findeclipse-paho-mqtt-c.cmake
paho-mqtt-cpp/1.2.0: Generator cmake created conanbuildinfo.cmake
paho-mqtt-cpp/1.2.0: Aggregating env generators
paho-mqtt-cpp/1.2.0: Calling build()
-- The C compiler identification is GNU 9.2.1
-- The CXX compiler identification is GNU 9.2.1
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/arm-linux-gnueabihf-gcc-9 - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/arm-linux-gnueabihf-g++-9 - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Conan: called by CMake conan helper
-- Conan: called inside local cache
-- Conan: Adjusting output directories
-- Conan: Using cmake global configuration
-- Conan: Adjusting default RPATHs Conan policies
-- Conan: Adjusting language standard
-- Conan: Adjusting fPIC flag (ON)
-- Conan: Compiler GCC>=5, checking major version 9
-- Conan: Checking correct version: 9
-- Conan: C++ stdlib: libstdc++
-- Found PahoMqttC: /home/conan/.conan/data/paho-mqtt-c/1.3.8///package/816065fbcab3faf801de50ee7a0b6500c779d038/lib/libpaho-mqtt3a.a
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Check if compiler accepts -pthread
-- Check if compiler accepts -pthread - yes
-- Found Threads: TRUE
-- Configuring done
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:

CMAKE_EXPORT_NO_PACKAGE_REGISTRY

-- Build files have been written to: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///build/0a7918ae5974d9a7edd75451e937d668e278d58c
Scanning dependencies of target paho-cpp-objs
[ 12%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/client.cpp.o
[ 12%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/async_client.cpp.o
[ 18%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/create_options.cpp.o
[ 25%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/connect_options.cpp.o
[ 31%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/disconnect_options.cpp.o
[ 37%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/iclient_persistence.cpp.o
[ 43%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/message.cpp.o
[ 50%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/properties.cpp.o
[ 56%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/response_options.cpp.o
[ 62%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/ssl_options.cpp.o
[ 68%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/string_collection.cpp.o
[ 75%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/subscribe_options.cpp.o
[ 81%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/token.cpp.o
[ 87%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/topic.cpp.o
[ 93%] Building CXX object source_subfolder/src/CMakeFiles/paho-cpp-objs.dir/will_options.cpp.o
[ 93%] Built target paho-cpp-objs
Scanning dependencies of target paho-mqttpp3-static
[100%] Linking CXX static library ../../lib/libpaho-mqttpp3.a
[100%] Built target paho-mqttpp3-static
paho-mqtt-cpp/1.2.0: Package '0a7918ae5974d9a7edd75451e937d668e278d58c' built
paho-mqtt-cpp/1.2.0: Build folder /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///build/0a7918ae5974d9a7edd75451e937d668e278d58c
paho-mqtt-cpp/1.2.0: Generated conaninfo.txt
paho-mqtt-cpp/1.2.0: Generated conanbuildinfo.txt
paho-mqtt-cpp/1.2.0: Generating the package
paho-mqtt-cpp/1.2.0: Package folder /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c
paho-mqtt-cpp/1.2.0: Calling package()
[ 93%] Built target paho-cpp-objs
[100%] Built target paho-mqttpp3-static
Install the project...
-- Install configuration: "Release"
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/lib/libpaho-mqttpp3.a
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/async_client.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/buffer_ref.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/buffer_view.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/callback.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/client.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/connect_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/create_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/delivery_token.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/disconnect_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/exception.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/iaction_listener.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/iasync_client.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/iclient_persistence.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/message.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/properties.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/response_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/server_response.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/ssl_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/string_collection.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/subscribe_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/thread_queue.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/token.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/topic.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/types.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/include/mqtt/will_options.h
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/lib/cmake/PahoMqttCpp/PahoMqttCppTargets.cmake
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/lib/cmake/PahoMqttCpp/PahoMqttCppTargets-release.cmake
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/lib/cmake/PahoMqttCpp/PahoMqttCppConfig.cmake
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/lib/cmake/PahoMqttCpp/FindPahoMqttC.cmake
-- Installing: /home/conan/.conan/data/paho-mqtt-cpp/1.2.0///package/0a7918ae5974d9a7edd75451e937d668e278d58c/lib/cmake/PahoMqttCpp/PahoMqttCppConfigVersion.cmake
paho-mqtt-cpp/1.2.0 package(): Packaged 25 '.h' files
paho-mqtt-cpp/1.2.0 package(): Packaged 2 files: epl-v10, edl-v10
paho-mqtt-cpp/1.2.0 package(): Packaged 1 '.html' file: notice.html
paho-mqtt-cpp/1.2.0 package(): Packaged 1 '.a' file: libpaho-mqttpp3.a
paho-mqtt-cpp/1.2.0: Package '0a7918ae5974d9a7edd75451e937d668e278d58c' created
paho-mqtt-cpp/1.2.0: Created package revision ff17e4ef04870a4bf07530ff2e65874f
Aggregating env generators

@memsharded
Copy link
Member

Based on the output:

paho-mqtt-cpp/1.2.0: Generator cmake_find_package created Findeclipse-paho-mqtt-c.cmake
...
CMake Error at /opt/fslc-framebuffer/2.8-snapshot/sysroots/x86_64-fslcsdk-linux/usr/share/cmake-3.14/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find PahoMqttC (missing: PAHO_MQTT_C_LIBRARIES
  PAHO_MQTT_C_INCLUDE_DIRS)

My bet is that the build is using other find module, probably belonging to yocto cmake or something like that.

@uilianries
Copy link
Member

My bet is that the build is using other find module, probably belonging to yocto cmake or something like that.

Yes, it sounds something affected by Yocto environment which is changing the Cmake root module path, like, searching on Yocto folders instead of using Conan folders.

@dornbirndevelops
Copy link

hello @uilianries !
I had a similar problem when developed on Yocto.
I remember I had to patch the CMAKE_FIND_ROOT_PATH like it's described here.
Could you please check whether this is relevant for your case?

@uilianries
Copy link
Member

@dornbirndevelops Excellent find, let's see if it works for @ukaiser

@ukaiser ukaiser closed this as completed Mar 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants