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

No 'rosidl_typesupport_c' found when building for Android NDK #129

Open
mpconte opened this issue Nov 8, 2022 · 2 comments
Open

No 'rosidl_typesupport_c' found when building for Android NDK #129

mpconte opened this issue Nov 8, 2022 · 2 comments

Comments

@mpconte
Copy link

mpconte commented Nov 8, 2022

Bug report

Required Info:

  • Operating System:
    • Windows 10 (Ubuntu 20.04 Container)
  • Installation type:
    • source
  • Version or commit hash:
    • humble

Steps to reproduce issue

After following the instructions for building ros2 libraries via the following repo https://github.com/sloretz/sensors_for_ros, I wanted to build another project with an updated CMAKE_FIND_ROOT_PATH set to the location of these built libraries from this repo

I then tried to build a project with a CMakeLists.txt files like below:

set(CMAKE_TOOLCHAIN_FILE ${ANDROID_NDK}/build/cmake/android.toolchain.cmake)
set(PYTHONPATH ${CMAKE_FIND_ROOT_PATH}/_python_)
set(AMENT_PREFIX_PATH ${CMAKE_FIND_ROOT_PATH})
set(ANDROID_PLATFORM android-${ANDROID_API_MIN})

cmake_minimum_required(VERSION 3.12)

project(multisensor_framework)

find_package(ament_cmake REQUIRED)
find_package(common_interfaces REQUIRED)
find_package(rosidl_typesupport_c REQUIRED)
find_package(builtin_interfaces REQUIRED)
find_package(rosidl_default_generators REQUIRED)
find_package(std_msgs REQUIRED)

rosidl_generate_interfaces(${PROJECT_NAME}
  "msg/Radar.msg"
  "msg/Finished.msg"
  "msg/Recipe.msg"
  "msg/Odometer.msg"
  "msg/RawNMEA.msg"
  "msg/MetaData.msg"
  "msg/StandardResponse.msg"
  "msg/StandardFloatDataResponse.msg"
  "srv/GPRControl.srv"
  "srv/GPRControlRate.srv"
  "srv/MetaData.srv"  
  DEPENDENCIES builtin_interfaces std_msgs
)

ament_package()

Using the following cmake command:

cmake -DANDROID_NDK=/root/android-ndk-r25b -DANDROID_API_MIN=31 -DANDROID_ARCH_ABI=arm64-v8a -DCMAKE_FIND_ROOT_PATH=/root/workspace/ros2-build/build/deps ..

Expected behavior

builtin_interfaces should be build

Actual behavior

-- Found ament_cmake: 1.3.3 (/root/workspace/ros2-build/build/deps/share/ament_cmake/cmake)
-- Found Python3: /usr/bin/python3.8 (found version "3.8.10") found components: Interpreter 
-- Found common_interfaces: 4.2.2 (/root/workspace/ros2-build/build/deps/share/common_interfaces/cmake)
-- Found rosidl_typesupport_c: 2.0.0 (/root/workspace/ros2-build/build/deps/share/rosidl_typesupport_c/cmake)
CMake Error at /root/workspace/ros2-build/build/deps/share/rosidl_typesupport_c/cmake/get_used_typesupports.cmake:35 (message):
  No 'rosidl_typesupport_c' found
Call Stack (most recent call first):
  /root/workspace/ros2-build/build/deps/share/rosidl_typesupport_c/cmake/rosidl_typesupport_c-extras.cmake:8 (get_used_typesupports)
  /root/workspace/ros2-build/build/deps/share/rosidl_typesupport_c/cmake/rosidl_typesupport_cConfig.cmake:41 (include)
  sensor_network_interfaces/CMakeLists.txt:11 (find_package)

Additional information

@sorensej
Copy link

sorensej commented Apr 1, 2023

I am having a similar issue. Were you able to find a fix?

@CursedRock17
Copy link
Contributor

The author that library has two listings here where they explain not finding rosidl_typesupport_c and quick fixes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants