Boost logo

Boost Users :

From: Pawan Badganchi (Pawan.Badganchi_at_[hidden])
Date: 2024-10-15 06:20:08


Hi,

I am trying to resolve below error.

Tried adding below path to atomic.cmake custom file but still failing with same issue. Could you please help here?

include_directories(
${Boost_LIBRARY_DIRS}/atomic/test
)

ERROR:
Compilation failed Stdout: [ 50%] Building CXX object CMakeFiles/test_atomic.dir/atomicity.cpp.o Stderr: /sdk/sysroots/core2-64-poky-linux/usr/share/doc/boost-atomic/examples**/atomicity.cpp:38:10: fatal error: test_clock.hpp: No such file or directory 38 | #include "test_clock.hpp" | ^~~~~~~~~~~~~~~~ compilation terminated. make[2]: ***** [CMakeFiles/test_atomic.dir/build.make:76: CMakeFiles/test_atomic.dir/atomicity.cpp.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/test_atomic.dir/all] Error 2 make: *** [Makefile:91: all] Error 2 Returncode: Expected: 0 Actual: 2

Below is the my atomic.cmake file content.

cmake_minimum_required(VERSION 2.8)

FIND_PACKAGE(Boost
             REQUIRED
             COMPONENTS
                 atomic
)
FIND_PACKAGE(Boost
             REQUIRED
             COMPONENTS
                 thread
)

include_directories(
${Boost_LIBRARY_DIRS}/atomic/test
)

add_executable(test_atomic
    atomicity.cpp
)

target_link_libraries(test_atomic
    ${Boost_LIBRARIES}
)

Thanks & Regards,
Pawan
​KPIT Technologies,Pune
This message contains information that may be privileged or confidential and is the property of the KPIT Technologies Ltd. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message. KPIT Technologies Ltd. does not accept any liability for virus infected mails.



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net