You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by kg...@apache.org on 2012/09/10 20:08:00 UTC

svn commit: r1383014 - in /qpid/proton/branches/driver_abstraction/proton-c: CMakeLists.txt src/driver-internal.h src/driver.c src/driver_impl.h src/drivers/openssl.c src/drivers/poll.c src/drivers/ssl_stub.c

Author: kgiusti
Date: Mon Sep 10 18:08:00 2012
New Revision: 1383014

URL: http://svn.apache.org/viewvc?rev=1383014&view=rev
Log:
PROTON-2: fix the SSL build, rename file for consistency.

Added:
    qpid/proton/branches/driver_abstraction/proton-c/src/driver-internal.h   (contents, props changed)
      - copied, changed from r1382918, qpid/proton/branches/driver_abstraction/proton-c/src/driver_impl.h
Removed:
    qpid/proton/branches/driver_abstraction/proton-c/src/driver_impl.h
Modified:
    qpid/proton/branches/driver_abstraction/proton-c/CMakeLists.txt
    qpid/proton/branches/driver_abstraction/proton-c/src/driver.c
    qpid/proton/branches/driver_abstraction/proton-c/src/drivers/openssl.c
    qpid/proton/branches/driver_abstraction/proton-c/src/drivers/poll.c
    qpid/proton/branches/driver_abstraction/proton-c/src/drivers/ssl_stub.c

Modified: qpid/proton/branches/driver_abstraction/proton-c/CMakeLists.txt
URL: http://svn.apache.org/viewvc/qpid/proton/branches/driver_abstraction/proton-c/CMakeLists.txt?rev=1383014&r1=1383013&r2=1383014&view=diff
==============================================================================
--- qpid/proton/branches/driver_abstraction/proton-c/CMakeLists.txt (original)
+++ qpid/proton/branches/driver_abstraction/proton-c/CMakeLists.txt Mon Sep 10 18:08:00 2012
@@ -61,7 +61,7 @@ endif (POLLER STREQUAL poll)
 # Link in openssl if present
 if (SSL_IMPL STREQUAL openssl)
   set (pn_driver_ssl_impl src/drivers/openssl.c)
-  set (LINK_DEPS ${LINK_DEPS} ssl crypto)
+  set (SSL_LIB ssl crypto)
 else (SSL_IMPL STREQUAL openssl)
   set (pn_driver_ssl_impl src/drivers/ssl_stub.c)
 endif (SSL_IMPL STREQUAL openssl)
@@ -109,7 +109,7 @@ add_library (
   ${PROJECT_BINARY_DIR}/encodings.h
   ${PROJECT_BINARY_DIR}/protocol.h
 )
-target_link_libraries (qpid-proton ${UUID_LIB})
+target_link_libraries (qpid-proton ${UUID_LIB} ${SSL_LIB})
 
 add_executable (proton src/proton.c)
 target_link_libraries (proton qpid-proton)

Copied: qpid/proton/branches/driver_abstraction/proton-c/src/driver-internal.h (from r1382918, qpid/proton/branches/driver_abstraction/proton-c/src/driver_impl.h)
URL: http://svn.apache.org/viewvc/qpid/proton/branches/driver_abstraction/proton-c/src/driver-internal.h?p2=qpid/proton/branches/driver_abstraction/proton-c/src/driver-internal.h&p1=qpid/proton/branches/driver_abstraction/proton-c/src/driver_impl.h&r1=1382918&r2=1383014&rev=1383014&view=diff
==============================================================================
--- qpid/proton/branches/driver_abstraction/proton-c/src/driver_impl.h (original)
+++ qpid/proton/branches/driver_abstraction/proton-c/src/driver-internal.h Mon Sep 10 18:08:00 2012
@@ -1,5 +1,5 @@
-#ifndef PROTON_SRC_DRIVER_H
-#define PROTON_SRC_DRIVER_H 1
+#ifndef PROTON_SRC_DRIVER_INTERNAL_H
+#define PROTON_SRC_DRIVER_INTERNAL_H 1
 /*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
@@ -111,4 +111,4 @@ void pn_connector_process_output(pn_conn
 void pn_connector_process_input(pn_connector_t *);
 
 
-#endif /* driver.h */
+#endif /* driver-internal.h */

Propchange: qpid/proton/branches/driver_abstraction/proton-c/src/driver-internal.h
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: qpid/proton/branches/driver_abstraction/proton-c/src/driver.c
URL: http://svn.apache.org/viewvc/qpid/proton/branches/driver_abstraction/proton-c/src/driver.c?rev=1383014&r1=1383013&r2=1383014&view=diff
==============================================================================
--- qpid/proton/branches/driver_abstraction/proton-c/src/driver.c (original)
+++ qpid/proton/branches/driver_abstraction/proton-c/src/driver.c Mon Sep 10 18:08:00 2012
@@ -24,7 +24,7 @@
 #include <proton/driver.h>
 #include <proton/sasl.h>
 #include "util.h"
-#include "driver_impl.h"
+#include "driver-internal.h"
 #include "drivers/ssl.h"
 
 #include <stdio.h>

Modified: qpid/proton/branches/driver_abstraction/proton-c/src/drivers/openssl.c
URL: http://svn.apache.org/viewvc/qpid/proton/branches/driver_abstraction/proton-c/src/drivers/openssl.c?rev=1383014&r1=1383013&r2=1383014&view=diff
==============================================================================
--- qpid/proton/branches/driver_abstraction/proton-c/src/drivers/openssl.c (original)
+++ qpid/proton/branches/driver_abstraction/proton-c/src/drivers/openssl.c Mon Sep 10 18:08:00 2012
@@ -22,7 +22,7 @@
 #define _POSIX_C_SOURCE 1
 
 #include <proton/driver.h>
-#include "../driver_impl.h"
+#include "../driver-internal.h"
 #include "../util.h"
 
 #include <openssl/ssl.h>

Modified: qpid/proton/branches/driver_abstraction/proton-c/src/drivers/poll.c
URL: http://svn.apache.org/viewvc/qpid/proton/branches/driver_abstraction/proton-c/src/drivers/poll.c?rev=1383014&r1=1383013&r2=1383014&view=diff
==============================================================================
--- qpid/proton/branches/driver_abstraction/proton-c/src/drivers/poll.c (original)
+++ qpid/proton/branches/driver_abstraction/proton-c/src/drivers/poll.c Mon Sep 10 18:08:00 2012
@@ -23,7 +23,7 @@
 
 #include <proton/driver.h>
 #include "../util.h"
-#include "../driver_impl.h"
+#include "../driver-internal.h"
 
 #include <poll.h>
 #include <unistd.h>

Modified: qpid/proton/branches/driver_abstraction/proton-c/src/drivers/ssl_stub.c
URL: http://svn.apache.org/viewvc/qpid/proton/branches/driver_abstraction/proton-c/src/drivers/ssl_stub.c?rev=1383014&r1=1383013&r2=1383014&view=diff
==============================================================================
--- qpid/proton/branches/driver_abstraction/proton-c/src/drivers/ssl_stub.c (original)
+++ qpid/proton/branches/driver_abstraction/proton-c/src/drivers/ssl_stub.c Mon Sep 10 18:08:00 2012
@@ -22,8 +22,11 @@
 #define _POSIX_C_SOURCE 1
 
 #include <proton/driver.h>
+#include "../driver-internal.h"
 #include "ssl.h"
 
+#include <stdio.h>
+
 
 /** @file
  * SSL/TLS support API.
@@ -40,18 +43,24 @@ int pn_listener_ssl_server_init(pn_liste
                                 const char *password,
                                 const char *certificate_db)
 {
-    return -1;
+  if (listener->driver->trace & PN_TRACE_DRV) {
+    fprintf(stderr, "pn_listener_ssl_server_init(): SSL not available.\n");
+  }
+  return -1;
 }
 
 int pn_listener_ssl_allow_unsecured_clients(pn_listener_t *listener)
 {
-    return -1;
+  return -1;
 }
 
 int pn_connector_ssl_client_init(pn_connector_t *connector,
                                  const char *certificate_db)
 {
-    return -1;
+  if (connector->trace & PN_TRACE_DRV) {
+    fprintf(stderr, "pn_connector_ssl_client_init(): SSL not available.\n");
+  }
+  return -1;
 }
 
 int pn_connector_ssl_set_client_auth(pn_connector_t *connector,
@@ -59,24 +68,24 @@ int pn_connector_ssl_set_client_auth(pn_
                                      const char *private_key_file,
                                      const char *password)
 {
-    return -1;
+  return -1;
 }
 
 int pn_connector_ssl_authenticate_client(pn_connector_t *connector,
                                          const char *trusted_CAs_file)
 {
-    return -1;
+  return -1;
 }
 
 int pn_listener_init_ssl_client( pn_listener_t *l, pn_connector_t *c)
 {
-    return 0;  // support routine - always succeed.
+  return 0;  // support routine - always succeed.
 }
 
 void pn_connector_shutdown_ssl( pn_connector_t *c)
 {
-    // since there's no SSL/TLS, we just close the connector
-    pn_connector_close( c );
+  // since there's no SSL/TLS, we just close the connector
+  pn_connector_close( c );
 }
 
 



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