diff --git a/configure.ac b/configure.ac index 46aab00349027273084d0fe38b040a9f4a4ad89e..276131346a59272342921b2719a5cbfc140a9867 100644 --- a/configure.ac +++ b/configure.ac @@ -427,15 +427,6 @@ AS_CASE(["$with_tls"], AC_DEFINE_UNQUOTED([HAVE_TLS], `if test $HAVE_GNUTLS -eq 1; then echo 1; else echo 0; fi`, [Define if you have tls support]) AM_CONDITIONAL(BUILD_TLS, test "$HAVE_GNUTLS" -eq 1) -# Instant Messaging -AC_ARG_WITH([instant_messaging], - [AS_HELP_STRING([--without-instant_messaging], [disable support for instant-messaging])], - [], - [with_instant_messaging=yes]) - -AC_DEFINE_UNQUOTED([HAVE_INSTANT_MESSAGING], `if test "x$with_instant_messaging" = "xyes"; then echo 1; else echo 0; fi`, [Define if you have instant messaging support]) -AM_CONDITIONAL(BUILD_INSTANT_MESSAGING, test "x$with_instant_messaging" = "xyes" ) - # PTHREAD # required dependency(ies): libxpat diff --git a/src/Makefile.am b/src/Makefile.am index e76ec025602ae443b26fe73df09ba7492a3691a9..355fa00950cf061ba18b95587eb8fb50c7dc69f8 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -23,23 +23,7 @@ RING_VIDEO_LIBS+= \ endif endif -if BUILD_INSTANT_MESSAGING -INSTANT_MESSAGING_SUBDIR = im -IM_LIBA=./im/libim.la -endif - -if USE_DHT -RINGACC_SUBDIR=ringdht -RINGACC_CXXFLAG=-DUSE_DHT -RINGACC_LIBA=./ringdht/libringacc.la -endif - -if BUILD_TLS -TLS_LIB = @GNUTLS_LIBS@ -TLS_CFLAGS = @GNUTLS_CFLAGS@ -endif - -SUBDIRS = client media config hooks sip upnp security $(RINGACC_SUBDIR) $(INSTANT_MESSAGING_SUBDIR) $(RING_VIDEO_SUBDIR) +SUBDIRS = client media config hooks sip upnp security ringdht im $(RING_VIDEO_SUBDIR) # libring @@ -53,8 +37,8 @@ libring_la_LIBADD = \ ./hooks/libhooks.la \ ./security/libsecurity.la \ ./upnp/libupnpcontrol.la \ - $(RINGACC_LIBA) \ - $(IM_LIBA) \ + ./ringdht/libringacc.la \ + ./im/libim.la \ $(RING_VIDEO_LIBS) libring_la_LDFLAGS = \ diff --git a/src/call.h b/src/call.h index e5c3329990824e1ccd2238371895b2b07eb36e73..54c264a698d25a09a3977976d92b29b0bcfeb30b 100644 --- a/src/call.h +++ b/src/call.h @@ -299,7 +299,6 @@ class Call : public Recordable, public std::enable_shared_from_this<Call> { */ virtual void carryingDTMFdigits(char code) = 0; -#if HAVE_INSTANT_MESSAGING /** * Send a message to a call identified by its callid * @@ -308,7 +307,6 @@ class Call : public Recordable, public std::enable_shared_from_this<Call> { */ virtual void sendTextMessage(const std::map<std::string, std::string>& messages, const std::string &from) = 0; -#endif void removeCall(); diff --git a/src/client/callmanager.cpp b/src/client/callmanager.cpp index b190d9d30c8dbb3da7dbd7fd583a297c132ff234..9882973892eb3fdc1c8a36153736c0572132c549 100644 --- a/src/client/callmanager.cpp +++ b/src/client/callmanager.cpp @@ -324,9 +324,7 @@ acceptEnrollment(const std::string& /*callID*/, bool /*accepted*/) void sendTextMessage(const std::string& callID, const std::map<std::string, std::string>& messages, const std::string& from, bool isMixed) { -#if HAVE_INSTANT_MESSAGING ring::Manager::instance().sendCallTextMessage(callID, messages, from, isMixed); -#endif } } // namespace DRing diff --git a/src/manager.cpp b/src/manager.cpp index 6d2638770e2d504e6caf90835266251e67f79bca..4ed2b1240493bea3e7410ff9539d838eb367b085 100644 --- a/src/manager.cpp +++ b/src/manager.cpp @@ -1637,7 +1637,6 @@ Manager::incomingCall(Call &call, const std::string& accountId) } //THREAD=VoIP -#if HAVE_INSTANT_MESSAGING void Manager::sendTextMessageToConference(const Conference& conf, const std::map<std::string, std::string>& messages, @@ -1718,7 +1717,6 @@ Manager::sendCallTextMessage(const std::string& callID, } } } -#endif // HAVE_INSTANT_MESSAGING //THREAD=VoIP CALL=Outgoing void diff --git a/src/manager.h b/src/manager.h index a3dde6c34f8a07412b838319e1ac1b4b5497c304..886718480f7ca67770c69e89aa55279c638bf468 100644 --- a/src/manager.h +++ b/src/manager.h @@ -377,7 +377,6 @@ class Manager { */ void peerHungupCall(Call& call); -#if HAVE_INSTANT_MESSAGING /** * Notify the client with an incoming message * @param accountId The account identifier @@ -396,7 +395,6 @@ class Manager { void sendCallTextMessage(const std::string& callID, const std::map<std::string, std::string>& messages, const std::string& from, bool isMixed); -#endif // HAVE_INSTANT_MESSAGING /** * Notify the client he has voice mails @@ -1041,11 +1039,9 @@ class Manager { /* Sink ID mapping */ std::map<std::string, std::weak_ptr<video::SinkClient>> sinkMap_; -#if HAVE_INSTANT_MESSAGING void sendTextMessageToConference(const Conference& conf, const std::map<std::string, std::string>& messages, const std::string& from) const noexcept; -#endif #ifdef RING_VIDEO std::unique_ptr<VideoManager> videoManager_; diff --git a/src/sip/sipcall.cpp b/src/sip/sipcall.cpp index df972e9730dc98846ac92e12fd734e1534b86af5..4114a7ef4a30a7eea1c9e52b9db31cd802028866 100644 --- a/src/sip/sipcall.cpp +++ b/src/sip/sipcall.cpp @@ -34,15 +34,9 @@ #include "string_utils.h" #include "upnp/upnp_control.h" #include "sip_utils.h" - #include "audio/audio_rtp_session.h" - #include "system_codec_container.h" - -#if HAVE_INSTANT_MESSAGING #include "im/instant_messaging.h" -#endif - #include "dring/call_const.h" #include "dring/media_const.h" #include "client/ring_signal.h" @@ -666,7 +660,6 @@ SIPCall::carryingDTMFdigits(char code) dtmfSend(*this, code, getSIPAccount().getDtmfType()); } -#if HAVE_INSTANT_MESSAGING void SIPCall::sendTextMessage(const std::map<std::string, std::string>& messages, const std::string& /* from */) @@ -680,7 +673,6 @@ SIPCall::sendTextMessage(const std::map<std::string, std::string>& messages, im::sendSipMessage(inv.get(), messages); } -#endif // HAVE_INSTANT_MESSAGING void SIPCall::onFailure(signed cause) diff --git a/src/sip/sipcall.h b/src/sip/sipcall.h index 4c252066bb59aecdac7d368a3b6c18a5b50b9403..74f35b1980ecc77737ea681ef3a7b883e47335d3 100644 --- a/src/sip/sipcall.h +++ b/src/sip/sipcall.h @@ -156,10 +156,8 @@ class SIPCall : public Call void carryingDTMFdigits(char code) override; -#if HAVE_INSTANT_MESSAGING void sendTextMessage(const std::map<std::string, std::string>& messages, const std::string& from) override; -#endif SIPAccountBase& getSIPAccount() const; diff --git a/src/sip/sipvoiplink.cpp b/src/sip/sipvoiplink.cpp index 0457584e495b0f63da117b666df4887deb20cdc8..ce26c4805e8fafd68310c5d65182e58d02ebbdbd 100644 --- a/src/sip/sipvoiplink.cpp +++ b/src/sip/sipvoiplink.cpp @@ -41,10 +41,7 @@ #include "sdes_negotiator.h" #endif -#if HAVE_INSTANT_MESSAGING #include "im/instant_messaging.h" -#endif - #include "system_codec_container.h" #include "audio/audio_rtp_session.h" @@ -1113,7 +1110,6 @@ static void onRequestMessage(pjsip_inv_session* /*inv*/, pjsip_rx_data* /*rdata*/, pjsip_msg* msg, SIPCall& call) { -#if HAVE_INSTANT_MESSAGING if (!msg->body) return; @@ -1122,8 +1118,6 @@ onRequestMessage(pjsip_inv_session* /*inv*/, pjsip_rx_data* /*rdata*/, pjsip_msg // in the future Manager::instance().incomingMessage(call.getCallId(), call.getPeerNumber(), im::parseSipMessage(msg)); - -#endif // HAVE_INSTANT_MESSAGING } static void