Lines 1-101
Link Here
|
1 |
PORTNAME= pjsip |
1 |
PORTNAME= pjsip |
2 |
DISTVERSION= 2.13.1 |
2 |
DISTVERSION= 2.14.1 |
3 |
PORTREVISION= 1 |
3 |
PORTREVISION= 1 |
4 |
CATEGORIES= net |
4 |
CATEGORIES= net |
5 |
|
5 |
|
6 |
MAINTAINER= ports@FreeBSD.org |
6 |
MAINTAINER= oliver.epper@gmail.com |
7 |
COMMENT= Multimedia communication library written in C language |
7 |
COMMENT= Multimedia communication library written in C language |
8 |
WWW= https://www.pjsip.org/ |
8 |
WWW= https://www.pjsip.org/ |
9 |
|
9 |
|
10 |
LICENSE= GPLv2+ |
10 |
LICENSE= GPLv2+ |
11 |
LICENSE_FILE= ${WRKSRC}/COPYING |
11 |
LICENSE_FILE= ${WRKSRC}/COPYING |
12 |
|
12 |
|
13 |
LIB_DEPENDS= libportaudio.so:audio/portaudio \ |
13 |
USES= cpe gmake localbase ssl pkgconfig |
14 |
libuuid.so:misc/e2fsprogs-libuuid |
14 |
CPE_VENDOR= teluu |
15 |
|
|
|
16 |
USES= cpe gmake localbase pathfix ssl tar:bz2 |
17 |
USE_LDCONFIG= yes |
15 |
USE_LDCONFIG= yes |
18 |
|
16 |
|
19 |
USE_GITHUB= yes |
17 |
USE_GITHUB= yes |
20 |
GH_PROJECT= pjproject |
18 |
GH_PROJECT= pjproject |
21 |
|
19 |
|
22 |
CPE_VENDOR= teluu |
|
|
23 |
|
24 |
GNU_CONFIGURE= yes |
20 |
GNU_CONFIGURE= yes |
25 |
CONFIGURE_ARGS= --with-external-pa \ |
|
|
26 |
--disable-silk |
27 |
PATHFIX_MAKEFILEIN= Makefile |
28 |
PLIST_SUB= CONFIGURE_TARGET="${CONFIGURE_TARGET}" |
29 |
|
21 |
|
30 |
OPTIONS_DEFINE= AMR DEBUG EXTSRTP FFMPEG G711 G722 G7221 GSM ILBC IPV6 \ |
22 |
PLIST_SUB= CONFIGURE_TARGET="${CONFIGURE_TARGET}" |
31 |
L16 OPENH264 OPUS PJSUA PJSUA2 RESAMPLE RESAMPLEDLL \ |
|
|
32 |
SAMPLERATE SDL SHARED SOUND SPEEX SPEEXAEC V4L VIDEO VPX WEBRTC |
33 |
OPTIONS_DEFAULT=G711 G722 G7221 GSM ILBC L16 OPUS PJSUA2 SHARED SPEEX SPEEXAEC \ |
34 |
VIDEO VPX WEBRTC |
35 |
|
36 |
EXTSRTP_DESC= Use libsrtp port (needed to get SRTP support in asterisk pjsip backend) |
37 |
G711_DESC= G.711 codec support |
38 |
G722_DESC= G.722 codec support |
39 |
G7221_DESC= G.722.1 codec support |
40 |
ILBC_DESC= iLBC codec support |
41 |
L16_DESC= Linear/L16 codec support |
42 |
OPENH264_DESC= OpenH264 support |
43 |
PJSUA_DESC= Command line SIP agent |
44 |
PJSUA2_DESC= SIP User agent 2 library |
45 |
RESAMPLE_DESC= Enable resampling implementations |
46 |
RESAMPLEDLL_DESC= Build libresample as shared library |
47 |
SHARED_DESC= Build shared libraries (other ports may depend on this) |
48 |
SPEEXAEC_DESC= Speex Acoustic Echo Canceller/AEC |
49 |
WEBRTC_DESC= Build libwebrtc |
50 |
|
23 |
|
|
|
24 |
OPTIONS_DEFINE= APPS DEBUG FFMPEG KQUEUE PA PJSUA2 RESAMPLEDLL SHARED SOUND \ |
25 |
SRTP UPNP VIDEO WEBRTC YUV |
26 |
OPTIONS_DEFAULT=G711 G722 KQUEUE OPUS PA PJSUA2 RESAMPLE SHARED SOUND SPEEX \ |
27 |
SRTP VIDEO WEBRTC YUV |
28 |
OPTIONS_GROUP= CODECS |
29 |
OPTIONS_GROUP_CODECS= AMR BCG729 G711 G722 G7221 GSM ILBC L16 OPUS SILK \ |
30 |
SPEEX SPEEXAEC |
31 |
OPTIONS_SINGLE= RESAMPLEIMP |
32 |
OPTIONS_SINGLE_RESAMPLEIMP= RESAMPLE SAMPLERATE SPEEXRESAMPLE NONE |
51 |
OPTIONS_SUB= yes |
33 |
OPTIONS_SUB= yes |
52 |
|
34 |
|
53 |
AMR_CONFIGURE_WITH= opencore-amr |
35 |
BCG729_DESC= bcg729 codec support |
54 |
AMR_LIB_DEPENDS= libopencore-amrwb.so:audio/opencore-amr \ |
36 |
CODECS_DESC= Codecs & Echo Cancellation |
55 |
libvo-amrwbenc.so:audio/vo-amrwbenc |
37 |
G711_DESC= G.711 codec support |
56 |
DEBUG_CFLAGS= -DNDEBUG=0 |
38 |
G7221_DESC= G.722.1 codec support |
57 |
DEBUG_CFLAGS_OFF= -DNDEBUG=1 |
39 |
G722_DESC= G.722 codec support |
58 |
EXTSRTP_CONFIGURE_WITH= external-srtp |
40 |
ILBC_DESC= iLBC codec support |
59 |
EXTSRTP_CONFLICTS_OFF= libsrtp libsrtp2 |
41 |
KQUEUE_DESC= Use kqueue ioqueue on macos/BSD (experimental) |
60 |
EXTSRTP_LIB_DEPENDS= libsrtp2.so:net/libsrtp2 |
42 |
L16_DESC= Linear/L16 codec support |
61 |
FFMPEG_CONFIGURE_ENABLE= ffmpeg |
43 |
PA_DESC= Use external PortAudio development files |
62 |
FFMPEG_LIB_DEPENDS= libswresample.so:multimedia/ffmpeg |
44 |
PJSUA2_DESC= Enable pjsua2 library |
63 |
G711_CONFIGURE_ENABLE= g711-codec |
45 |
PJSUA_DESC= Command line SIP agent |
64 |
G722_CONFIGURE_ENABLE= g722-codec |
46 |
RESAMPLEDLL_DESC= Build libresample as a shared library |
65 |
G7221_CONFIGURE_ENABLE= g7221-codec |
47 |
RESAMPLE_DESC= Enable resampling implementations |
66 |
GSM_CONFIGURE_ENABLE= gsm-codec |
48 |
APPS_DESC= Install apps & samples from the pjsip-apps directory |
67 |
GSM_CONFIGURE_ON= --with-external-gsm |
49 |
SHARED_DESC= Build shared libraries (other ports may depend on this) |
68 |
GSM_LIB_DEPENDS= libgsm.so:audio/gsm |
50 |
SILK_DESC= Enable SILK support |
69 |
ILBC_CONFIGURE_ENABLE= ilbc-codec |
51 |
SOUND_DESC= Include sound in the build |
70 |
IPV6_CFLAGS= -DPJ_HAS_IPV6=1 |
52 |
SPEEXAEC_DESC= Speex Acoustic Echo Canceller/AEC |
71 |
IPV6_CFLAGS_OFF= -DPJ_HAS_IPV6=0 |
53 |
SPEEXRESAMPLE_DESC= Enable Speex resample |
72 |
L16_CONFIGURE_ENABLE= l16-codec |
54 |
SRTP_DESC= Secure Real-Time Transport Protocol – SRTP support |
73 |
OPENH264_CONFIGURE_ENABLE= openh264 |
55 |
WEBRTC_DESC= Include libwebrtc in the build |
74 |
OPENH264_LIB_DEPENDS= libopenh264.so:multimedia/openh264 |
56 |
YUV_DESC= Include libyuv in the build |
75 |
OPUS_CONFIGURE_ENABLE= opus |
57 |
RESAMPLEIMP_DESC= Resample Implementations |
76 |
OPUS_LIB_DEPENDS= libopus.so:audio/opus |
58 |
NONE_DESC= Disable resampling implementations |
77 |
PJSUA2_CONFIGURE_ENABLE= pjsua2 |
59 |
|
|
|
60 |
# general options |
61 |
|
62 |
DEBUG_CFLAGS= -DNDEBUG=0 |
63 |
DEBUG_CFLAGS_OFF= -DNDEBUG=1 |
64 |
|
65 |
FFMPEG_LIB_DEPENDS= libswresample.so:multimedia/ffmpeg |
66 |
FFMPEG_CONFIGURE_OFF= --disable-ffmpeg |
67 |
|
68 |
# This can become KQUEUE_CONFIGURE_ENABLE once |
69 |
# https://github.com/pjsip/pjproject/commit/c36802585ddefb3ca477d1f6d773d179510c5412 |
70 |
# is included in the next release (> 2.14.1). |
71 |
KQUEUE_CONFIGURE_ON= --enable-kqueue |
72 |
|
73 |
PA_LIB_DEPENDS= libportaudio.so:audio/portaudio |
74 |
PA_CONFIGURE_ON= --with-external-pa |
75 |
|
76 |
PJSUA2_CONFIGURE_OFF= --disable-pjsua2 |
77 |
|
78 |
RESAMPLE_CONFIGURE_ENABLE= resample |
78 |
RESAMPLE_CONFIGURE_ENABLE= resample |
|
|
79 |
|
79 |
RESAMPLEDLL_CONFIGURE_ENABLE= resample-dll |
80 |
RESAMPLEDLL_CONFIGURE_ENABLE= resample-dll |
80 |
SAMPLERATE_CONFIGURE_ENABLE= libsamplerate |
81 |
RESAMPLEDLL_IMPLIES= RESAMPLE |
|
|
82 |
|
81 |
SAMPLERATE_LIB_DEPENDS= libsamplerate.so:audio/libsamplerate |
83 |
SAMPLERATE_LIB_DEPENDS= libsamplerate.so:audio/libsamplerate |
82 |
SDL_CONFIGURE_ENABLE= sdl |
84 |
SAMPLERATE_CONFIGURE_ENABLE= libsamplerate |
83 |
SDL_USES= sdl |
85 |
SAMPLERATE_PREVENTS= RESAMPLE RESAMPLEDLL |
84 |
SDL_USE= SDL=sdl |
86 |
SAMPLERATE_PREVENTS_MSG= SAMPLERATE will prevent RESAMPLE that is\ |
|
|
87 |
implied by RESAMPLEDLL |
88 |
|
85 |
SHARED_CONFIGURE_ENABLE= shared |
89 |
SHARED_CONFIGURE_ENABLE= shared |
86 |
SOUND_CONFIGURE_ENABLE= sound |
90 |
SHARED_PREVENTS= RESAMPLEDLL |
|
|
91 |
SHARED_PREVENTS_MSG= When building shared libraries RESAMPLEDLL\ |
92 |
has no effect. |
93 |
|
94 |
SOUND_CONFIGURE_ENABLE= sound |
95 |
|
96 |
SRTP_LIB_DEPENDS= libsrtp2.so:net/libsrtp2 |
97 |
SRTP_CONFIGURE_ENABLE= libsrtp |
98 |
SRTP_CONFIGURE_ON= --with-external-srtp |
99 |
|
100 |
UPNP_LIB_DEPENDS= libupnp.so:devel/upnp |
101 |
UPNP_CONFIGURE_OFF= --disable-upnp |
102 |
|
103 |
VIDEO_CONFIGURE_ENABLE= video |
104 |
|
105 |
WEBRTC_CONFIGURE_OFF= --disable-libwebrtc |
106 |
|
107 |
YUV_CONFIGURE_ENABLE= libyuv |
108 |
|
109 |
# Codecs |
110 |
AMR_LIB_DEPENDS= libopencore-amrwb.so:audio/opencore-amr \ |
111 |
libvo-amrwbenc.so:audio/vo-amrwbenc |
112 |
AMR_CONFIGURE_WITH= opencore-amr |
113 |
|
114 |
BCG729_CONFIGURE_ENABLE=bcg729 |
115 |
|
116 |
G711_CONFIGURE_ENABLE= g711-codec |
117 |
|
118 |
G7221_CONFIGURE_ENABLE= g7221-codec |
119 |
|
120 |
G722_CONFIGURE_ENABLE= g722-codec |
121 |
|
122 |
GSM_LIB_DEPENDS= libgsm.so:audio/gsm |
123 |
GSM_CONFIGURE_ENABLE= gsm-codec |
124 |
GSM_CONFIGURE_ON= --with-external-gsm |
125 |
|
126 |
ILBC_CONFIGURE_ENABLE= ilbc-codec |
127 |
|
128 |
L16_CONFIGURE_ENABLE= l16-codec |
129 |
|
130 |
OPUS_LIB_DEPENDS= libopus.so:audio/opus |
131 |
OPUS_CONFIGURE_OFF= --disable-opus |
132 |
|
133 |
SILK_CONFIGURE_ENABLE= silk |
134 |
|
135 |
SPEEX_LIB_DEPENDS= libspeex.so:audio/speex \ |
136 |
libspeexdsp.so:audio/speexdsp |
137 |
SPEEX_CONFIGURE_ENABLE= speex-codec |
138 |
SPEEX_CONFIGURE_ON= --with-external-speex |
139 |
|
140 |
# Speex Echo Cancellation & Resampling |
87 |
SPEEXAEC_CONFIGURE_ENABLE= speex-aec |
141 |
SPEEXAEC_CONFIGURE_ENABLE= speex-aec |
88 |
SPEEX_CONFIGURE_ENABLE= speex-codec |
142 |
SPEEXAEC_IMPLIES= SPEEX |
89 |
SPEEX_CONFIGURE_ON= --with-external-speex |
143 |
|
90 |
SPEEX_LIB_DEPENDS= libspeex.so:audio/speex \ |
144 |
SPEEXRESAMPLE_CONFIGURE_ENABLE= speex-resample |
91 |
libspeexdsp.so:audio/speexdsp |
145 |
SPEEXRESAMPLE_IMPLIES= SPEEX |
92 |
V4L_BUILD_DEPENDS= v4l_compat>=0:multimedia/v4l_compat |
146 |
SPEEXRESAMPLE_PREVENTS= RESAMPLE RESAMPLEDLL |
93 |
V4L_CONFIGURE_ENABLE= v4l2 |
147 |
SPEEXRESAMPLE_PREVENTS_MSG= SPEEXRESAMPLE will prevent RESAMPLE that is\ |
94 |
V4L_LIB_DEPENDS= libv4l2.so:multimedia/libv4l |
148 |
implied by RESAMPLEDLL |
95 |
VIDEO_CONFIGURE_ENABLE= video |
|
|
96 |
VPX_CONFIGURE_ENABLE= vpx |
97 |
VPX_LIB_DEPENDS= libvpx.so:multimedia/libvpx |
98 |
WEBRTC_CONFIGURE_OFF= --disable-libwebrtc |
99 |
|
149 |
|
100 |
post-patch: |
150 |
post-patch: |
101 |
@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|' \ |
151 |
@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|' \ |
Lines 103-117
post-patch:
Link Here
|
103 |
@${CP} ${FILESDIR}/config_site.h \ |
153 |
@${CP} ${FILESDIR}/config_site.h \ |
104 |
${WRKSRC}/pjlib/include/pj/config_site.h |
154 |
${WRKSRC}/pjlib/include/pj/config_site.h |
105 |
|
155 |
|
|
|
156 |
pre-build: |
157 |
@${MAKE_CMD} -C ${WRKSRC} dep |
158 |
@${MAKE_CMD} -C ${WRKSRC} clean |
159 |
|
106 |
post-install-SHARED-on: |
160 |
post-install-SHARED-on: |
107 |
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/*.so |
161 |
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/*.so |
108 |
|
162 |
|
109 |
post-install-PJSUA-on: |
163 |
post-install-APPS-on: |
|
|
164 |
${INSTALL_PROGRAM} \ |
165 |
${WRKSRC}/pjsip-apps/bin/pjsua-${ARCH}-portbld-${OPSYS:tl}${OSREL} \ |
166 |
${STAGEDIR}${PREFIX}/bin/pjsua |
110 |
${INSTALL_PROGRAM} \ |
167 |
${INSTALL_PROGRAM} \ |
111 |
${WRKSRC}/pjsip-apps/bin/pjsua-${ARCH}-portbld-${OPSYS:tl}${OSREL} \ |
168 |
${WRKSRC}/pjsip-apps/bin/pjsystest-${ARCH}-portbld-${OPSYS:tl}${OSREL} \ |
112 |
${STAGEDIR}${PREFIX}/bin/pjsua |
169 |
${STAGEDIR}${PREFIX}/bin/pjsystest |
|
|
170 |
${MKDIR} ${STAGEDIR}${PREFIX}/libexec/pjsip-apps/samples |
113 |
${INSTALL_PROGRAM} \ |
171 |
${INSTALL_PROGRAM} \ |
114 |
${WRKSRC}/pjsip-apps/bin/pjsystest-${ARCH}-portbld-${OPSYS:tl}${OSREL} \ |
172 |
${WRKSRC}/pjsip-apps/bin/samples/${ARCH}-portbld-${OPSYS:tl}${OSREL}/* \ |
115 |
${STAGEDIR}${PREFIX}/bin/pjsystest |
173 |
${STAGEDIR}${PREFIX}/libexec/pjsip-apps/samples/ |
|
|
174 |
|
175 |
.include <bsd.port.pre.mk> |
176 |
|
177 |
# resample dso needs to be installed when either the dso is |
178 |
# explicitely requested via RESAMPLEDLL which implies RESAMPLE, |
179 |
# or when RESAMPLE is selected together with SHARED |
180 |
RESAMPLE_DLL_OR_SHARED="@comment " |
181 |
|
182 |
.if ${PORT_OPTIONS:MRESAMPLEDLL} |
183 |
RESAMPLE_DLL_OR_SHARED="" |
184 |
.endif |
185 |
|
186 |
.if ${PORT_OPTIONS:MRESAMPLE} && ${PORT_OPTIONS:MSHARED} |
187 |
RESAMPLE_DLL_OR_SHARED="" |
188 |
.endif |
189 |
|
190 |
PLIST_SUB+= RESAMPLE_DLL_OR_SHARED=${RESAMPLE_DLL_OR_SHARED} |
116 |
|
191 |
|
117 |
.include <bsd.port.mk> |
192 |
.include <bsd.port.post.mk> |