2013-03-21 17:43:46 +00:00
|
|
|
# Created by: Pavel Volkov <pavelivolkov@googlemail.com>
|
2010-08-11 14:39:09 +00:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= sqlite-ext-mobigroup
|
2011-04-20 17:41:58 +00:00
|
|
|
PORTVERSION= 3.7.5.1
|
2014-07-04 09:40:59 +00:00
|
|
|
PORTREVISION= 1
|
2011-04-20 17:41:58 +00:00
|
|
|
PORTEPOCH= 1
|
2010-08-11 14:39:09 +00:00
|
|
|
CATEGORIES= databases
|
2011-04-20 17:41:58 +00:00
|
|
|
MASTER_SITES= http://mobigroup.ru/debian/pool-squeeze/main/s/sqlite3/
|
|
|
|
DISTNAME= sqlite3_${PORTVERSION:R}-mobigroup.${PORTVERSION:E}
|
2010-08-11 14:39:09 +00:00
|
|
|
|
|
|
|
MAINTAINER= pavelivolkov@googlemail.com
|
2014-06-10 07:39:01 +00:00
|
|
|
COMMENT= Mobigroup functions library for SQLite
|
2010-08-11 14:39:09 +00:00
|
|
|
|
|
|
|
USE_SQLITE= yes
|
|
|
|
|
|
|
|
DIST_SUBDIR= sqlite-ext
|
2011-04-20 17:41:58 +00:00
|
|
|
WRKSRC= ${WRKDIR}/sqlite3-${PORTVERSION:R}
|
2010-08-11 14:39:09 +00:00
|
|
|
|
|
|
|
USE_LDCONFIG= ${PREFIX}/libexec/${DIST_SUBDIR}
|
|
|
|
|
2013-03-21 17:43:46 +00:00
|
|
|
OPTIONS_DEFINE= COMPRESS ENV INET MD5 EXAMPLES DOCS
|
|
|
|
COMPRESS_DESC= compress content into a blob using libz
|
|
|
|
ENV_DESC= implements the getenv
|
|
|
|
INET_DESC= provide the ipv4 functions in SQL queries
|
|
|
|
MD5_DESC= implements the MD5 message-digest algorithm
|
2010-08-11 14:39:09 +00:00
|
|
|
|
|
|
|
PLIST_DIRS= libexec/${DIST_SUBDIR}
|
2010-11-05 01:50:48 +00:00
|
|
|
PORTDOCS= *
|
|
|
|
PORTEXAMPLES= *
|
2010-08-11 14:39:09 +00:00
|
|
|
|
2011-04-20 17:41:58 +00:00
|
|
|
.include <bsd.port.options.mk>
|
|
|
|
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MCOMPRESS}
|
2010-11-05 01:50:48 +00:00
|
|
|
PLIST_FILES+= libexec/${DIST_SUBDIR}/libsqlitecompress.so
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MINET}
|
2010-08-11 14:39:09 +00:00
|
|
|
PLIST_FILES+= libexec/${DIST_SUBDIR}/libsqliteipv4.so
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MENV}
|
2010-08-11 14:39:09 +00:00
|
|
|
PLIST_FILES+= libexec/${DIST_SUBDIR}/libsqliteenv.so
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MMD5}
|
2010-08-11 14:39:09 +00:00
|
|
|
PLIST_FILES+= libexec/${DIST_SUBDIR}/libsqlitemd5.so
|
|
|
|
.endif
|
|
|
|
|
|
|
|
CFLAGS+= -I${PREFIX}/include -fPIC -lm -shared
|
|
|
|
|
|
|
|
do-build:
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MCOMPRESS}
|
2011-04-20 17:41:58 +00:00
|
|
|
@cd ${WRKSRC}/ext/_compress && \
|
2010-11-05 01:50:48 +00:00
|
|
|
${CC} -lz ${CFLAGS} compress.c -o libsqlitecompress.so
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MINET}
|
2011-04-20 17:41:58 +00:00
|
|
|
@cd ${WRKSRC}/ext/inet && \
|
2010-08-11 14:39:09 +00:00
|
|
|
${CC} ${CFLAGS} ipv4-ext.c -o libsqliteipv4.so
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MENV}
|
2011-04-20 17:41:58 +00:00
|
|
|
@cd ${WRKSRC}/ext/env && \
|
2010-08-11 14:39:09 +00:00
|
|
|
${CC} ${CFLAGS} env.c -o libsqliteenv.so
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MMD5}
|
2011-04-20 17:41:58 +00:00
|
|
|
@cd ${WRKSRC}/ext/md5 && \
|
2010-08-11 14:39:09 +00:00
|
|
|
${CC} ${CFLAGS} md5.c -o libsqlitemd5.so
|
|
|
|
.endif
|
|
|
|
|
|
|
|
do-install:
|
2014-05-16 03:07:40 +00:00
|
|
|
@${MKDIR} ${STAGEDIR}${PREFIX}/libexec/${DIST_SUBDIR}
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MDOCS}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
2010-11-05 01:50:48 +00:00
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MEXAMPLES}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
|
2010-11-05 01:50:48 +00:00
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MCOMPRESS}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_PROGRAM} ${WRKSRC}/ext/_compress/libsqlitecompress.so ${STAGEDIR}${PREFIX}/libexec/${DIST_SUBDIR}
|
2010-11-05 01:50:48 +00:00
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MINET}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_PROGRAM} ${WRKSRC}/ext/inet/libsqliteipv4.so ${STAGEDIR}${PREFIX}/libexec/${DIST_SUBDIR}
|
2013-03-21 17:43:46 +00:00
|
|
|
. if ${PORT_OPTIONS:MDOCS}
|
2011-04-20 17:41:58 +00:00
|
|
|
@${SED} '/\/\*/d;/\*\//,$$d' ${WRKSRC}/ext/inet/ipv4-ext.c > ${WRKSRC}/ext/inet/README-ipv4.txt
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/ext/inet/README-ipv4.txt ${STAGEDIR}${DOCSDIR}
|
2010-08-11 14:39:09 +00:00
|
|
|
. endif
|
2013-03-21 17:43:46 +00:00
|
|
|
. if ${PORT_OPTIONS:MEXAMPLES}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/ext/inet/ipv4-ext.sql ${STAGEDIR}${EXAMPLESDIR}
|
2010-08-11 14:39:09 +00:00
|
|
|
. endif
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MENV}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_PROGRAM} ${WRKSRC}/ext/env/libsqliteenv.so ${STAGEDIR}${PREFIX}/libexec/${DIST_SUBDIR}
|
2013-03-21 17:43:46 +00:00
|
|
|
. if ${PORT_OPTIONS:MDOCS}
|
2011-04-20 17:41:58 +00:00
|
|
|
@${SED} '/\/\*/d;/\*\//,$$d' ${WRKSRC}/ext/env/env.c > ${WRKSRC}/ext/env/README-env.txt
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/ext/env/README-env.txt ${STAGEDIR}${DOCSDIR}
|
2010-08-11 14:39:09 +00:00
|
|
|
. endif
|
|
|
|
.endif
|
2013-03-21 17:43:46 +00:00
|
|
|
.if ${PORT_OPTIONS:MMD5}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_PROGRAM} ${WRKSRC}/ext/md5/libsqlitemd5.so ${STAGEDIR}${PREFIX}/libexec/${DIST_SUBDIR}
|
2013-03-21 17:43:46 +00:00
|
|
|
. if ${PORT_OPTIONS:MDOCS}
|
2011-04-20 17:41:58 +00:00
|
|
|
@${SED} '/\/\*/d;/\*\//,$$d' ${WRKSRC}/ext/md5/md5.c > ${WRKSRC}/ext/md5/README-md5.txt
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/ext/md5/README-md5.txt ${STAGEDIR}${DOCSDIR}
|
2010-08-11 14:39:09 +00:00
|
|
|
. endif
|
2013-03-21 17:43:46 +00:00
|
|
|
. if ${PORT_OPTIONS:MEXAMPLES}
|
2014-05-16 03:07:40 +00:00
|
|
|
@${INSTALL_DATA} ${WRKSRC}/ext/md5/md5.sql ${STAGEDIR}${EXAMPLESDIR}
|
2010-08-11 14:39:09 +00:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2011-04-20 17:41:58 +00:00
|
|
|
.include <bsd.port.mk>
|