[pan2: 217/268] build fixes https://bugzilla.gnome.org/show_bug.cgi?id=665032



commit 72c8148cc5bf24ae7715f40864e1e665734944df
Author: Heinrich MÃller <sphemuel stud informatik uni-erlangen de>
Date:   Mon Nov 28 22:05:04 2011 +0100

    build fixes https://bugzilla.gnome.org/show_bug.cgi?id=665032

 configure.in                 |   14 +++++++++++++-
 pan/gui/gui.h                |    2 ++
 pan/tasks/socket-impl-main.h |   38 +++++++++++++++++++-------------------
 3 files changed, 34 insertions(+), 20 deletions(-)
---
diff --git a/configure.in b/configure.in
index e1e2263..6ab3e39 100644
--- a/configure.in
+++ b/configure.in
@@ -52,12 +52,14 @@ GTK3_REQUIRED=3.0.0
 GTKSPELL_REQUIRED=2.0.7
 OPENSSL_REQUIRED=1.0.0
 LIBNOTIFY_REQUIRED=0.4.1
+LIBGSASL_REQUIRED=1.6.1
 AC_SUBST(GLIB_REQUIRED)
 AC_SUBST(GMIME_REQUIRED)
 AC_SUBST(GTK_REQUIRED)
 AC_SUBST(GTKSPELL_REQUIRED)
 AC_SUBST(OPENSSL_REQUIRED)
 AC_SUBST(LIBNOTIFY_REQUIRED)
+AC_SUBST(LIBGSASL_REQUIRED)
 
 AC_PROG_CXX
 AC_HEADER_STDC
@@ -115,6 +117,7 @@ if test "x$want_openssl" = "xyes" ; then
 	                  AC_MSG_RESULT(no)])
 fi
 
+dnl Check for libnotify if user-enabled for popup notifications
 AC_ARG_ENABLE([libnotify],
 AC_HELP_STRING([--enable-libnotify],[enable libnotify support]),,[enable_libnotify=yes])
 if test "x$enable_libnotify" = "xyes" ; then
@@ -122,10 +125,19 @@ if test "x$enable_libnotify" = "xyes" ; then
   AC_SUBST([LIBNOTIFY_CFLAGS])
   AC_SUBST([LIBNOTIFY_LIBS])
   if test "x$HAVE_LIBNOTIFY" = "xyes"; then
-    AC_DEFINE([HAVE_LIBNOTIFY],[1],[libnotify is available on this machine])
+    AC_DEFINE([HAVE_LIBNOTIFY],[1],[libnotify for popup notifications (experimental)])
   fi
 fi
 
+dnl Check for gsasl for secure authentication
+PKG_CHECK_MODULES([LIBGSASL],[libgsasl >= $LIBGSASL_REQUIRED],[HAVE_SASL="yes"],[HAVE_SASL="no"])
+AC_SUBST([LIBGSASL_CFLAGS])
+AC_SUBST([LIBGSASL_LIBS])
+if test "x$HAVE_SASL" = "xyes"; then
+  AC_DEFINE([HAVE_SASL],[1],[libgsasl for secure NNTP authentication])
+fi
+
+
 dnl Check to see if strftime supports the use of %l and %k
 AC_MSG_CHECKING(for %l and %k support in strftime)
 AC_TRY_RUN([
diff --git a/pan/gui/gui.h b/pan/gui/gui.h
index 32ab8e9..553a08c 100644
--- a/pan/gui/gui.h
+++ b/pan/gui/gui.h
@@ -64,7 +64,9 @@ namespace pan
 
       struct VerifyData
       {
+#ifdef HAVE_OPENSSL
         X509* cert;
+#endif
         std::string server;
         std::string cert_name;
         int nr;
diff --git a/pan/tasks/socket-impl-main.h b/pan/tasks/socket-impl-main.h
index b0db92c..0e7a73a 100644
--- a/pan/tasks/socket-impl-main.h
+++ b/pan/tasks/socket-impl-main.h
@@ -157,25 +157,25 @@ namespace pan
                                   Socket::Creator::Listener * listener,
                                   bool               use_ssl);
 
-      struct Listener
-      {
-        virtual ~Listener() {}
-        /* functions that other listeners listen on */
-        virtual void on_handshake_done (X509* cert UNUSED, std::string server UNUSED, std::string cert_name UNUSED, int nr UNUSED) = 0;
-      };
-
-      typedef std::set<Listener*> listeners_t;
-      listeners_t _listeners;
-
-      void add_listener (Listener * l)    { _listeners.insert(l); }
-      void remove_listener (Listener * l) { _listeners.erase(l);  }
-
-      /* notify functions for listener list */
-      void handshake_done (X509* c, std::string server, std::string cn, int nr)
-      {
-        for (listeners_t::iterator it(_listeners.begin()), end(_listeners.end()); it!=end; ++it)
-          (*it)->on_handshake_done (c, server, cn, nr);
-      }
+//      struct Listener
+//      {
+//        virtual ~Listener() {}
+//        /* functions that other listeners listen on */
+//        virtual void on_handshake_done (X509* cert UNUSED, std::string server UNUSED, std::string cert_name UNUSED, int nr UNUSED) = 0;
+//      };
+//
+//      typedef std::set<Listener*> listeners_t;
+//      listeners_t _listeners;
+//
+//      void add_listener (Listener * l)    { _listeners.insert(l); }
+//      void remove_listener (Listener * l) { _listeners.erase(l);  }
+//
+//      /* notify functions for listener list */
+//      void handshake_done (X509* c, std::string server, std::string cn, int nr)
+//      {
+//        for (listeners_t::iterator it(_listeners.begin()), end(_listeners.end()); it!=end; ++it)
+//          (*it)->on_handshake_done (c, server, cn, nr);
+//      }
 
   };
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]