aboutsummaryrefslogtreecommitdiff
path: root/net/asterisk/Makefile
diff options
context:
space:
mode:
authorMaxim Sobolev <sobomax@FreeBSD.org>2007-04-13 08:06:06 +0000
committerMaxim Sobolev <sobomax@FreeBSD.org>2007-04-13 08:06:06 +0000
commitacc33b14df77f1bad1c2d0a2c775185fa9e864eb (patch)
tree861d5d09092cff4fbc720b4a04db22add91bf3d3 /net/asterisk/Makefile
parent1409736de1222de37cb2e4296d6651803bc1eb80 (diff)
downloadports-acc33b14df77f1bad1c2d0a2c775185fa9e864eb.tar.gz
ports-acc33b14df77f1bad1c2d0a2c775185fa9e864eb.zip
Notes
Diffstat (limited to 'net/asterisk/Makefile')
-rw-r--r--net/asterisk/Makefile84
1 files changed, 53 insertions, 31 deletions
diff --git a/net/asterisk/Makefile b/net/asterisk/Makefile
index 084330745cb8..621b9f859077 100644
--- a/net/asterisk/Makefile
+++ b/net/asterisk/Makefile
@@ -6,20 +6,11 @@
#
PORTNAME= asterisk
-PORTVERSION= 1.2.13
-PORTREVISION= 4
+PORTVERSION= 1.4.2
CATEGORIES= net
MASTER_SITES= http://ftp.digium.com/pub/asterisk/ \
http://ftp.digium.com/pub/asterisk/old-releases/
-PATCHFILES= asterisk-1.2.12.1-codec-negotiation-20061009.diff.gz
-PATCH_SITES= http://unofficial.portaone.com/~bamby/public/
-
-# ${PORTNAME}-1.2.4-${BRIVER}.patch.gz:bristuff
-# ${MASTER_SITE_LOCAL:S,$,:bristuff,}
-#PATCH_SITE_SUBDIR= fjoe/:bristuff
-#BRIVER= bristuff-0.3.0-PRE-1l
-
MAINTAINER= sobomax@FreeBSD.org
COMMENT= An Open Source PBX and telephony toolkit
@@ -32,7 +23,9 @@ RUN_DEPENDS= mpg123:${PORTSDIR}/audio/mpg123
ONLY_FOR_ARCHS= i386 sparc64 amd64
GNU_CONFIGURE= yes
-CONFIGURE_WRKSRC= ${WRKSRC}/editline
+CONFIGURE_ARGS= --mandir=/usr/local/man
+CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
+ LDFLAGS="-L${LOCALBASE}/lib"
USE_GMAKE= yes
USE_BISON= yes
USE_RC_SUBR= asterisk.sh
@@ -43,35 +36,41 @@ MAKE_ENV= PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
OPENH323DIR=${LOCALBASE}/share/openh323 \
OSVERSION=${OSVERSION} \
CXX="${CXX}"
-PLIST_SUB= BRISTUFF="@comment "
MAN8= asterisk.8 astgenkey.8 autosupport.8 safe_asterisk.8
+OPTIONS= OGGVORBIS "Enable Ogg Vorbis support" on \
+ ODBC "Enable ODBC support" on \
+ POSTGRES "Enable PostgreSQL support" on \
+ RADIUS "Enable RADIUS accounting support" on \
+ SNMP "Enable SNMP support" on
+
.include <bsd.port.pre.mk>
-.if ${ARCH} != "i386"
-WITHOUT_H323= 1
-WITHOUT_ZAPTEL= 1
+.if ${ARCH} == "i386"
+OPTIONS+= H323 "Enable H.323 support" on \
+ ZAPTEL "Enable Zaptel support" on
.endif
.if defined(WITHOUT_H323)
PLIST_SUB+= WITH_H323="@comment "
+CONFIGURE_ARGS+= --without-h323
.else
-LIB_DEPENDS+= pt_r.1:${PORTSDIR}/devel/pwlib\
- h323_r.1:${PORTSDIR}/net/openh323
PLIST_SUB+= WITH_H323=""
-MAKE_ENV+= WITH_H323=1
+CONFIGURE_ARGS+= --with-h323
+LIB_DEPENDS+= pt_r.1:${PORTSDIR}/devel/pwlib \
+ h323_r.1:${PORTSDIR}/net/openh323
.endif
.if defined(WITHOUT_ZAPTEL)
PLIST_SUB+= WITH_ZAPTEL="@comment "
-MAKE_ENV+= WITHOUT_ZAPTEL=1
+CONFIGURE_ARGS+= --without-zaptel
.else
+PLIST_SUB+= WITH_ZAPTEL=""
+CONFIGURE_ARGS+= --with-zaptel
BUILD_DEPENDS+= libpri>=1.2.0:${PORTSDIR}/misc/libpri \
${LOCALBASE}/include/zaptel.h:${PORTSDIR}/misc/zaptel
LIB_DEPENDS+= pri.1:${PORTSDIR}/misc/libpri
RUN_DEPENDS+= ${LOCALBASE}/include/zaptel.h:${PORTSDIR}/misc/zaptel
-PLIST_SUB+= WITH_ZAPTEL=""
-MAKE_ENV+= WITH_ZAPTEL=1
.endif
#
@@ -79,24 +78,47 @@ MAKE_ENV+= WITH_ZAPTEL=1
# similarly
.if defined(WITHOUT_ODBC)
PLIST_SUB+= WITH_ODBC="@comment "
+CONFIGURE_ARGS+= --without-odbc
.else
-LIB_DEPENDS+= odbc.1:${PORTSDIR}/databases/unixODBC
PLIST_SUB+= WITH_ODBC=""
-MAKE_ENV+= WITH_ODBC=1
+CONFIGURE_ARGS+= --with-odbc
+LIB_DEPENDS+= odbc.1:${PORTSDIR}/databases/unixODBC
+.endif
+
+.if defined(WITHOUT_POSTGRES)
+PLIST_SUB+= WITH_POSTGRES="@comment "
+CONFIGURE_ARGS+= --without-postgres
+.else
+PLIST_SUB+= WITH_POSTGRES=""
+USE_PGSQL= yes
+CONFIGURE_ARGS+= --with-postgres
+.endif
+
+.if defined(WITHOUT_OGGVORBIS)
+PLIST_SUB+= WITH_OGGVORBIS="@comment "
+CONFIGURE_ARGS+= --without-ogg
+.else
+PLIST_SUB+= WITH_OGGVORBIS=""
+CONFIGURE_ARGS+= --with-ogg
+LIB_DEPENDS+= vorbis.3:${PORTSDIR}/audio/libvorbis
.endif
-.if defined(WITHOUT_FAX)
-PLIST_SUB+= WITH_FAX="@comment "
+.if defined(WITHOUT_RADIUS)
+PLIST_SUB+= WITH_RADIUS="@comment "
+CONFIGURE_ARGS+= --without-radius
.else
-MAKE_ENV+= WITH_FAX=1
-LIB_DEPENDS+= spandsp.0:${PORTSDIR}/comms/spandsp
-PLIST_SUB+= WITH_FAX=""
+PLIST_SUB+= WITH_RADIUS=""
+CONFIGURE_ARGS+= --with-radius
+LIB_DEPENDS+= radiusclient-ng.2:${PORTSDIR}/net/radiusclient
.endif
-.if ${OSVERSION} >= 500036
-PLIST_SUB+= NEWGCC=""
+.if defined(WITHOUT_SNMP)
+PLIST_SUB+= WITH_SNMP="@comment "
+CONFIGURE_ARGS+= --without-netsnmp
.else
-PLIST_SUB+= NEWGCC="@comment "
+PLIST_SUB+= WITH_SNMP=""
+CONFIGURE_ARGS+= --with-netsnmp
+LIB_DEPENDS+= netsnmp.10:${PORTSDIR}/net-mgmt/net-snmp
.endif
post-patch: