summaryrefslogtreecommitdiff
path: root/devel/libosmo-netif
diff options
context:
space:
mode:
authorJan Beich <jbeich@FreeBSD.org>2015-02-24 07:37:50 +0000
committerJan Beich <jbeich@FreeBSD.org>2015-02-24 07:37:50 +0000
commit9b82d28acc48fed4d61826040a957a282f4530b7 (patch)
treec498fd0a7ff0173e42b36bdc7adea7fe0e7d113a /devel/libosmo-netif
parentstrip binary. (diff)
Add new port: devel/libosmo-netif
PR: 197707 Submitted by: Nikola Kolev <koue@chaosophia.net> Libosmo-netif is library containing common/shared code regarding network interfaces. It's part of Osmocom project regarding open source mobile communications. WWW: http://git.osmocom.org/libosmo-netif/
Diffstat (limited to 'devel/libosmo-netif')
-rw-r--r--devel/libosmo-netif/Makefile37
-rw-r--r--devel/libosmo-netif/distinfo2
-rw-r--r--devel/libosmo-netif/files/patch-abis-ipa-stream-client.c8
-rw-r--r--devel/libosmo-netif/files/patch-abis-ipa-stream-server.c8
-rw-r--r--devel/libosmo-netif/files/patch-datagram.c11
-rw-r--r--devel/libosmo-netif/files/patch-ipa-stream-client.c11
-rw-r--r--devel/libosmo-netif/files/patch-ipa-stream-server.c11
-rw-r--r--devel/libosmo-netif/files/patch-osmocom_netif_amr.h11
-rw-r--r--devel/libosmo-netif/files/patch-osmocom_netif_osmux.h11
-rw-r--r--devel/libosmo-netif/files/patch-osmocom_netif_rtp.h11
-rw-r--r--devel/libosmo-netif/files/patch-rs232-write.c10
-rw-r--r--devel/libosmo-netif/files/patch-rs232.c11
-rw-r--r--devel/libosmo-netif/files/patch-stream.c11
-rw-r--r--devel/libosmo-netif/pkg-descr3
-rw-r--r--devel/libosmo-netif/pkg-plist16
15 files changed, 172 insertions, 0 deletions
diff --git a/devel/libosmo-netif/Makefile b/devel/libosmo-netif/Makefile
new file mode 100644
index 000000000000..a7a770b610a9
--- /dev/null
+++ b/devel/libosmo-netif/Makefile
@@ -0,0 +1,37 @@
+# $FreeBSD$
+
+PORTNAME= libosmo-netif
+PORTVERSION= 0.0.4
+CATEGORIES= devel
+MASTER_SITES= http://git.osmocom.org/libosmo-netif/snapshot/ \
+ http://chaosophia.net/downloads/osmocom/${PORTNAME}/
+
+MAINTAINER= koue@chaosophia.net
+COMMENT= Library containing common/shared code regarding network interface
+
+LICENSE= GPLv2
+LICENSE_FILE= ${WRKSRC}/COPYING
+
+LIB_DEPENDS= libosmocore.so:${PORTSDIR}/devel/libosmocore \
+ libosmoabis.so:${PORTSDIR}/devel/libosmo-abis
+
+USES= autoreconf libtool pathfix pkgconfig
+PATHFIX_MAKEFILEIN=Makefile.am
+GNU_CONFIGURE= yes
+INSTALL_TARGET= install-strip
+USE_LDCONFIG= yes
+
+post-patch:
+ ${REINPLACE_CMD} -e 's,endian\.h,sys/endian.h,' \
+ -e 's,__BYTE_ORDER,BYTE_ORDER,' \
+ -e 's,__LITTLE_ENDIAN,LITTLE_ENDIAN,' \
+ -e 's,__BIG_ENDIAN,BIG_ENDIAN,' \
+ ${WRKSRC}/configure.ac \
+ ${WRKSRC}/examples/rs232-write.c \
+ ${WRKSRC}/include/osmocom/netif/amr.h \
+ ${WRKSRC}/include/osmocom/netif/rtp.h \
+ ${WRKSRC}/include/osmocom/netif/osmux.h \
+ ${WRKSRC}/src/rtp.c
+ ${ECHO_CMD} ${PORTVERSION} > ${WRKSRC}/.tarball-version
+
+.include <bsd.port.mk>
diff --git a/devel/libosmo-netif/distinfo b/devel/libosmo-netif/distinfo
new file mode 100644
index 000000000000..9f2a4cda012d
--- /dev/null
+++ b/devel/libosmo-netif/distinfo
@@ -0,0 +1,2 @@
+SHA256 (libosmo-netif-0.0.4.tar.gz) = 58549da17af181ebef6fa9b74e80592657d9595d061a8dd1fbb24966968b1b24
+SIZE (libosmo-netif-0.0.4.tar.gz) = 150052
diff --git a/devel/libosmo-netif/files/patch-abis-ipa-stream-client.c b/devel/libosmo-netif/files/patch-abis-ipa-stream-client.c
new file mode 100644
index 000000000000..b0b3009489f9
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-abis-ipa-stream-client.c
@@ -0,0 +1,8 @@
+--- src/channel/abis/ipa_stream_client.c.orig 2015-02-16 17:12:17.000000000 +0200
++++ src/channel/abis/ipa_stream_client.c 2015-02-16 17:09:59.000000000 +0200
+@@ -1,4 +1,5 @@
+ #include <stdlib.h>
++#include <sys/types.h>
+ #include <netinet/in.h>
+ #include <netinet/tcp.h>
+ #include <sys/socket.h>
diff --git a/devel/libosmo-netif/files/patch-abis-ipa-stream-server.c b/devel/libosmo-netif/files/patch-abis-ipa-stream-server.c
new file mode 100644
index 000000000000..fd1d0b906553
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-abis-ipa-stream-server.c
@@ -0,0 +1,8 @@
+--- src/channel/abis/ipa_stream_server.c.orig 2015-02-16 17:09:48.000000000 +0200
++++ src/channel/abis/ipa_stream_server.c 2015-02-16 17:08:09.000000000 +0200
+@@ -1,4 +1,5 @@
+ #include <stdlib.h>
++#include <sys/types.h>
+ #include <netinet/in.h>
+ #include <netinet/tcp.h>
+ #include <sys/socket.h>
diff --git a/devel/libosmo-netif/files/patch-datagram.c b/devel/libosmo-netif/files/patch-datagram.c
new file mode 100644
index 000000000000..1988c165a9d6
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-datagram.c
@@ -0,0 +1,11 @@
+--- src/datagram.c.orig 2015-02-16 11:44:42.000000000 +0200
++++ src/datagram.c 2015-02-16 11:44:12.000000000 +0200
+@@ -19,6 +19,8 @@
+
+ #include <osmocom/netif/datagram.h>
+
++#include <netinet/in.h>
++
+ /*
+ * Client side.
+ */
diff --git a/devel/libosmo-netif/files/patch-ipa-stream-client.c b/devel/libosmo-netif/files/patch-ipa-stream-client.c
new file mode 100644
index 000000000000..d3cc8d23e555
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-ipa-stream-client.c
@@ -0,0 +1,11 @@
+--- examples/ipa-stream-client.c.orig 2014-09-08 08:52:08.000000000 +0300
++++ examples/ipa-stream-client.c 2015-02-16 17:06:50.000000000 +0200
+@@ -6,6 +6,8 @@
+ #include <signal.h>
+ #include <sys/time.h>
+ #include <arpa/inet.h>
++#include <sys/types.h>
++#include <netinet/in.h>
+ #include <netinet/tcp.h>
+
+ #include <osmocom/core/select.h>
diff --git a/devel/libosmo-netif/files/patch-ipa-stream-server.c b/devel/libosmo-netif/files/patch-ipa-stream-server.c
new file mode 100644
index 000000000000..b763b94e0b4e
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-ipa-stream-server.c
@@ -0,0 +1,11 @@
+--- examples/ipa-stream-server.c.orig 2014-09-08 08:52:08.000000000 +0300
++++ examples/ipa-stream-server.c 2015-02-16 17:05:21.000000000 +0200
+@@ -4,6 +4,8 @@
+ #include <string.h>
+ #include <unistd.h>
+ #include <arpa/inet.h>
++#include <sys/types.h>
++#include <netinet/in.h>
+ #include <netinet/tcp.h>
+
+ #include <osmocom/core/select.h>
diff --git a/devel/libosmo-netif/files/patch-osmocom_netif_amr.h b/devel/libosmo-netif/files/patch-osmocom_netif_amr.h
new file mode 100644
index 000000000000..3170dd176e6d
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-osmocom_netif_amr.h
@@ -0,0 +1,11 @@
+--- include/osmocom/netif/amr.h.orig 2015-02-23 11:51:17 UTC
++++ include/osmocom/netif/amr.h
+@@ -1,6 +1,8 @@
+ #ifndef _OSMO_AMR_H_
+ #define _OSMO_AMR_H_
+
++#include <endian.h>
++
+ /* As defined by RFC3267: Adaptive Multi-Rate (AMR) */
+
+ /*
diff --git a/devel/libosmo-netif/files/patch-osmocom_netif_osmux.h b/devel/libosmo-netif/files/patch-osmocom_netif_osmux.h
new file mode 100644
index 000000000000..ad99948e831b
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-osmocom_netif_osmux.h
@@ -0,0 +1,11 @@
+--- include/osmocom/netif/osmux.h.orig 2015-02-23 11:51:17 UTC
++++ include/osmocom/netif/osmux.h
+@@ -1,6 +1,8 @@
+ #ifndef _OSMUX_H_
+ #define _OSMUX_H_
+
++#include <endian.h>
++
+ /* OSmux header:
+ *
+ * ft (3 bits): 0=signalling, 1=voice
diff --git a/devel/libosmo-netif/files/patch-osmocom_netif_rtp.h b/devel/libosmo-netif/files/patch-osmocom_netif_rtp.h
new file mode 100644
index 000000000000..33cddd5a79ae
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-osmocom_netif_rtp.h
@@ -0,0 +1,11 @@
+--- include/osmocom/netif/rtp.h.orig 2015-02-23 11:51:17 UTC
++++ include/osmocom/netif/rtp.h
+@@ -1,6 +1,8 @@
+ #ifndef _OSMO_RTP_H_
+ #define _OSMO_RTP_H_
+
++#include <endian.h>
++
+ /* RTP header as defined by RFC 3550 */
+ struct rtp_hdr {
+ #if BYTE_ORDER == LITTLE_ENDIAN
diff --git a/devel/libosmo-netif/files/patch-rs232-write.c b/devel/libosmo-netif/files/patch-rs232-write.c
new file mode 100644
index 000000000000..79b4ab8a7400
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-rs232-write.c
@@ -0,0 +1,10 @@
+--- examples/rs232-write.c.orig 2015-02-23 11:51:17 UTC
++++ examples/rs232-write.c
+@@ -3,6 +3,7 @@
+ #include <string.h>
+ #include <arpa/inet.h>
+ #include <unistd.h>
++#include <endian.h>
+
+ #include <osmocom/core/select.h>
+ #include <osmocom/core/talloc.h>
diff --git a/devel/libosmo-netif/files/patch-rs232.c b/devel/libosmo-netif/files/patch-rs232.c
new file mode 100644
index 000000000000..7433e2d1402c
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-rs232.c
@@ -0,0 +1,11 @@
+--- src/rs232.c.orig 2015-02-16 11:50:26.000000000 +0200
++++ src/rs232.c 2015-02-16 11:50:41.000000000 +0200
+@@ -167,7 +167,7 @@ static struct baudrate2termbits {
+ { 9600, B9600 },
+ { 19200, B19200 },
+ { 38400, B38400 },
+- { 115200, B1152000 },
++ { 115200, B115200 },
+ { -1, -1 },
+ };
+
diff --git a/devel/libosmo-netif/files/patch-stream.c b/devel/libosmo-netif/files/patch-stream.c
new file mode 100644
index 000000000000..b8dca9e3885b
--- /dev/null
+++ b/devel/libosmo-netif/files/patch-stream.c
@@ -0,0 +1,11 @@
+--- src/stream.c.orig 2015-02-16 11:47:30.000000000 +0200
++++ src/stream.c 2015-02-16 11:48:03.000000000 +0200
+@@ -19,6 +19,8 @@
+
+ #include <osmocom/netif/stream.h>
+
++#include <netinet/in.h>
++
+ /*
+ * Client side.
+ */
diff --git a/devel/libosmo-netif/pkg-descr b/devel/libosmo-netif/pkg-descr
new file mode 100644
index 000000000000..310561cad2b9
--- /dev/null
+++ b/devel/libosmo-netif/pkg-descr
@@ -0,0 +1,3 @@
+Library containing common/shared code regarding network interface.
+
+WWW: http://git.osmocom.org/libosmo-netif/
diff --git a/devel/libosmo-netif/pkg-plist b/devel/libosmo-netif/pkg-plist
new file mode 100644
index 000000000000..58347a4f9251
--- /dev/null
+++ b/devel/libosmo-netif/pkg-plist
@@ -0,0 +1,16 @@
+include/osmocom/netif/amr.h
+include/osmocom/netif/channel.h
+include/osmocom/netif/channel/abis_ipa_client.h
+include/osmocom/netif/channel/abis_ipa_server.h
+include/osmocom/netif/datagram.h
+include/osmocom/netif/ipa.h
+include/osmocom/netif/ipa_unit.h
+include/osmocom/netif/osmux.h
+include/osmocom/netif/rs232.h
+include/osmocom/netif/rtp.h
+include/osmocom/netif/stream.h
+lib/libosmonetif.a
+lib/libosmonetif.so
+lib/libosmonetif.so.2
+lib/libosmonetif.so.2.0.0
+libdata/pkgconfig/libosmo-netif.pc