Repository: qpid-proton
Updated Branches:
  refs/heads/PROTON-1488 [created] fe5dffdde


build remote sasl support as a separate library


Project: http://git-wip-us.apache.org/repos/asf/qpid-proton/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-proton/commit/fe5dffdd
Tree: http://git-wip-us.apache.org/repos/asf/qpid-proton/tree/fe5dffdd
Diff: http://git-wip-us.apache.org/repos/asf/qpid-proton/diff/fe5dffdd

Branch: refs/heads/PROTON-1488
Commit: fe5dffddeeaff9f4668904f8b6e07c4eb105d6cf
Parents: 75fc841
Author: Gordon Sim <g...@redhat.com>
Authored: Thu May 25 14:44:22 2017 +0100
Committer: Gordon Sim <g...@redhat.com>
Committed: Thu May 25 14:44:45 2017 +0100

----------------------------------------------------------------------
 proton-c/CMakeLists.txt               | 18 ++++++++++++--
 proton-c/include/proton/proactor.h    |  4 ----
 proton-c/include/proton/remote_sasl.h | 38 ++++++++++++++++++++++++++++++
 proton-c/src/ProtonConfig.cmake.in    |  1 +
 proton-c/src/sasl/remote_sasl.c       |  1 +
 5 files changed, 56 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/fe5dffdd/proton-c/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/proton-c/CMakeLists.txt b/proton-c/CMakeLists.txt
index 094fba4..f0688bb 100644
--- a/proton-c/CMakeLists.txt
+++ b/proton-c/CMakeLists.txt
@@ -456,6 +456,7 @@ set (qpid-proton-include
   include/proton/netaddr.h
   include/proton/object.h
   include/proton/proactor.h
+  include/proton/remote_sasl.h
   include/proton/sasl.h
   include/proton/session.h
   include/proton/ssl.h
@@ -486,7 +487,7 @@ if (PROACTOR STREQUAL "epoll" OR (NOT PROACTOR AND NOT 
BUILD_PROACTOR))
   check_symbol_exists(epoll_wait "sys/epoll.h" HAVE_EPOLL)
   if (HAVE_EPOLL)
     set (PROACTOR_OK epoll)
-    set (qpid-proton-proactor src/proactor/epoll.c 
src/proactor/proactor-internal.c src/sasl/remote_sasl.c)
+    set (qpid-proton-proactor src/proactor/epoll.c 
src/proactor/proactor-internal.c)
     set (PROACTOR_LIBS -lpthread)
     set_source_files_properties (${qpid-proton-proactor} PROPERTIES
       COMPILE_FLAGS "${COMPILE_WARNING_FLAGS} ${COMPILE_LANGUAGE_FLAGS} ${LTO}"
@@ -498,7 +499,7 @@ if (PROACTOR STREQUAL "libuv" OR (NOT PROACTOR AND NOT 
PROACTOR_OK))
   find_package(Libuv)
   if (LIBUV_FOUND)
     set (PROACTOR_OK libuv)
-    set (qpid-proton-proactor src/proactor/libuv.c 
src/proactor/proactor-internal.c src/sasl/remote_sasl.c)
+    set (qpid-proton-proactor src/proactor/libuv.c 
src/proactor/proactor-internal.c)
     set (PROACTOR_LIBS ${Libuv_LIBRARIES})
     set_source_files_properties (${qpid-proton-proactor} PROPERTIES
       COMPILE_FLAGS "${COMPILE_WARNING_FLAGS} ${COMPILE_LANGUAGE_FLAGS} ${LTO}"
@@ -623,6 +624,18 @@ if (qpid-proton-proactor)
     SOVERSION "${PN_LIB_SOMAJOR}"
     LINK_FLAGS "${CATCH_UNDEFINED} ${LTO}"
     )
+
+  add_library (qpid-proton-remotesasl SHARED src/sasl/remote_sasl.c)
+  target_link_libraries (qpid-proton-remotesasl LINK_PUBLIC 
qpid-proton-proactor)
+  target_link_libraries (qpid-proton-remotesasl LINK_PUBLIC qpid-proton-core)
+  list(APPEND LIB_TARGETS qpid-proton-remotesasl)
+  set_target_properties (
+    qpid-proton-remotesasl
+    PROPERTIES
+    VERSION   "${PN_LIB_SOMAJOR}.${PN_LIB_SOMINOR}"
+    SOVERSION "${PN_LIB_SOMAJOR}"
+    LINK_FLAGS "${CATCH_UNDEFINED} ${LTO}"
+    )
 endif()
 
 # Install executables and libraries
@@ -667,6 +680,7 @@ configure_lib(PROTONLIB qpid-proton)
 configure_lib(PROTONCORELIB qpid-proton-core)
 if(HAS_PROACTOR)
   configure_lib(PROTONPROACTORLIB qpid-proton-proactor)
+  configure_lib(PROTONREMOTESASLLIB qpid-proton-remotesasl)
 endif(HAS_PROACTOR)
 
 include(WriteBasicConfigVersionFile)

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/fe5dffdd/proton-c/include/proton/proactor.h
----------------------------------------------------------------------
diff --git a/proton-c/include/proton/proactor.h 
b/proton-c/include/proton/proactor.h
index 978453b..861afbe 100644
--- a/proton-c/include/proton/proactor.h
+++ b/proton-c/include/proton/proactor.h
@@ -285,10 +285,6 @@ PNP_EXTERN pn_proactor_t *pn_event_proactor(pn_event_t 
*event);
  */
 PNP_EXTERN pn_millis_t pn_proactor_now(void);
 
-PNP_EXTERN void pn_use_remote_authentication_service(pn_transport_t* 
transport, const char* address);
-PNP_EXTERN bool pn_is_authentication_service_connection(pn_connection_t* conn);
-PNP_EXTERN void pn_handle_authentication_service_connection_event(pn_event_t 
*e);
-
 /**
  * @defgroup proactor_events Events
  *

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/fe5dffdd/proton-c/include/proton/remote_sasl.h
----------------------------------------------------------------------
diff --git a/proton-c/include/proton/remote_sasl.h 
b/proton-c/include/proton/remote_sasl.h
new file mode 100644
index 0000000..462d1ec
--- /dev/null
+++ b/proton-c/include/proton/remote_sasl.h
@@ -0,0 +1,38 @@
+#ifndef PROTON_REMOTE_SASL_H
+#define PROTON_REMOTE_SASL_H 1
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include <proton/import_export.h>
+#include <proton/types.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+PN_EXPORT void pn_use_remote_authentication_service(pn_transport_t* transport, 
const char* address);
+PN_EXPORT bool pn_is_authentication_service_connection(pn_connection_t* conn);
+PN_EXPORT void pn_handle_authentication_service_connection_event(pn_event_t 
*e);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* remote_sasl.h */

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/fe5dffdd/proton-c/src/ProtonConfig.cmake.in
----------------------------------------------------------------------
diff --git a/proton-c/src/ProtonConfig.cmake.in 
b/proton-c/src/ProtonConfig.cmake.in
index 5b23be0..78bb586 100644
--- a/proton-c/src/ProtonConfig.cmake.in
+++ b/proton-c/src/ProtonConfig.cmake.in
@@ -37,6 +37,7 @@ if (HAS_PROACTOR)
   set (Proton_Proactor_INCLUDE_DIRS  @INCLUDEDIR@)
   set (Proton_Proactor_LIBRARIES     optimized @LIBDIR@/@PROTONPROACTORLIB@ 
debug @LIBDIR@/@PROTONPROACTORLIBDEBUG@)
   set (Proton_Proactor_FOUND True)
+  set (Proton_Remote_SASL_LIBRARIES     optimized 
@LIBDIR@/@PROTONREMOTESASLLIB@ debug @LIBDIR@/@PROTONREMOTESASLLIBDEBUG@)
 endif()
 
 # Check for all required components

http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/fe5dffdd/proton-c/src/sasl/remote_sasl.c
----------------------------------------------------------------------
diff --git a/proton-c/src/sasl/remote_sasl.c b/proton-c/src/sasl/remote_sasl.c
index d799a93..8721a51 100644
--- a/proton-c/src/sasl/remote_sasl.c
+++ b/proton-c/src/sasl/remote_sasl.c
@@ -24,6 +24,7 @@
 #include "core/engine-internal.h"
 #include "core/util.h"
 #include "proton/proactor.h"
+#include "proton/remote_sasl.h"
 
 typedef struct
 {


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@qpid.apache.org
For additional commands, e-mail: commits-h...@qpid.apache.org

Reply via email to