mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
Merge pull request #674 from VILLASframework/fix-amqp
node-amqp: Handle moved include dir of rabbitmq-c
This commit is contained in:
commit
3d6e5204ff
4 changed files with 20 additions and 0 deletions
|
@ -145,6 +145,12 @@ if (REDISPP_FOUND)
|
|||
endif()
|
||||
endif()
|
||||
|
||||
if (RABBITMQ_C_FOUND)
|
||||
if (EXISTS "${RABBITMQ_C_INCLUDEDIR}/rabbitmq-c/amqp.h")
|
||||
set(RABBITMQ_C_NEW_INCLUDE_DIR ON)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Check if libwebsockets is build with deflate extension
|
||||
if(${CMAKE_VERSION} VERSION_LESS "3.12.4")
|
||||
set(LWS_LOCATION "${LIBWEBSOCKETS_LIBRARY_DIRS}/lib${LIBWEBSOCKETS_LIBRARIES}.so")
|
||||
|
|
|
@ -59,3 +59,4 @@
|
|||
#cmakedefine LWS_DEFLATE_FOUND
|
||||
#cmakedefine REDISPP_WITH_TLS
|
||||
#cmakedefine REDISPP_WITH_URI
|
||||
#cmakedefine RABBITMQ_C_NEW_INCLUDE_DIR
|
||||
|
|
|
@ -8,7 +8,13 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <villas/node/config.hpp>
|
||||
|
||||
#ifdef RABBITMQ_C_NEW_INCLUDE_DIR
|
||||
#include <rabbitmq-c/amqp.h>
|
||||
#else
|
||||
#include <amqp.h>
|
||||
#endif
|
||||
|
||||
#include <villas/list.hpp>
|
||||
#include <villas/format.hpp>
|
||||
|
|
|
@ -7,8 +7,15 @@
|
|||
|
||||
#include <cstring>
|
||||
|
||||
#include <villas/node/config.hpp>
|
||||
|
||||
#ifdef RABBITMQ_C_NEW_INCLUDE_DIR
|
||||
#include <rabbitmq-c/ssl_socket.h>
|
||||
#include <rabbitmq-c/tcp_socket.h>
|
||||
#else
|
||||
#include <amqp_ssl_socket.h>
|
||||
#include <amqp_tcp_socket.h>
|
||||
#endif
|
||||
|
||||
#include <villas/node_compat.hpp>
|
||||
#include <villas/nodes/amqp.hpp>
|
||||
|
|
Loading…
Add table
Reference in a new issue