blob: e8146b8dcb1efd6624bacfb6eeaf7872ff886a3b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
# Created by: Martin Matuska <mm@FreeBSD.org>
# $FreeBSD$
PORTNAME= mysql-udf
PORTVERSION= 0.3
PORTREVISION= 2
CATEGORIES= databases
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
MAINTAINER= ports@FreeBSD.org
COMMENT= Set of user-defined functions for the MySQL server
WRKSRC= ${WRKDIR}/${PORTNAME}
USE_MYSQL= yes
MODULES= colwidth confidence_higher confidence_lower correlation \
faculty geomean intercept kurtosis longest median noverm \
skewness slope stdnorm_density stdnorm_dist weightedavg
.for MODULE in ${MODULES}
PLIST_FILES+= lib/mysql/plugin/udf_${MODULE}.so
.endfor
.include <bsd.port.pre.mk>
.if ${ARCH} == amd64
CFLAGS+= -fPIC
.endif
do-build:
.for MODULE in ${MODULES}
cd ${WRKSRC} && \
${CC} ${CFLAGS} -I${LOCALBASE}/include/mysql -c -o udf_${MODULE}.o udf_${MODULE}.cc && \
${CC} -shared -o udf_${MODULE}.so udf_${MODULE}.o
.endfor
do-install:
${MKDIR} ${STAGEDIR}${PREFIX}/lib/mysql/plugin
.for MODULE in ${MODULES}
${INSTALL_PROGRAM} ${WRKSRC}/udf_${MODULE}.so ${STAGEDIR}${PREFIX}/lib/mysql/plugin/udf_${MODULE}.so
.endfor
.include <bsd.port.post.mk>
|