View previous topic :: View next topic |
Author |
Message |
darkomen
Joined: 15 Apr 2014 Posts: 4
|
Posted: Tue Apr 15, 2014 2:21 pm Post subject: FreeBSD 9.1 + IPF |
|
|
Trying to install miniupnp on this system and getting error
Code: | ===> Building for miniupnpd-1.8,1
cc -O2 -pipe -fno-strict-aliasing -ansi -Wall -W -Wstrict-prototypes -fno-common -c -o pf/obsdrdr.o pf/obsdrdr.c
pf/obsdrdr.c: In function 'add_redirect_rule2':
pf/obsdrdr.c:198: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c:198: error: (Each undeclared identifier is reported only once
pf/obsdrdr.c:198: error: for each function it appears in.)
pf/obsdrdr.c:254: error: 'tag' undeclared (first use in this function)
pf/obsdrdr.c: In function 'get_redirect_rule':
pf/obsdrdr.c:475: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c: In function 'delete_redirect_rule':
pf/obsdrdr.c:576: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c: In function 'get_redirect_rule_by_index':
pf/obsdrdr.c:694: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c: In function 'get_portmappings_in_range':
pf/obsdrdr.c:806: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c:837: warning: format '%lu' expects type 'long unsigned int', but argument 3 has type 'unsigned int'
*** [pf/obsdrdr.o] Error code 1
Stop in /usr/ports/net/miniupnpd/work/miniupnpd-1.8.
*** [do-build] Error code 1
Stop in /usr/ports/net/miniupnpd.
*** [build] Error code 1
Stop in /usr/ports/net/miniupnpd.
[root@vista /usr/ports/net/miniupnpd]# uname -a
FreeBSD 9.1-RELEASE-p1 FreeBSD 9.1-RELEASE-p1 #3: Tue Jun 4 18:46:09 MSK 2013 :/usr/obj/usr/src/sys/main_kernel_05_03_2013 i386
|
I'm trying this patch but it had no effect
Code: | --- Makefile 31 Mar 2014 12:21:23 -0000 1.79
+++ Makefile 7 Apr 2014 10:29:43 -0000
@@ -45,7 +45,8 @@ FWNAME = ipf
.if $(OSNAME) == "FreeBSD"
FWNAME != . /etc/rc.subr; . /etc/rc.conf; \
if checkyesno ipfilter_enable; then \
- echo "ipf"; else echo "pf"; fi
+ echo "ipf"; elif checkyesno pf_enable; then \
+ echo "pf"; else echo "ipfw" ; fi
.endif
.if $(OSNAME) == "NetBSD"
|
[/i] |
|
Back to top |
|
 |
miniupnp Site Admin
Joined: 14 Apr 2007 Posts: 1589
|
Posted: Tue Apr 15, 2014 5:32 pm Post subject: |
|
|
if you are using ipf, it should not try to compile pf/obsdrdr.c
try to force FWNAME=ipf in Makefile.
It is possible you have an already existing FWNAME variable _________________ Main miniUPnP author.
https://miniupnp.tuxfamily.org/ |
|
Back to top |
|
 |
darkomen
Joined: 15 Apr 2014 Posts: 4
|
Posted: Wed Apr 16, 2014 7:31 am Post subject: |
|
|
I changed Makefile to this
FWNAME=ipf
But
Code: | [root@vista /usr/ports/net/miniupnpd]# make
===> Building for miniupnpd-1.8.20140310,1
cc -O2 -pipe -fno-strict-aliasing -ansi -Wall -W -Wstrict-prototypes -fno-common -c -o pf/obsdrdr.o pf/obsdrdr.c
pf/obsdrdr.c: In function 'add_redirect_rule2':
pf/obsdrdr.c:244: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c:244: error: (Each undeclared identifier is reported only once
pf/obsdrdr.c:244: error: for each function it appears in.)
pf/obsdrdr.c:306: error: 'tag' undeclared (first use in this function)
pf/obsdrdr.c: In function 'get_redirect_rule':
pf/obsdrdr.c:509: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c: In function 'priv_delete_redirect_rule':
pf/obsdrdr.c:617: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c: In function 'priv_delete_filter_rule':
pf/obsdrdr.c:712: warning: unused parameter 'iaddr'
pf/obsdrdr.c: In function 'get_redirect_rule_by_index':
pf/obsdrdr.c:810: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c: In function 'get_portmappings_in_range':
pf/obsdrdr.c:926: error: 'anchor_name' undeclared (first use in this function)
pf/obsdrdr.c:962: warning: format '%lu' expects type 'long unsigned int', but argument 3 has type 'unsigned int'
*** [pf/obsdrdr.o] Error code 1
Stop in /usr/ports/net/miniupnpd/work/miniupnpd-1.8.20140310.
*** [do-build] Error code 1
Stop in /usr/ports/net/miniupnpd.
*** [build] Error code 1
|
|
|
Back to top |
|
 |
miniupnp Site Admin
Joined: 14 Apr 2007 Posts: 1589
|
Posted: Wed Apr 16, 2014 7:57 am Post subject: |
|
|
FWNAME must be set to "pf" somewhere below, or else it wouldn't try to compile pf/obsdrdr.c
Code: | .if $(FWNAME) == "pf"
ALLOBJS += $(PFOBJS)
.elif $(FWNAME) == "ipfw"
ALLOBJS += $(IPFWOBJS)
.else
ALLOBJS += $(IPFOBJS)
.endif
|
PFOBJS = pf/obsdrdr.o pf/pfpinhole.o
IPFOBJS = ipf/ipfrdr.o
IPFWOBJS = ipfw/ipfwrdr.o ipfw/ipfwaux.o _________________ Main miniUPnP author.
https://miniupnp.tuxfamily.org/ |
|
Back to top |
|
 |
darkomen
Joined: 15 Apr 2014 Posts: 4
|
Posted: Wed Apr 16, 2014 8:08 am Post subject: |
|
|
I deleted this rm /usr/include/net/pfvar.h and can install this package, may be you can fix this troubles? |
|
Back to top |
|
 |
|