Line 0
Link Here
|
|
|
1 |
# $FreeBSD$ |
2 |
|
3 |
PORTNAME= soxr |
4 |
PORTVERSION= 0.1.2 |
5 |
DISTVERSIONSUFFIX= -Source |
6 |
CATEGORIES= audio |
7 |
MASTER_SITES= SF/${PORTNAME}/ |
8 |
|
9 |
MAINTAINER= |
10 |
COMMENT= High quality, one-dimensional sample-rate conversion library |
11 |
|
12 |
LICENSE= LGPL21 |
13 |
|
14 |
USES= cmake pathfix pkgconfig tar:xz |
15 |
|
16 |
PORTDOCS= NEWS README |
17 |
|
18 |
OPTIONS_SUB= yes |
19 |
OPTIONS_DEFINE= OPENMP SHLIB SIMD LSRLIKE |
20 |
OPTIONS_RADIO= SIMD_DFT |
21 |
OPTIONS_RADIO_SIMD_DFT= _NOUSE AVFFT PFFFT |
22 |
OPTIONS_GROUP= PRECISION |
23 |
OPTIONS_GROUP_PRECISION= PREC_D PREC_S |
24 |
|
25 |
OPTIONS_DEFAULT= OPENMP PFFFT PREC_D PREC_S SHLIB SIMD LSRLIKE |
26 |
|
27 |
LSRLIKE_DESC= Include a libsamplerate-like interface |
28 |
LSRLIKE_CMAKE_ON= -DWITH_LSR_BINDINGS:BOOL=ON |
29 |
LSRLIKE_CMAKE_OFF= -DWITH_LSR_BINDINGS:BOOL=OFF |
30 |
|
31 |
OPENMP_CMAKE_ON= -DWITH_OPENMP:BOOL=ON |
32 |
OPENMP_CMAKE_OFF= -DWITH_OPENMP:BOOL=OFF |
33 |
OPENMP_USE= compiler:openmp |
34 |
|
35 |
SIMD_CMAKE_ON= -DWITH_SIMD:BOOL=ON |
36 |
SIMD_CMAKE_OFF= -DWITH_SIMD:BOOL=OFF |
37 |
|
38 |
SHLIB_DESC= Build shared libraries, otherwise static libraries |
39 |
SHLIB_CMAKE_ON= -DBUILD_SHARED_LIBS:BOOL=ON |
40 |
SHLIB_CMAKE_OFF= -DBUILD_SHARED_LIBS:BOOL=OFF |
41 |
|
42 |
PREC_D_DESC= Build with double precision (for up to 32-bit accuracy) |
43 |
PREC_S_DESC= Build with single precision (for up to 20-bit accuracy) |
44 |
PREC_D_CMAKE_ON= -DWITH_DOUBLE_PRECISION:BOOL=ON |
45 |
PREC_D_CMAKE_OFF= -DWITH_DOUBLE_PRECISION:BOOL=OFF |
46 |
PREC_S_CMAKE_ON= -DWITH_SINGLE_PRECISION:BOOL=ON |
47 |
PREC_S_CMAKE_OFF= -DWITH_SINGLE_PRECISION:BOOL=OFF |
48 |
|
49 |
_NOUSE_DESC= Use neither of below |
50 |
AVFFT_DESC= Use libavcodec (implies SIMD) |
51 |
PFFFT_DESC= Use PFFFT (implies SIMD) |
52 |
AVFFT_IMPLIES= SIMD |
53 |
PFFFT_IMPLIES= SIMD |
54 |
AVFFT_CMAKE_ON= -DWITH_AVFFT:BOOL=ON |
55 |
AVFFT_CMAKE_OFF= -DWITH_AVFFT:BOOL=OFF |
56 |
AVFFT_LIB_DEPENDS= libavcodec.so:${PORTSDIR}/multimedia/ffmpeg |
57 |
PFFFT_CMAKE_ON= -DWITH_PFFFT:BOOL=ON |
58 |
PFFFT_CMAKE_OFF= -DWITH_PFFFT:BOOL=OFF |
59 |
|
60 |
.include <bsd.port.options.mk> |
61 |
|
62 |
.if ${PORT_OPTIONS:MSHLIB} |
63 |
USE_LDCONFIG= yes |
64 |
.endif |
65 |
|
66 |
DOCSDIR= ${PREFIX}/share/doc/lib${PORTNAME} |
67 |
|
68 |
post-patch: |
69 |
@${GREP} -El 'SOURCE_DIR}/LICENCE|AVCODEC_INCLUDE_DIRS' \ |
70 |
${WRKSRC}/CMakeLists.txt | ${XARGS} ${REINPLACE_CMD} \ |
71 |
-e '/$${CMAKE_CURRENT_SOURCE_DIR}\/LICENCE/d' \ |
72 |
-e 's/AVCODEC_INCLUDE_DIRS/AVCODEC_INCLUDES/' |
73 |
|
74 |
.include <bsd.port.mk> |