aboutsummaryrefslogtreecommitdiffstats
path: root/databases/sqlite-ext-inet
diff options
context:
space:
mode:
authormiwi <miwi@FreeBSD.org>2009-09-13 20:25:29 +0800
committermiwi <miwi@FreeBSD.org>2009-09-13 20:25:29 +0800
commitd7de3e032fff19d74c366fe3368942c283ded862 (patch)
tree0b720a9b16b62c8951fd1c5cf7f6cc64b6197357 /databases/sqlite-ext-inet
parentab34ecc5f7d784b54d45ec95453d79e402deaf69 (diff)
downloadfreebsd-ports-gnome-d7de3e032fff19d74c366fe3368942c283ded862.tar.gz
freebsd-ports-gnome-d7de3e032fff19d74c366fe3368942c283ded862.tar.zst
freebsd-ports-gnome-d7de3e032fff19d74c366fe3368942c283ded862.zip
This library will provide the ipv4 ISINNET, IP2INT, INT2IP,
NETFROM, NETLENGTH, NETMASKLENGTH functions in SQL queries. WWW: http://mobigroup.ru/files/sqlite-ext/inet/ PR: ports/137295 Submitted by: Pavel Volkov <pol at iib.ru>
Diffstat (limited to 'databases/sqlite-ext-inet')
-rw-r--r--databases/sqlite-ext-inet/Makefile49
-rw-r--r--databases/sqlite-ext-inet/distinfo6
-rw-r--r--databases/sqlite-ext-inet/files/patch-ipv4-ext.c10
-rw-r--r--databases/sqlite-ext-inet/pkg-descr4
4 files changed, 69 insertions, 0 deletions
diff --git a/databases/sqlite-ext-inet/Makefile b/databases/sqlite-ext-inet/Makefile
new file mode 100644
index 000000000000..8dd851522177
--- /dev/null
+++ b/databases/sqlite-ext-inet/Makefile
@@ -0,0 +1,49 @@
+# New ports collection makefile for: sqlite-ext/inet
+# Date created: 30 Jul 2009
+# Whom: Pavel Volkov <pol@iib.ru>
+#
+# $FreeBSD$
+#
+
+PORTNAME= sqlite-ext-inet
+PORTVERSION= 1.0
+CATEGORIES= databases
+MASTER_SITES= http://mobigroup.ru/files/sqlite-ext/inet/
+DISTFILES= ipv4-ext.c ipv4-ext.sql
+
+MAINTAINER= pol@iib.ru
+COMMENT= Library will provide the ipv4 functions in SQL queries
+
+USE_SQLITE= yes
+
+DIST_SUBDIR= sqlite-ext
+NO_WRKSUBDIR= yes
+
+EXTRACT_CMD= ${CP}
+EXTRACT_BEFORE_ARGS=
+EXTRACT_AFTER_ARGS= ${WRKSRC}/
+
+PLIST_FILES= libexec/${DIST_SUBDIR}/libsqliteipv4.so
+PLIST_DIRS= libexec/${DIST_SUBDIR}
+.if !defined(NOPORTDOCS)
+PLIST_FILES+= %%DATADIR%%/ipv4-ext.sql %%DATADIR%%/README.txt
+PLIST_DIRS+= %%DATADIR%%
+.endif
+
+CFLAGS+= -I${PREFIX}/include -fPIC -lm -shared
+
+do-build:
+ cd ${WRKSRC} && \
+ ${CC} ${CFLAGS} ipv4-ext.c -o libsqliteipv4.so
+
+do-install:
+ ${MKDIR} ${PREFIX}/libexec/${DIST_SUBDIR}
+ ${INSTALL_PROGRAM} ${WRKSRC}/libsqliteipv4.so ${PREFIX}/libexec/${DIST_SUBDIR}
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${DATADIR}
+ ${INSTALL_DATA} ${WRKSRC}/ipv4-ext.sql ${DATADIR}
+ ${SED} '/\/\*/d;/\*\//,$$d' ${WRKSRC}/ipv4-ext.c > ${WRKSRC}/README.txt
+ ${INSTALL_DATA} ${WRKSRC}/README.txt ${DATADIR}
+.endif
+
+.include <bsd.port.mk>
diff --git a/databases/sqlite-ext-inet/distinfo b/databases/sqlite-ext-inet/distinfo
new file mode 100644
index 000000000000..378ec9253ce5
--- /dev/null
+++ b/databases/sqlite-ext-inet/distinfo
@@ -0,0 +1,6 @@
+MD5 (sqlite-ext/ipv4-ext.c) = 8165d1320aca2a4b1148984c4b0a1959
+SHA256 (sqlite-ext/ipv4-ext.c) = 024246ca03973cd18700b6c76da59a2f5d8990673e1e998d606aa14725a22229
+SIZE (sqlite-ext/ipv4-ext.c) = 19685
+MD5 (sqlite-ext/ipv4-ext.sql) = fe983bab4600684817e634b82225bb06
+SHA256 (sqlite-ext/ipv4-ext.sql) = e13b3ef729841b7981ae1cf50d0ca24d2244f9c428b2b41efb061f4f519b0413
+SIZE (sqlite-ext/ipv4-ext.sql) = 13449
diff --git a/databases/sqlite-ext-inet/files/patch-ipv4-ext.c b/databases/sqlite-ext-inet/files/patch-ipv4-ext.c
new file mode 100644
index 000000000000..632fbea3cfce
--- /dev/null
+++ b/databases/sqlite-ext-inet/files/patch-ipv4-ext.c
@@ -0,0 +1,10 @@
+--- ipv4-ext.c.orig 2009-07-30 17:21:45.000000000 +0400
++++ ipv4-ext.c 2009-07-30 17:22:19.000000000 +0400
+@@ -355,6 +355,7 @@
+
+ #include <stdlib.h>
+ #include <sys/types.h>
++#include <sys/socket.h>
+ #include <string.h>
+ #include <arpa/inet.h>
+ #include <stdio.h>
diff --git a/databases/sqlite-ext-inet/pkg-descr b/databases/sqlite-ext-inet/pkg-descr
new file mode 100644
index 000000000000..b1dc8b66a04a
--- /dev/null
+++ b/databases/sqlite-ext-inet/pkg-descr
@@ -0,0 +1,4 @@
+This library will provide the ipv4 ISINNET, IP2INT, INT2IP,
+NETFROM, NETLENGTH, NETMASKLENGTH functions in SQL queries.
+
+WWW: http://mobigroup.ru/files/sqlite-ext/inet/