svn commit: r457359 - in head/sysutils/pflogx: . files

Alexey Dokuchaev danfe at FreeBSD.org
Wed Dec 27 10:40:00 UTC 2017


Author: danfe
Date: Wed Dec 27 10:39:58 2017
New Revision: 457359
URL: https://svnweb.freebsd.org/changeset/ports/457359

Log:
  Unbreak the build on sparc64: it was caused by #include <net/pfvar.h> that
  was conflicting with C++ headers, leading to the following errors:
  
    In file included from /usr/include/c++/4.2/iostream:45,
                     from ../include/XmlFileWriter.h:36,
                     from pflogx.cpp:36:
    /usr/include/c++/4.2/ostream:566:47: error: macro "flush" passed 2
    arguments, but takes just 1
  
  This header was required before PF_* enums were moved to <netpfil/pf/pf.h>,
  which applies to all supported versions of FreeBSD.  Thus, do not #include
  offending and nowadays useless header file, only #include <netpfil/pf/pf.h>
  (which is #included by <net/pfvar.h>) when its definitions are needed.
  
  Tested on:	i386, amd64, powerpc, sparc64

Added:
  head/sysutils/pflogx/files/patch-include_LogEntry.h   (contents, props changed)
  head/sysutils/pflogx/files/patch-include_LogParser.h   (contents, props changed)
  head/sysutils/pflogx/files/patch-include_Options.h
     - copied unchanged from r457358, head/sysutils/pflogx/files/patch-include__Options.h
  head/sysutils/pflogx/files/patch-src_CmdLineParser.cpp   (contents, props changed)
  head/sysutils/pflogx/files/patch-src_LogEntryFormat.cpp   (contents, props changed)
  head/sysutils/pflogx/files/patch-src_LogEntryParser.cpp   (contents, props changed)
Deleted:
  head/sysutils/pflogx/files/patch-include__Options.h
Modified:
  head/sysutils/pflogx/Makefile

Modified: head/sysutils/pflogx/Makefile
==============================================================================
--- head/sysutils/pflogx/Makefile	Wed Dec 27 09:30:47 2017	(r457358)
+++ head/sysutils/pflogx/Makefile	Wed Dec 27 10:39:58 2017	(r457359)
@@ -13,8 +13,6 @@ COMMENT=	Simple tool to export pf (packet filter) logs
 LICENSE=	BSD2CLAUSE
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
-BROKEN_sparc64=	cannot compile: error in C++ code
-
 WRKSRC=		${WRKDIR}/${PORTNAME}
 
 OPTIONS_DEFINE=	EXPAT DOCS EXAMPLES

Added: head/sysutils/pflogx/files/patch-include_LogEntry.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/pflogx/files/patch-include_LogEntry.h	Wed Dec 27 10:39:58 2017	(r457359)
@@ -0,0 +1,10 @@
+--- include/LogEntry.h.orig	2006-04-16 13:43:43 UTC
++++ include/LogEntry.h
+@@ -36,7 +36,6 @@
+ #include <sys/time.h>
+ #include <net/if.h>
+ #include <netinet/in.h>
+-#include <net/pfvar.h>
+ #include <string>
+ 
+ using namespace std;

Added: head/sysutils/pflogx/files/patch-include_LogParser.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/pflogx/files/patch-include_LogParser.h	Wed Dec 27 10:39:58 2017	(r457359)
@@ -0,0 +1,10 @@
+--- include/LogParser.h.orig	2006-04-16 13:45:17 UTC
++++ include/LogParser.h
+@@ -35,7 +35,6 @@
+ #include <sys/socket.h>
+ #include <net/if.h>
+ #include <netinet/in.h>
+-#include <net/pfvar.h>
+ #include <net/if_pflog.h>
+ #include <netinet/in_systm.h>
+ #include <netinet/ip.h>

Copied: head/sysutils/pflogx/files/patch-include_Options.h (from r457358, head/sysutils/pflogx/files/patch-include__Options.h)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/pflogx/files/patch-include_Options.h	Wed Dec 27 10:39:58 2017	(r457359, copy of r457358, head/sysutils/pflogx/files/patch-include__Options.h)
@@ -0,0 +1,10 @@
+--- include/Options.h.orig	2006-04-25 19:13:29 UTC
++++ include/Options.h
+@@ -33,6 +33,7 @@
+ 
+ #include <string>
+ #include <vector>
++#include <sys/types.h>
+ 
+ using namespace std;
+ 

Added: head/sysutils/pflogx/files/patch-src_CmdLineParser.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/pflogx/files/patch-src_CmdLineParser.cpp	Wed Dec 27 10:39:58 2017	(r457359)
@@ -0,0 +1,10 @@
+--- src/CmdLineParser.cpp.orig	2006-05-08 10:21:40 UTC
++++ src/CmdLineParser.cpp
+@@ -31,6 +31,7 @@
+ #include "CmdLineParser.h"
+ #include "LogEntry.h"
+ #include "StrTools.h"
++#include <netpfil/pf/pf.h>
+ #include <unistd.h>
+ #include <vector>
+ 

Added: head/sysutils/pflogx/files/patch-src_LogEntryFormat.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/pflogx/files/patch-src_LogEntryFormat.cpp	Wed Dec 27 10:39:58 2017	(r457359)
@@ -0,0 +1,10 @@
+--- src/LogEntryFormat.cpp.orig	2006-05-08 10:23:07 UTC
++++ src/LogEntryFormat.cpp
+@@ -34,6 +34,7 @@
+ #include <time.h>
+ #include <netinet/in.h>
+ #include <arpa/inet.h>
++#include <netpfil/pf/pf.h>
+ 
+ 
+ #define STATIC_BUFFER_LEN	128

Added: head/sysutils/pflogx/files/patch-src_LogEntryParser.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/pflogx/files/patch-src_LogEntryParser.cpp	Wed Dec 27 10:39:58 2017	(r457359)
@@ -0,0 +1,10 @@
+--- src/LogEntryParser.cpp.orig	2006-04-25 19:22:42 UTC
++++ src/LogEntryParser.cpp
+@@ -35,6 +35,7 @@
+ #include <sys/socket.h>
+ #include <netinet/in.h>
+ #include <arpa/inet.h>
++#include <netpfil/pf/pf.h>
+ 
+ 
+ 


More information about the svn-ports-head mailing list