Index: head/net/mpd5/Makefile =================================================================== --- head/net/mpd5/Makefile (revision 485844) +++ head/net/mpd5/Makefile (revision 485845) @@ -1,57 +1,60 @@ # Created by: Archie Cobbs # $FreeBSD$ PORTNAME= mpd DISTVERSION= 5.8 -PORTREVISION= 9 +PORTREVISION= 10 CATEGORIES= net MASTER_SITES= SF/${PORTNAME}/Mpd5/Mpd-${PORTVERSION} PKGNAMESUFFIX= 5 DIST_SUBDIR= mpd5 MAINTAINER= eugen@FreeBSD.org COMMENT= Multi-link PPP daemon based on netgraph(4) LICENSE= BSD3CLAUSE BROKEN_SSL= libressl libressl-devel BROKEN_SSL_REASON_libressl= needs libfetch(3) linked with system libssl BROKEN_SSL_REASON_libressl-devel= needs libfetch(3) linked with system libssl OPTIONS_DEFINE= DOCS NG_IPACCT NG_IPACCT_DESC= Use ng_ipacct kernel module from port HAS_CONFIGURE= YES CONFIGURE_WRKSRC= "${WRKSRC}/src" USES= ssl .include MAKE_ARGS+= OSVERSION=${OSVERSION} .if ${OPSYS} == "FreeBSD" && ${OSVERSION} < 1200085 BROKEN_SSL+= openssl111 BROKEN_SSL_REASON_openssl111= needs libfetch(3) linked with system libssl .endif .if ${PORT_OPTIONS:MNG_IPACCT} BUILD_DEPENDS+= ${LOCALBASE}/include/netgraph/ng_ipacct.h:net-mgmt/ng_ipacct .if exists(${KMODDIR}/ng_ipacct.ko) RUN_DEPENDS+= ${KMODDIR}/ng_ipacct.ko:net-mgmt/ng_ipacct .else RUN_DEPENDS+= /boot/modules/ng_ipacct.ko:net-mgmt/ng_ipacct .endif +.else +CONFIGURE_ENV+= USE_NG_IPACCT=no +EXTRA_PATCHES+= ${FILESDIR}/extra-patch-no-ng_ipacct .endif USE_RC_SUBR= mpd5 CONFSUF= conf secret script DOCSDIR= ${PREFIX}/share/doc/mpd5 PORTDOCS= README mpd* PLIST_FILES= ${CONFSUF:S/^/etc\/mpd5\/mpd./:S/$/.sample/} sbin/mpd5 .if !defined(WITHOUT_MAN) PLIST_FILES+= man/man8/mpd5.8.gz .endif .include Index: head/net/mpd5/files/extra-patch-no-ng_ipacct =================================================================== --- head/net/mpd5/files/extra-patch-no-ng_ipacct (nonexistent) +++ head/net/mpd5/files/extra-patch-no-ng_ipacct (revision 485845) @@ -0,0 +1,10 @@ +--- src/Makefile.orig 2018-11-25 14:23:23.317174000 +0700 ++++ src/Makefile 2018-11-25 14:26:24.356555000 +0700 +@@ -56,7 +56,6 @@ + USE_NG_BPF= yes + USE_NG_CAR= yes + USE_NG_DEFLATE= yes +-USE_NG_IPACCT= yes + USE_NG_MPPC= yes + USE_NG_NAT= yes + USE_NG_NETFLOW= yes Property changes on: head/net/mpd5/files/extra-patch-no-ng_ipacct ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/net/mpd5/files/patch-configure =================================================================== --- head/net/mpd5/files/patch-configure (nonexistent) +++ head/net/mpd5/files/patch-configure (revision 485845) @@ -0,0 +1,23 @@ +Index: configure +=================================================================== +--- src/configure (revision 2259) ++++ src/configure (working copy) +@@ -33,7 +33,9 @@ else + fi + + echo -n "Looking for ng_ipacct ..." +-if [ -e /usr/include/netgraph/ng_ipacct.h \ ++if [ "$USE_NG_IPACCT" = no ]; then ++ echo " disabled." ++else if [ -e /usr/include/netgraph/ng_ipacct.h \ + -o -e /usr/local/include/netgraph/ng_ipacct.h ] + then + echo " found." +@@ -41,6 +43,7 @@ then + else + echo " not found." + fi ++fi + + echo -n "Looking for ng_mppc ..." + if [ -e /usr/include/netgraph/ng_mppc.h \ Property changes on: head/net/mpd5/files/patch-configure ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/net/mpd5/files/patch-src-Makefile =================================================================== --- head/net/mpd5/files/patch-src-Makefile (revision 485844) +++ head/net/mpd5/files/patch-src-Makefile (revision 485845) @@ -1,245 +1,286 @@ ---- src/Makefile 2016-01-06 22:42:06.000000000 +0700 -+++ src/Makefile 2017-07-02 17:48:59.910230000 +0700 -@@ -11,8 +11,17 @@ +--- src/Makefile.orig 2016-01-06 22:42:06.000000000 +0700 ++++ src/Makefile 2018-11-25 13:48:31.977979000 +0700 +@@ -9,10 +9,20 @@ + + PROG?= mpd5 PREFIX?= /usr/local ++LOCALBASE?= ${PREFIX} BINDIR?= ${PREFIX}/sbin VERSION= 5.8 -NOMAN= + +.if defined(OSVERSION) +.if ${OSVERSION} > 1100100 +MK_MAN= no +.else +NO_MAN= +.endif +.else +MK_MAN= no NO_MAN= +.endif BINOWN!= /usr/bin/id -n -u BINGRP!= /usr/bin/id -n -g -@@ -72,7 +81,7 @@ +@@ -60,9 +70,6 @@ + USE_AUTH_PAM= yes + USE_AUTH_SYSTEM= yes +-# Build with builtin libpdel +-NOLIBPDEL= yes +- + # Build without builtin web server. + #NOWEB= yes + +@@ -72,7 +79,7 @@ + # Print wide protocol names instead of short names. # Comment this line, to save about 10 KB space -COPTS+= -DPROTO_NAME_LIST +CFLAGS+= -DPROTO_NAME_LIST # Reduce some internal structures size to save more memory # This is to limit amount of active sessions -@@ -84,27 +93,27 @@ +@@ -84,27 +91,27 @@ ## filter TCP accept connections LDADD+= -lwrap DPADD+= ${LIBWRAP} -COPTS+= -DUSE_WRAP +CFLAGS+= -DUSE_WRAP .endif ## authentication methods: opie, pam, /etc/password .if defined ( USE_AUTH_OPIE ) LDADD+= -lopie DPADD+= ${LIBOPIE} -COPTS+= -DUSE_OPIE +CFLAGS+= -DUSE_OPIE .endif .if exists ( /usr/lib/libpam.so ) && defined ( USE_AUTH_PAM ) LDADD+= -lpam DPADD+= ${LIBPAM} -COPTS+= -DUSE_PAM +CFLAGS+= -DUSE_PAM .endif .if defined ( USE_AUTH_SYSTEM ) ## based on /etc/password LDADD+= -lcrypt DPADD+= ${LIBCRYPT} ${LIBUTIL} -COPTS+= -DUSE_SYSTEM +CFLAGS+= -DUSE_SYSTEM .endif LDADD+= -lnetgraph -lutil -@@ -122,10 +131,10 @@ +@@ -113,19 +120,12 @@ + LDADD+= -L/usr/lib -lradius + DPADD+= ${LIBRADIUS} +-## libpdel needs ssl and libexpat (libxml2 cannot be used) +-.if !defined ( NOLIBPDEL ) +-LDADD+= -L${PREFIX}/lib +-LDADD+= -lpdel +-LDADD+= -lexpat +-.endif +- MPD_VERSION!= echo -n "${VERSION} (`id -un`@`uname -n` `LC_TIME=C date +'%R %v'`)" -COPTS+= -DPATH_CONF_DIR='"${MPD_CONF_DIR}"' -COPTS+= -DMPD_VERSION='"${MPD_VERSION}"' -COPTS+= -g -COPTS+= -Wall \ +CFLAGS+= -DPATH_CONF_DIR='"${MPD_CONF_DIR}"' +CFLAGS+= -DMPD_VERSION='"${MPD_VERSION}"' +CFLAGS+= -g +CFLAGS+= -Wall \ -Wcast-align \ -Wchar-subscripts \ -Wformat \ -@@ -139,11 +148,11 @@ - -I${PREFIX}/include +@@ -135,15 +135,14 @@ + -Wnested-externs \ + -Wpointer-arith \ + -Wwrite-strings \ +- -pthread \ +- -I${PREFIX}/include ++ -pthread .if defined ( MPD_VENDOR ) -COPTS+= -DMPD_VENDOR='"${MPD_VENDOR}"' +CFLAGS+= -DMPD_VENDOR='"${MPD_VENDOR}"' .endif .if defined ( SYSLOG_FACILITY ) -COPTS+= -DSYSLOG_FACILITY='"${SYSLOG_FACILITY}"' +CFLAGS+= -DSYSLOG_FACILITY='"${SYSLOG_FACILITY}"' .endif # Standard sources -@@ -155,14 +164,14 @@ +@@ -155,14 +154,13 @@ util.c vars.c eap.c msoft.c ippool.c .if defined ( NOWEB ) -COPTS+= -DNOWEB +CFLAGS+= -DNOWEB .else STDSRCS+= web.c LDADD+= -lssl .endif - .if defined ( NOLIBPDEL ) +-.if defined ( NOLIBPDEL ) -COPTS+= -DNOLIBPDEL -I./contrib/libpdel -+CFLAGS+= -DNOLIBPDEL -I./contrib/libpdel ++CFLAGS+= -DNOLIBPDEL -I./contrib/libpdel PDPATH1= contrib/libpdel/util:contrib/libpdel/structs PDPATH2= contrib/libpdel/structs/type .if defined ( NOWEB ) -@@ -206,54 +215,54 @@ +@@ -200,60 +198,59 @@ + string_fp.c \ + timeout_fp.c + .endif +-.endif + # Add sources and flags for the various physical layer types + .if defined ( PHYSTYPE_MODEM ) SRCS+= modem.c chat.c -COPTS+= -DPHYSTYPE_MODEM +CFLAGS+= -DPHYSTYPE_MODEM .endif .if defined ( PHYSTYPE_UDP ) SRCS+= udp.c -COPTS+= -DPHYSTYPE_UDP +CFLAGS+= -DPHYSTYPE_UDP .endif .if defined ( PHYSTYPE_TCP ) SRCS+= tcp.c -COPTS+= -DPHYSTYPE_TCP +CFLAGS+= -DPHYSTYPE_TCP .endif .if defined ( PHYSTYPE_NG_SOCKET ) SRCS+= ng.c -COPTS+= -DPHYSTYPE_NG_SOCKET +CFLAGS+= -DPHYSTYPE_NG_SOCKET .endif .if defined ( PHYSTYPE_PPTP ) SRCS+= pptp.c pptp_ctrl.c -COPTS+= -DPHYSTYPE_PPTP -COPTS+= -DRANDOMIZE_CID -#COPTS+= -DLOOK_LIKE_NT +CFLAGS+= -DPHYSTYPE_PPTP +CFLAGS+= -DRANDOMIZE_CID +#CFLAGS+= -DLOOK_LIKE_NT .endif .if defined ( PHYSTYPE_PPPOE ) SRCS+= pppoe.c -COPTS+= -DPHYSTYPE_PPPOE +CFLAGS+= -DPHYSTYPE_PPPOE .endif .if defined ( PHYSTYPE_L2TP ) SRCS+= l2tp.c l2tp_avp.c l2tp_ctrl.c -COPTS+= -DPHYSTYPE_L2TP +CFLAGS+= -DPHYSTYPE_L2TP .endif # CCP .if defined ( CCP_DEFLATE ) && defined ( USE_NG_DEFLATE ) SRCS+= ccp_deflate.c -COPTS+= -DCCP_DEFLATE -COPTS+= -DUSE_NG_DEFLATE +CFLAGS+= -DCCP_DEFLATE +CFLAGS+= -DUSE_NG_DEFLATE .endif .if defined ( CCP_MPPC ) && defined ( USE_NG_MPPC ) SRCS+= ccp_mppc.c -COPTS+= -DCCP_MPPC -COPTS+= -DUSE_NG_MPPC +CFLAGS+= -DCCP_MPPC +CFLAGS+= -DUSE_NG_MPPC .endif .if defined ( CCP_PRED1 ) SRCS+= ccp_pred1.c -COPTS+= -DCCP_PRED1 +CFLAGS+= -DCCP_PRED1 .if defined ( USE_NG_PRED1 ) -COPTS+= -DUSE_NG_PRED1 +CFLAGS+= -DUSE_NG_PRED1 .endif .endif -@@ -262,46 +271,46 @@ +@@ -262,46 +259,46 @@ .if defined ( ECP_DES ) SRCS+= ecp_dese.c SRCS+= ecp_dese_bis.c -COPTS+= -DECP_DES +CFLAGS+= -DECP_DES NEED_DES= yes .endif # Features .if defined ( USE_NG_BPF ) -COPTS+= -DUSE_NG_BPF +CFLAGS+= -DUSE_NG_BPF LDADD+= -lpcap DPADD+= ${LIBPCAP} .endif .if defined ( USE_NG_CAR ) -COPTS+= -DUSE_NG_CAR +CFLAGS+= -DUSE_NG_CAR .endif .if defined ( USE_NG_IPACCT ) -COPTS+= -DUSE_NG_IPACCT -+CFLAGS+= -DUSE_NG_IPACCT ++CFLAGS+= -DUSE_NG_IPACCT -nostdinc -I/usr/include -I${LOCALBASE}/include .endif .if defined ( USE_NG_NAT ) SRCS+= nat.c -COPTS+= -DUSE_NG_NAT +CFLAGS+= -DUSE_NG_NAT .endif .if defined ( USE_NG_NETFLOW ) -COPTS+= -DUSE_NG_NETFLOW +CFLAGS+= -DUSE_NG_NETFLOW .endif .if defined ( USE_NG_TCPMSS ) -COPTS+= -DUSE_NG_TCPMSS +CFLAGS+= -DUSE_NG_TCPMSS .endif .if defined ( USE_NG_VJC ) -COPTS+= -DUSE_NG_VJC +CFLAGS+= -DUSE_NG_VJC .endif .if defined ( USE_IPFW ) -COPTS+= -DUSE_IPFW +CFLAGS+= -DUSE_IPFW .endif .if defined ( USE_FETCH ) -COPTS+= -DUSE_FETCH +CFLAGS+= -DUSE_FETCH LDADD+= -lfetch DPADD+= ${LIBFETCH} .endif .if defined ( SMALL_SYSTEM ) -COPTS+= -DSMALL_SYSTEM +CFLAGS+= -DSMALL_SYSTEM .endif # Add in required support files and libraries -@@ -310,7 +319,7 @@ +@@ -310,15 +307,12 @@ .if exists ( /usr/lib/libexecinfo.so ) LDADD+= -lexecinfo -COPTS+= -DUSE_BACKTRACE +CFLAGS+= -DUSE_BACKTRACE .endif # Now add standard sources + + SRCS+= ${STDSRCS} +- +-.if defined ( NOLIBPDEL ) + SRCS+= ${PDELSRCS} +-.endif + + .include