View | Details | Raw Unified | Return to bug 235864
Collapse All | Expand All

(-)ndproxy/Makefile (-7 / +7 lines)
Lines 1-9 Link Here
1
# $FreeBSD$
1
# $FreeBSD$
2
2
3
PORTNAME=	ndproxy
3
PORTNAME=	ndproxy
4
PORTVERSION=	2.0
4
PORTVERSION=	3.2
5
DISTVERSIONPREFIX=	v
5
CATEGORIES=	net
6
CATEGORIES=	net ipv6
7
6
8
MAINTAINER=	fbsd.bugzilla@fenyo.net
7
MAINTAINER=	fbsd.bugzilla@fenyo.net
9
COMMENT=	Implementation of IPv6 Neighbor Discovery proxy
8
COMMENT=	Implementation of IPv6 Neighbor Discovery proxy
Lines 11-27 Link Here
11
LICENSE=	BSD2CLAUSE
10
LICENSE=	BSD2CLAUSE
12
LICENSE_FILE=	${WRKSRC}/LICENSE
11
LICENSE_FILE=	${WRKSRC}/LICENSE
13
12
14
BROKEN_mips=		fails to build: ndproxy.c:51: function declaration isn't a prototype
13
USES=		kmod
15
BROKEN_mips64=		fails to build: ndproxy.c:51: function declaration isn't a prototype
16
BROKEN_powerpc64=	fails to build: ndproxy.c:51: function declaration isn't a prototype
17
14
18
SUB_FILES=	pkg-message
15
SUB_FILES=	pkg-message
19
16
20
USES=		kmod
21
USE_RC_SUBR=	ndproxy
17
USE_RC_SUBR=	ndproxy
22
USE_GITHUB=	yes
18
USE_GITHUB=	yes
23
GH_ACCOUNT=	AlexandreFenyo
19
GH_ACCOUNT=	AlexandreFenyo
20
GH_TAGNAME=	v${PORTVERSION}
24
21
22
# build for a kernel with 'options VIMAGE'
23
CFLAGS+=	-DVIMAGE
24
25
PLIST_FILES=	${KMODDIR}/${PORTNAME}.ko man/man4/${PORTNAME}.4.gz
25
PLIST_FILES=	${KMODDIR}/${PORTNAME}.ko man/man4/${PORTNAME}.4.gz
26
26
27
pre-build:
27
pre-build:
(-)ndproxy/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1502146291
1
TIMESTAMP = 1550596032
2
SHA256 (AlexandreFenyo-ndproxy-v2.0_GH0.tar.gz) = 29c626355d91fef9c13281d668b2a1f79618758c44c4aaf4b0434977ceb38588
2
SHA256 (AlexandreFenyo-ndproxy-3.2-v3.2_GH0.tar.gz) = 8ea72bb12b26bb1ca4df31bc1bd86b3eea52d42fe2d014d890a1a067721c63dd
3
SIZE (AlexandreFenyo-ndproxy-v2.0_GH0.tar.gz) = 8274107
3
SIZE (AlexandreFenyo-ndproxy-3.2-v3.2_GH0.tar.gz) = 10172863
(-)ndproxy/files/ndproxy.in (-11 / +17 lines)
Lines 17-24 Link Here
17
ndproxy_start()
17
ndproxy_start()
18
{
18
{
19
    echo "Starting ndproxy:"
19
    echo "Starting ndproxy:"
20
    if ! sysctl net.inet6.ndproxyconf_uplink_interface > /dev/null 2>&1; then
20
    sysctl net.inet6.ndproxyconf_uplink_interface > /dev/null 2>&1
21
	if ! kldload ndproxy > /dev/null 2>&1; then
21
    if [ $? -eq 1 ]; then
22
	kldload ndproxy > /dev/null 2>&1
23
	if [ $? -eq 1 ]; then
22
	    echo Failure loading ndproxy.
24
	    echo Failure loading ndproxy.
23
	    return;
25
	    return;
24
	fi
26
	fi
Lines 26-56 Link Here
26
28
27
    sysctl net.inet6.ndproxycount=0
29
    sysctl net.inet6.ndproxycount=0
28
30
31
    sysctl net.inet6.ndproxyconf_uplink_interface=${ndproxy_uplink_interface}
32
    sysctl net.inet6.ndproxyconf_downlink_mac_address=${ndproxy_downlink_mac_address}
33
    sysctl net.inet6.ndproxyconf_exception_ipv6_addresses=${ndproxy_exception_ipv6_addresses}
34
    sysctl net.inet6.ndproxyconf_uplink_ipv6_addresses=${ndproxy_uplink_ipv6_addresses}
35
29
    if [ -z "${ndproxy_uplink_interface}" ]; then
36
    if [ -z "${ndproxy_uplink_interface}" ]; then
30
	echo "Warning: ndproxy_uplink_interface should be defined in rc.conf (see ndproxy(4))."
37
	echo "Warning: ndproxy_uplink_interface should be defined in rc.conf (see ndproxy(4))."
31
    fi
38
    fi
32
    sysctl net.inet6.ndproxyconf_uplink_interface=${ndproxy_uplink_interface}
33
39
34
    if [ -z "${ndproxy_downlink_mac_address}" ]; then
40
    if [ -z "${ndproxy_downlink_mac_address}" ]; then
35
	echo "Warning: ndproxy_downlink_mac_address should be defined in rc.conf (see ndproxy(4))."
41
	echo "Warning: ndproxy_downlink_mac_address should be defined in rc.conf (see ndproxy(4))."
36
    fi
42
    fi
37
    sysctl net.inet6.ndproxyconf_downlink_mac_address=${ndproxy_downlink_mac_address}
38
43
39
    if [ -z "${ndproxy_uplink_ipv6_addresses}" ]; then
44
    if [ -z "${ndproxy_uplink_ipv6_addresses}" ]; then
40
	echo "Warning: ndproxy_uplink_ipv6_addresses should be defined in rc.conf (see ndproxy(4))."
45
	echo "Warning: ndproxy_uplink_ipv6_addresses should be defined in rc.conf (see ndproxy(4))."
41
    fi
46
    fi
42
    sysctl net.inet6.ndproxyconf_exception_ipv6_addresses=${ndproxy_exception_ipv6_addresses}
43
47
44
    # Note that ndproxy_exception_ipv6_addresses may be left empty.
48
    # Note that ndproxy_exception_ipv6_addresses may be left empty.
45
49
    
46
    if [ -n "${ndproxy_uplink_interface}" ]; then
50
    if [ -n "${ndproxy_uplink_interface}" ]; then
47
	if ! ifconfig ${ndproxy_uplink_interface} | head -1 | grep -q PPROMISC; then
51
	ifconfig ${ndproxy_uplink_interface} | head -1 | grep PPROMISC > /dev/null
52
	if [ $? -eq 1 ]; then
48
	    echo "Putting interface ${ndproxy_uplink_interface} into permanently promiscuous mode."
53
	    echo "Putting interface ${ndproxy_uplink_interface} into permanently promiscuous mode."
49
	    ifconfig ${ndproxy_uplink_interface} promisc
54
	    ifconfig ${ndproxy_uplink_interface} promisc
50
	fi
55
	fi
51
    fi
56
    fi
52
    sysctl net.inet6.ndproxyconf_uplink_ipv6_addresses=${ndproxy_uplink_ipv6_addresses}
57
    
53
54
    echo Done.
58
    echo Done.
55
}
59
}
56
60
Lines 58-67 Link Here
58
{
62
{
59
    echo "Stopping ndproxy:"
63
    echo "Stopping ndproxy:"
60
64
61
    if ! sysctl net.inet6.ndproxyconf_uplink_interface > /dev/null 2>&1; then
65
    sysctl net.inet6.ndproxyconf_uplink_interface > /dev/null 2>&1
66
    if [ $? -eq 1 ]; then
62
	echo Failure unloading ndproxy.
67
	echo Failure unloading ndproxy.
63
    else
68
    else
64
	if ! kldunload ndproxy > /dev/null 2>&1; then
69
	kldunload ndproxy > /dev/null 2>&1
70
	if [ $? -eq 1 ]; then
65
	    echo Failure unloading ndproxy.
71
	    echo Failure unloading ndproxy.
66
	else
72
	else
67
	    echo Done.
73
	    echo Done.

Return to bug 235864