svn commit: r365034 - in head/net/libbgpdump: . files
Kurt Jaeger
pi at FreeBSD.org
Fri Aug 15 20:24:08 UTC 2014
Author: pi
Date: Fri Aug 15 20:24:06 2014
New Revision: 365034
URL: http://svnweb.freebsd.org/changeset/ports/365034
QAT: https://qat.redports.org/buildarchive/r365034/
Log:
net/libbgpdump: fix build with clang
PR: 191428
Submitted by: mjl at luckie.org.nz (maintainer)
Added:
head/net/libbgpdump/files/patch-util.c (contents, props changed)
Modified:
head/net/libbgpdump/Makefile
Modified: head/net/libbgpdump/Makefile
==============================================================================
--- head/net/libbgpdump/Makefile Fri Aug 15 20:05:45 2014 (r365033)
+++ head/net/libbgpdump/Makefile Fri Aug 15 20:24:06 2014 (r365034)
@@ -1,9 +1,8 @@
-# Created by: ijliao
# $FreeBSD$
PORTNAME= libbgpdump
PORTVERSION= 1.4.99.13
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= net
MASTER_SITES= http://www.ris.ripe.net/source/bgpdump/
EXTRACT_SUFX= .tgz
@@ -15,7 +14,6 @@ LICENSE= GPLv2
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
-USE_GCC= any
OPTIONS_DEFINE= DOCS EXAMPLES
Added: head/net/libbgpdump/files/patch-util.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/net/libbgpdump/files/patch-util.c Fri Aug 15 20:24:06 2014 (r365034)
@@ -0,0 +1,29 @@
+--- util.c.orig 2014-08-15 12:58:56.000000000 -0700
++++ util.c 2014-08-15 13:01:14.000000000 -0700
+@@ -29,6 +29,7 @@
+ #include <syslog.h>
+ #include <time.h>
+ #include <string.h>
++#include <inttypes.h>
+
+ static bool use_syslog = true;
+
+@@ -110,17 +111,7 @@
+
+ int int2str(uint32_t value, char* str)
+ {
+- const int LEN = 11;
+- char b[LEN];
+- int i = LEN;
+- b[i--] = '\0';
+-
+- do {
+- b[i--] = (char)(48 + (value % 10));
+- } while (value /= 10);
+-
+- memcpy(str, b + i + 1, LEN - i);
+- return LEN - i - 1;
++ return snprintf(str, 11, "%"PRIu32, value);
+ }
+
+ static void ti2s(uint32_t value) {
More information about the svn-ports-head
mailing list