diff options
author | Bryan Drewery <bdrewery@FreeBSD.org> | 2016-01-27 01:33:23 +0000 |
---|---|---|
committer | Bryan Drewery <bdrewery@FreeBSD.org> | 2016-01-27 01:33:23 +0000 |
commit | 545d341d774438a75a48bec334e566059bd4f6e2 (patch) | |
tree | ddf7230cd8288727745d477343eef6388bb43cab /lib | |
parent | bde5c8997ec9312a1e3923234e3d6ac8ff6f797d (diff) | |
download | src-545d341d774438a75a48bec334e566059bd4f6e2.tar.gz src-545d341d774438a75a48bec334e566059bd4f6e2.zip |
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
Notes
Notes:
svn path=/head/; revision=294877
Diffstat (limited to 'lib')
-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 ed1d75f29ce4..6f51f08f236b 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 \ |