CMake Error: "IMPORTED_LOCATION not set for imported target 'octomap' configuration 'Debug'" in ROS 2 Build

I’m encountering the following CMake error when building my ROS 2 project that depends on OctoMap:

CMake Error in CMakeLists.txt:
IMPORTED_LOCATION not set for imported target “octomap” configuration “Debug”.

I have OctoMap installed as part of my ROS 2 (Humble) installation, and the library is located in the following path:

/opt/ros/humble/lib/x86_64-linux-gnu/liboctomap.so

I’ve tried the following solutions:

Set the CMAKE_PREFIX_PATH to the path of the ROS 2 libraries.

Explicitly specified the include directories and library paths in my CMakeLists.txt.

Rebuilt the OctoMap library to ensure that debug symbols are included.

However, the error persists, and CMake is unable to find the correct IMPORTED_LOCATION for the OctoMap library in the Debug configuration.
Additional Information:

I am building the project with colcon build.

The error occurs during the CMake generation step.

Questions:

How do I correctly set the IMPORTED_LOCATION for the OctoMap library in the Debug configuration when using ROS 2?

Should I be pointing to the /opt/ros/humble library or another location for the IMPORTED_LOCATION?

Any help would be appreciated!