summaryrefslogtreecommitdiff
path: root/net/asterisk12/files
diff options
context:
space:
mode:
authorMaxim Sobolev <sobomax@FreeBSD.org>2007-07-31 21:18:09 +0000
committerMaxim Sobolev <sobomax@FreeBSD.org>2007-07-31 21:18:09 +0000
commitf93d68c0890a0565bedfb079bc09b4e610c83a50 (patch)
tree6a25843585d95d165634bf1889b8d1dbd1417560 /net/asterisk12/files
parentUpdate to 2.0.10 (diff)
o Upgrade to 1.2.23.
o Disable fax-related modules since they don't compile with newest spandsp. o Enable FreeTDS support (could be disabled using WITHOUT_FREETDS knob). Sponsored by: Sippy Software, Inc. ( http://www.sippysoft.com/ )
Diffstat (limited to 'net/asterisk12/files')
-rw-r--r--net/asterisk12/files/patch-Makefile4
-rw-r--r--net/asterisk12/files/patch-cdr::Makefile2
-rw-r--r--net/asterisk12/files/patch-channels::Makefile14
-rw-r--r--net/asterisk12/files/patch-channels::chan_sip.c20
4 files changed, 22 insertions, 18 deletions
diff --git a/net/asterisk12/files/patch-Makefile b/net/asterisk12/files/patch-Makefile
index 432d517b4956..779f7d635207 100644
--- a/net/asterisk12/files/patch-Makefile
+++ b/net/asterisk12/files/patch-Makefile
@@ -343,7 +343,7 @@ $FreeBSD$
+ $(BSD_INSTALL_SCRIPT) contrib/scripts/astgenkey $(DESTDIR)$(ASTSBINDIR)/
+ $(BSD_INSTALL_SCRIPT) contrib/scripts/autosupport $(DESTDIR)$(ASTSBINDIR)/
if [ ! -f $(DESTDIR)$(ASTSBINDIR)/safe_asterisk ]; then \
- cat contrib/scripts/safe_asterisk | sed 's|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;' > $(DESTDIR)$(ASTSBINDIR)/safe_asterisk ;\
+ cat contrib/scripts/safe_asterisk | sed 's|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;s|__ASTERISK_VARRUN_DIR__|$(ASTVARRUNDIR)|;' > $(DESTDIR)$(ASTSBINDIR)/safe_asterisk ;\
chmod 755 $(DESTDIR)$(ASTSBINDIR)/safe_asterisk;\
fi
- $(INSTALL) -d $(DESTDIR)$(ASTHEADERDIR)
@@ -470,7 +470,7 @@ $FreeBSD$
done
- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
- for x in sounds/*.mp3; do \
+ for x in sounds/moh/*.mp3 sounds/moh/LICENSE; do \
- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
done
diff --git a/net/asterisk12/files/patch-cdr::Makefile b/net/asterisk12/files/patch-cdr::Makefile
index 8628383461d2..5b905c7778ef 100644
--- a/net/asterisk12/files/patch-cdr::Makefile
+++ b/net/asterisk12/files/patch-cdr::Makefile
@@ -30,7 +30,7 @@ $FreeBSD$
#
-ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/freetds/tds.h),)
- ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/local/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/include/freetds/tdsver.h | grep -c 0.64),1)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/freetds/tds.h),)
++ifdef WITH_FREETDS
+ ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/include/freetds/tdsver.h | grep -c 0.64),1)
CFLAGS += -DFREETDS_0_64
else
diff --git a/net/asterisk12/files/patch-channels::Makefile b/net/asterisk12/files/patch-channels::Makefile
index b80c1bfdf134..56539d83d6b9 100644
--- a/net/asterisk12/files/patch-channels::Makefile
+++ b/net/asterisk12/files/patch-channels::Makefile
@@ -14,7 +14,7 @@ $FreeBSD$
CHANH323LIB=-pthread
endif
-@@ -75,11 +75,11 @@
+@@ -75,7 +75,7 @@
SOLINK+=-lrt
endif
@@ -23,12 +23,16 @@ $FreeBSD$
CHANNEL_LIBS+=chan_phone.so
endif
+@@ -83,7 +83,7 @@
+ CFLAGS+=-DHAVE_LINUX_COMPILER_H
+ endif
+
-ifneq ($(wildcard h323/libchanh323.a),)
+ifdef WITH_H323
CHANNEL_LIBS+=chan_h323.so
endif
-@@ -94,12 +94,12 @@
+@@ -102,12 +102,12 @@
CHANNEL_LIBS+=chan_alsa.so
endif
@@ -43,7 +47,7 @@ $FreeBSD$
CFLAGS+=-DZAPATA_R2
ZAPR2=-lmfcr2
endif
-@@ -112,12 +112,12 @@
+@@ -120,12 +120,12 @@
endif
ifndef WITHOUT_ZAPTEL
@@ -58,7 +62,7 @@ $FreeBSD$
endif
CFLAGS+=-DIAX_TRUNKING
CHANNEL_LIBS+=chan_zap.so
-@@ -233,8 +233,10 @@
+@@ -241,8 +241,10 @@
chan_h323.so: chan_h323.o h323/libchanh323.a h323/Makefile.ast
$(CC) $(SOLINK) $(H323LDFLAGS) -o $@ $< h323/libchanh323.a $(H323LDLIBS) -lstdc++
else
@@ -71,7 +75,7 @@ $FreeBSD$
endif
misdn/chan_misdn_lib.a:
-@@ -253,8 +255,7 @@
+@@ -261,8 +263,7 @@
# $(CC) -rdynamic -shared -Xlinker -x -o $@ $<
install: all
diff --git a/net/asterisk12/files/patch-channels::chan_sip.c b/net/asterisk12/files/patch-channels::chan_sip.c
index 8c24eff3a3aa..c06789847723 100644
--- a/net/asterisk12/files/patch-channels::chan_sip.c
+++ b/net/asterisk12/files/patch-channels::chan_sip.c
@@ -3,7 +3,7 @@ $FreeBSD$
--- channels/chan_sip.c.orig
+++ channels/chan_sip.c
-@@ -340,7 +340,7 @@
+@@ -339,7 +339,7 @@
static char default_language[MAX_LANGUAGE] = "";
@@ -20,7 +20,7 @@ $FreeBSD$
char hop[0];
};
-@@ -2815,6 +2816,8 @@
+@@ -2835,6 +2836,8 @@
ast_codec_pref_remove2(&tmp->nativeformats, ~i->usercapability);
fmt = ast_codec_pref_index_audio(&tmp->nativeformats, 0);
@@ -29,7 +29,7 @@ $FreeBSD$
if (title)
snprintf(tmp->name, sizeof(tmp->name), "SIP/%s-%08x", title, (int)(long) i);
else if (strchr(i->fromdomain,':'))
-@@ -6222,6 +6225,7 @@
+@@ -6312,6 +6315,7 @@
/* Make a struct route */
thishop = malloc(sizeof(*thishop) + len);
if (thishop) {
@@ -37,7 +37,7 @@ $FreeBSD$
ast_copy_string(thishop->hop, rr, len);
ast_log(LOG_DEBUG, "build_route: Record-Route hop: <%s>\n", thishop->hop);
/* Link in */
-@@ -6247,31 +6251,41 @@
+@@ -6337,31 +6341,41 @@
/* Only append the contact if we are dealing with a strict router */
if (!head || (!ast_strlen_zero(head->hop) && strstr(head->hop,";lr") == NULL) ) {
@@ -103,7 +103,7 @@ $FreeBSD$
}
}
}
-@@ -9248,6 +9262,13 @@
+@@ -9356,6 +9370,13 @@
secret = p->peersecret;
md5secret = p->peermd5secret;
}
@@ -117,7 +117,7 @@ $FreeBSD$
if (ast_strlen_zero(username)) /* We have no authentication */
return -1;
-@@ -10621,7 +10642,11 @@
+@@ -10759,7 +10780,11 @@
gotdest = get_destination(p, NULL);
get_rdnis(p, NULL);
@@ -130,7 +130,7 @@ $FreeBSD$
build_contact(p);
if (gotdest) {
-@@ -10649,7 +10674,6 @@
+@@ -10780,7 +10805,6 @@
c = sip_new(p, AST_STATE_DOWN, ast_strlen_zero(p->username) ? NULL : p->username );
*recount = 1;
/* Save Record-Route for any later requests we make on this dialogue */
@@ -138,17 +138,17 @@ $FreeBSD$
if (c) {
/* Pre-lock the call */
ast_mutex_lock(&c->lock);
-@@ -10735,7 +10759,12 @@
+@@ -10867,7 +10891,12 @@
transmit_response(p, "180 Ringing", req);
break;
case AST_STATE_UP:
-- /* Here we have reINVITE request - try to renegotiate codecs with */
+- /* If this is not a re-invite or something to ignore - it's critical */
+ /* Assuming this to be reinvite, process new SDP portion */
+ if (!ast_strlen_zero(get_header(req, "Content-Type"))) {
+ process_sdp(p, req);
+ } else {
+ ast_log(LOG_DEBUG, "Hm.... No sdp for the moment\n");
+ }
- transmit_response_with_sdp(p, "200 OK", req, 1);
+ transmit_response_with_sdp(p, "200 OK", req, (ignore || reinvite) ? 1 : 2);
break;
default: