diff options
| author | Darryl L. Pierce <mcpierce@apache.org> | 2013-04-25 17:40:22 +0000 |
|---|---|---|
| committer | Darryl L. Pierce <mcpierce@apache.org> | 2013-04-25 17:40:22 +0000 |
| commit | 2dd24b5d15f2382f3d65bfb1d684984b338cbf1c (patch) | |
| tree | eaeb1196f3062dffe063f68c230233479e1950fc /qpid/cpp/bindings/qmf2/ruby | |
| parent | e10f718c39056853c7d09cb5a6cd3de64485d4a6 (diff) | |
| download | qpid-python-2dd24b5d15f2382f3d65bfb1d684984b338cbf1c.tar.gz | |
QPID-4776: Fixes building Ruby bindings on Cmake < 2.8
This patch fixes issues regarding finding the Ruby install and building
the bindings for it.
Contributed by Irina Boverman <iboverma@redhat.com>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1475868 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/bindings/qmf2/ruby')
| -rw-r--r-- | qpid/cpp/bindings/qmf2/ruby/CMakeLists.txt | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/qpid/cpp/bindings/qmf2/ruby/CMakeLists.txt b/qpid/cpp/bindings/qmf2/ruby/CMakeLists.txt index 70b3e917f9..4ea61abbe8 100644 --- a/qpid/cpp/bindings/qmf2/ruby/CMakeLists.txt +++ b/qpid/cpp/bindings/qmf2/ruby/CMakeLists.txt @@ -22,6 +22,10 @@ ##------------------------------------------------------ set_source_files_properties(${CMAKE_CURRENT_SOURCE_DIR}/ruby.i PROPERTIES CPLUSPLUS ON) +if ((${CMAKE_MAJOR_VERSION} EQUAL 2) AND (${CMAKE_MINOR_VERSION} LESS 8)) + set (RUBY_INCLUDE_DIRS ${RUBY_INCLUDE_PATH}) +endif ((${CMAKE_MAJOR_VERSION} EQUAL 2) AND (${CMAKE_MINOR_VERSION} LESS 8)) + include_directories(${RUBY_INCLUDE_DIRS} ${qpid-cpp_SOURCE_DIR}/include ${qpid-cpp_SOURCE_DIR}/bindings) @@ -32,9 +36,17 @@ swig_link_libraries(cqmf2_ruby qmf2 ${RUBY_LIBRARY}) ##---------------------------------- ## Install the complete Ruby binding ##---------------------------------- -install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libcqmf2_ruby.so +if ((${CMAKE_MAJOR_VERSION} EQUAL 2) AND (${CMAKE_MINOR_VERSION} LESS 8)) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cqmf2_ruby.so + RENAME cqmf2.so + DESTINATION ${RUBY_PFX_ARCH_DIR} + COMPONENT ${QPID_COMPONENT_CLIENT} + ) +else() + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libcqmf2_ruby.so RENAME cqmf2.so DESTINATION ${RUBY_PFX_ARCH_DIR} COMPONENT ${QPID_COMPONENT_CLIENT} ) +endif ((${CMAKE_MAJOR_VERSION} EQUAL 2) AND (${CMAKE_MINOR_VERSION} LESS 8)) |
