Revert "Revert "oran-shell-release: release image for F""
[pti/rtp.git] / meta-starlingx / meta-stx-cloud / recipes-connectivity / qpid / qpid-proton / fix-missing-libary-for-cpp-binding.patch
1 diff -urN qpid-proton-0.28.0~/CMakeLists.txt qpid-proton-0.28.0/CMakeLists.txt
2 --- qpid-proton-0.28.0~/CMakeLists.txt  2019-08-20 15:03:13.807056363 +0800
3 +++ qpid-proton-0.28.0/CMakeLists.txt   2019-08-21 11:15:26.282136822 +0800
4 @@ -222,15 +222,6 @@
5  # So make these cached variables and the specific variables non cached
6  # and derived from them.
7  
8 -if (NOT DEFINED LIB_SUFFIX)
9 -    get_property(LIB64 GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS)
10 -    if ("${LIB64}" STREQUAL "TRUE" AND ${CMAKE_SIZEOF_VOID_P} STREQUAL "8")
11 -        set(LIB_SUFFIX 64)
12 -    else()
13 -        set(LIB_SUFFIX "")
14 -    endif()
15 -endif()
16 -
17  # Start of variables used during install
18  set (INCLUDE_INSTALL_DIR include CACHE PATH "Include file directory")
19  set (LIB_INSTALL_DIR "lib${LIB_SUFFIX}" CACHE PATH "Library object file directory")
20 @@ -354,7 +345,7 @@
21    # DEFAULT_{uppercase name of binding} to ON
22  
23    # Prerequisites for Python wrapper:
24 -  find_package (PythonLibs ${PYTHON_VERSION_STRING} EXACT)
25 +  find_package (PythonLibs 2.7 REQUIRED)
26    # TODO aconway 2018-09-07: get python binding tests working with sanitizers
27    if (PYTHONLIBS_FOUND AND NOT SANITIZE_FLAGS)
28      set (DEFAULT_PYTHON ON)
29 @@ -393,10 +384,6 @@
30  
31  unset(BUILD_BINDINGS CACHE) # Remove from cache, only relevant when creating the initial cache.
32  
33 -install (FILES LICENSE.txt README.md tests/share/CMakeLists.txt DESTINATION ${PROTON_SHARE})
34 -install (FILES tests/share/examples-README.md RENAME README.md DESTINATION ${PROTON_SHARE}/examples)
35 -install (DIRECTORY tests DESTINATION ${PROTON_SHARE} PATTERN share EXCLUDE)
36 -
37  # Generate test environment settings
38  configure_file(${CMAKE_SOURCE_DIR}/misc/config.sh.in
39                 ${CMAKE_BINARY_DIR}/config.sh @ONLY)
40 diff -urN qpid-proton-0.28.0~/cpp/CMakeLists.txt qpid-proton-0.28.0/cpp/CMakeLists.txt
41 --- qpid-proton-0.28.0~/cpp/CMakeLists.txt      2019-08-20 15:03:13.763056364 +0800
42 +++ qpid-proton-0.28.0/cpp/CMakeLists.txt       2019-08-20 15:06:51.195053615 +0800
43 @@ -269,7 +269,7 @@
44  
45  macro(add_cpp_test test)
46    add_executable (${test} src/${test}.cpp)
47 -  target_link_libraries (${test} qpid-proton-cpp ${PLATFORM_LIBS})
48 +  target_link_libraries (${test} qpid-proton-cpp qpid-proton-core qpid-proton-proactor ${PLATFORM_LIBS})
49    add_test (NAME cpp-${test}
50      COMMAND ${PN_ENV_SCRIPT} -- ${test_env}  ${TEST_EXE_PREFIX_CMD} $<TARGET_FILE:${test}> ${ARGN})
51  endmacro(add_cpp_test)
52 @@ -287,7 +287,7 @@
53  add_cpp_test(credit_test)
54  if (ENABLE_JSONCPP)
55    add_cpp_test(connect_config_test)
56 -  target_link_libraries(connect_config_test qpid-proton-core) # For pn_sasl_enabled
57 +  target_link_libraries(connect_config_test qpid-proton-core qpid-proton-proactor) # For pn_sasl_enabled
58    set_tests_properties(cpp-connect_config_test PROPERTIES WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}")
59    # Test data and output directories for connect_config_test
60    file(COPY  "${CMAKE_CURRENT_SOURCE_DIR}/testdata" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
61 @@ -300,7 +300,7 @@
62  
63  include_directories(${CMAKE_SOURCE_DIR}/tests/include)
64  add_executable(cpp-test src/cpp-test.cpp src/url_test.cpp)
65 -target_link_libraries(cpp-test qpid-proton-cpp ${PLATFORM_LIBS})
66 +target_link_libraries(cpp-test qpid-proton-cpp qpid-proton-core qpid-proton-proactor ${PLATFORM_LIBS})
67  
68  macro(add_catch_test tag)
69    add_test (
70 diff -urN qpid-proton-0.28.0~/cpp/examples/CMakeLists.txt qpid-proton-0.28.0/cpp/examples/CMakeLists.txt
71 --- qpid-proton-0.28.0~/cpp/examples/CMakeLists.txt     2019-08-20 15:03:13.767056363 +0800
72 +++ qpid-proton-0.28.0/cpp/examples/CMakeLists.txt      2019-08-20 15:26:18.731038854 +0800
73 @@ -82,6 +82,7 @@
74      ssl_client_cert
75      encode_decode)
76    add_executable(${example} ${example}.cpp)
77 +  target_link_libraries(${example} ${CMAKE_THREAD_LIBS_INIT} qpid-proton-core qpid-proton-proactor)
78  endforeach()
79  
80  if(HAS_ENOUGH_CPP11)
81 @@ -90,6 +91,7 @@
82        scheduled_send
83        service_bus)
84      add_executable(${example} ${example}.cpp)
85 +    target_link_libraries(${example} ${CMAKE_THREAD_LIBS_INIT} qpid-proton-core qpid-proton-proactor)
86    endforeach()
87  
88    # Examples that use threads directly
89 @@ -98,7 +100,7 @@
90          multithreaded_client
91          multithreaded_client_flow_control)
92        add_executable(${example} ${example}.cpp)
93 -      target_link_libraries(${example} ${CMAKE_THREAD_LIBS_INIT})
94 +      target_link_libraries(${example} ${CMAKE_THREAD_LIBS_INIT} qpid-proton-core qpid-proton-proactor)
95      endforeach()
96    endif()
97  endif()