Bug 197707 - [new port] devel/libosmo-netif
Summary: [new port] devel/libosmo-netif
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Jan Beich
URL:
Keywords:
Depends on:
Blocks: 197784
  Show dependency treegraph
 
Reported: 2015-02-16 15:35 UTC by Nikola Kolev
Modified: 2015-02-24 07:52 UTC (History)
1 user (show)

See Also:


Attachments
libosmo-netif (7.73 KB, text/plain)
2015-02-16 15:35 UTC, Nikola Kolev
no flags Details
simplify (5.91 KB, patch)
2015-02-22 14:20 UTC, Jan Beich
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nikola Kolev 2015-02-16 15:35:15 UTC
Created attachment 153038 [details]
libosmo-netif

Libosmo-netif is library containing common/shared code regarding network interfaces. It's part of Osmocom project regarding open source mobile communications.

% portlint 
looks fine.

% make check-plist
====> Checking for pkg-plist issues (check-plist)
===> Parsing plist
===> Checking for items in STAGEDIR missing from pkg-plist
===> Checking for items in pkg-plist which are not in STAGEDIR
===> No pkg-plist issues found (check-plist)

% make stage-qa
====> Running Q/A tests (stage-qa)


http://chaosophia.net/poudriere/libosmo-netif-0.0.4-101x386.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-101x64.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-10x64.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-10x386.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-84x64.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-84x386.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-93x64.log
http://chaosophia.net/poudriere/libosmo-netif-0.0.4-93x386.log
Comment 1 Jan Beich freebsd_committer freebsd_triage 2015-02-22 13:50:26 UTC
Comment on attachment 153038 [details]
libosmo-netif

>XUSES=		libtool pkgconfig
>X
>XUSE_AUTOTOOLS=	aclocal autoconf automake libtoolize autoheader
>XAUTOMAKE_ARGS=	--gnu --add-missing --copy

Can be replaced with

  USES=		autoreconf

>Xpost-patch:
>X	${REINPLACE_CMD} -e 's|pkgconfigdir.*|pkgconfigdir = ${PREFIX}/libdata/pkgconfig|g' \
>X		${WRKSRC}/Makefile.am

Can be replaced with

  USES=		pathfix
  PATHFIX_MAKEFILEIN=	Makefile.am  

>Xpost-stage:
>X	${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libosmonetif.so.2.0.0

Can be replaced with

  INSTALL_TARGET=	install-strip

>sed 's/^X//' >libosmo-netif/pkg-descr << '79ad83226ca6216d3244c7c44ff54313'
>XLibrary containing common/shared code regarding network interface.
>XDevelopment headers for Osmocom network interface.
>XDebug symbols for Osmocom network interface.

Why not put comment 0 description instead of debian/control shorts? We
don't split packages into devel/debug.

>X+++ configure.ac	2015-02-16 17:04:01.000000000 +0200
>X@@ -32,7 +32,7 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([char 
>X CFLAGS="$saved_CFLAGS"
>X AC_SUBST(SYMBOL_VISIBILITY)
>X 
>X-AC_CHECK_HEADER([endian.h], [], [AC_MSG_ERROR([endian.h not found!]) ])
>X+AC_CHECK_HEADER([sys/endian.h], [], [AC_MSG_ERROR([endian.h not found!]) ])

Use plural form and drop AC_MSG_ERROR e.g.,

  AC_CHECK_HEADERS(endian.h sys/endian.h)

>X--- src/rtp.c.orig	2014-09-08 08:52:08.000000000 +0300
>X+++ src/rtp.c	2015-02-16 11:54:11.000000000 +0200
>X@@ -1,6 +1,10 @@
>X #include <stdint.h>
>X #include <sys/time.h>
>X+#ifdef __FreeBSD__

Better use defines from autoheader e.g.,

  #ifdef HAVE_CONFIG_H
  #include "config.h"
  #endif
  #ifdef HAVE_SYS_ENDIAN_H

>X+#include <sys/endian.h>
>X+#else
>X #include <endian.h>
>X+#endif

>X+++ examples/ipa-stream-server.c	2015-02-16 17:05:21.000000000 +0200
>X@@ -4,6 +4,10 @@
>X #include <string.h>
>X #include <unistd.h>
>X #include <arpa/inet.h>
>X+#ifdef __FreeBSD__

No need to guard POSIX headers. It'd also help other BSDs like DragonFly.

>X+#include <sys/types.h>
>X+#include <netinet/in.h>
>X+#endif
>X #include <netinet/tcp.h>

>echo x - libosmo-netif/pkg-plist
>sed 's/^X//' >libosmo-netif/pkg-plist << '589ab34feab31363be59acbd04f9baf2'
>Xlib/libosmonetif.so
>Xlib/libosmonetif.so.2
>Xlib/libosmonetif.so.2.0.0

Didn't portlint(1) warn you about USE_LDCONFIG ?
Comment 2 Jan Beich freebsd_committer freebsd_triage 2015-02-22 14:20:05 UTC
Created attachment 153314 [details]
simplify

Here's what I have in mind in case that review was incomprehensible. Some changes can probably be applied to other devel/libosmo* ports.
Comment 3 Nikola Kolev 2015-02-23 09:23:18 UTC
I'm agree with the changes.
Comment 4 commit-hook freebsd_committer freebsd_triage 2015-02-24 07:38:06 UTC
A commit references this bug:

Author: jbeich
Date: Tue Feb 24 07:37:55 UTC 2015
New revision: 379761
URL: https://svnweb.freebsd.org/changeset/ports/379761

Log:
  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/

Changes:
  head/devel/libosmo-netif/
  head/devel/libosmo-netif/Makefile
  head/devel/libosmo-netif/distinfo
  head/devel/libosmo-netif/files/
  head/devel/libosmo-netif/files/patch-abis-ipa-stream-client.c
  head/devel/libosmo-netif/files/patch-abis-ipa-stream-server.c
  head/devel/libosmo-netif/files/patch-datagram.c
  head/devel/libosmo-netif/files/patch-ipa-stream-client.c
  head/devel/libosmo-netif/files/patch-ipa-stream-server.c
  head/devel/libosmo-netif/files/patch-osmocom_netif_amr.h
  head/devel/libosmo-netif/files/patch-osmocom_netif_osmux.h
  head/devel/libosmo-netif/files/patch-osmocom_netif_rtp.h
  head/devel/libosmo-netif/files/patch-rs232-write.c
  head/devel/libosmo-netif/files/patch-rs232.c
  head/devel/libosmo-netif/files/patch-stream.c
  head/devel/libosmo-netif/pkg-descr
  head/devel/libosmo-netif/pkg-plist
Comment 5 Jan Beich freebsd_committer freebsd_triage 2015-02-24 07:52:55 UTC
Thanks. Committed.