diff options
author | bdrewery <bdrewery@FreeBSD.org> | 2016-01-27 01:33:23 +0000 |
---|---|---|
committer | bdrewery <bdrewery@FreeBSD.org> | 2016-01-27 01:33:23 +0000 |
commit | 273b2d98ab2ca59155970f71a9edc9d7c79d0e68 (patch) | |
tree | ddf7230cd8288727745d477343eef6388bb43cab /lib/libc | |
parent | 46307c6f50aa27e604086cfcd78d7ee2fc110f4b (diff) | |
download | FreeBSD-src-273b2d98ab2ca59155970f71a9edc9d7c79d0e68.zip FreeBSD-src-273b2d98ab2ca59155970f71a9edc9d7c79d0e68.tar.gz |
Replace nslexer.l->nslexer.c custom rule with a -D CFLAG.
This avoids reproducing the lex logic which had dependencies set wrong
and used an intermediate file for modifying the YY_BUF_SIZE.
This has only been possible since flex 2.5.37 was imported in r250873,
which uses #ifndef YY_BUF_SIZE.
MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division
Diffstat (limited to 'lib/libc')
-rw-r--r-- | lib/libc/net/Makefile.inc | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/lib/libc/net/Makefile.inc b/lib/libc/net/Makefile.inc index ed1d75f..6f51f08 100644 --- a/lib/libc/net/Makefile.inc +++ b/lib/libc/net/Makefile.inc @@ -12,7 +12,7 @@ SRCS+= base64.c ether_addr.c eui64.c \ getproto.c getprotoent.c getprotoname.c getservent.c \ if_indextoname.c if_nameindex.c if_nametoindex.c \ ip6opt.c linkaddr.c map_v4v6.c name6.c ntoh.c \ - nsdispatch.c nslexer.c nsparser.y nss_compat.c \ + nsdispatch.c nslexer.l nsparser.y nss_compat.c \ rcmd.c rcmdsh.c recv.c rthdr.c sctp_sys_calls.c send.c \ sockatmark.c sourcefilter.c vars.c @@ -34,13 +34,8 @@ CFLAGS+=-I${LIBC_SRCTOP}/resolv YFLAGS+=-p_nsyy LFLAGS+=-P_nsyy -CLEANFILES+=nslexer.c nslexer.c.* - -nslexer.c: nslexer.l - ${LEX} ${LFLAGS} -o${.TARGET}.tmp1 ${.IMPSRC} - sed -e '/YY_BUF_SIZE/s/16384/1024/' ${.TARGET}.tmp1 >${.TARGET}.tmp2 - rm -f ${.TARGET}.tmp1 - mv -f ${.TARGET}.tmp2 ${.TARGET} +CFLAGS.nslexer.c= -DYY_BUF_SIZE=1024 +CFLAGS+= ${CFLAGS.${.IMPSRC:T}} MAN+= byteorder.3 ethers.3 eui64.3 \ getaddrinfo.3 gai_strerror.3 gethostbyname.3 \ |