From owner-freebsd-current@freebsd.org Fri May 5 13:39:41 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4B795D54882 for ; Fri, 5 May 2017 13:39:41 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (tensor.andric.com [IPv6:2001:470:7a58:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "tensor.andric.com", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 174819DB; Fri, 5 May 2017 13:39:41 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from [IPv6:2001:470:7a58::4dc9:3418:c61e:b581] (unknown [IPv6:2001:470:7a58:0:4dc9:3418:c61e:b581]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id B428E3ACF5; Fri, 5 May 2017 15:39:38 +0200 (CEST) From: Dimitry Andric Message-Id: Content-Type: multipart/signed; boundary="Apple-Mail=_ABB39161-4836-4987-AA8E-E0A6E26FF92C"; protocol="application/pgp-signature"; micalg=pgp-sha1 Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: make buildworld broken at r317821 (libsysdecode) Date: Fri, 5 May 2017 15:39:25 +0200 In-Reply-To: <20170505093141.ulbr7j65gxvzyz6i@vzakharov> Cc: freebsd-current , Ed Maste , Kyle Evans To: Vladimir Zakharov References: <20170505093141.ulbr7j65gxvzyz6i@vzakharov> X-Mailer: Apple Mail (2.3273) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 May 2017 13:39:41 -0000 --Apple-Mail=_ABB39161-4836-4987-AA8E-E0A6E26FF92C Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii On 5 May 2017, at 11:31, Vladimir Zakharov wrote: > > Cannot build world due to error in compiling lib/libsysdecode. ... > --- all_subdir_lib/libsysdecode --- > ioctl.c:30:10: fatal error: 'cam/cam_compat.h:#define' file not found > #include > ^~~~~~~~~~~~~~~~~~~~~~~~~~ ... > $ cat /etc/src.conf ... > WITH_BSD_GREP= This appears to be caused by bsdgrep. :-/ The build for lib/libsysdecode uses a shell script, mkioctls, to generate a ioctl.c file at build time. This script contains the following fragment: ioctl_includes=$( cd $includedir find -H -s * -name '*.h' | \ egrep -v '(.*disk.*|net/pfvar|net/if_pfsync)\.h' | \ xargs egrep -l \ '^#[ ]*define[ ]+[A-Za-z_][A-Za-z0-9_]*[ ]+_IO[^a-z0-9_]' | awk '{printf("#include <%s>\\n", $1)}' ) The idea is that all headers are searched for defines of ioctl macros, which start with _IO. The -l option to egrep is used to print only the matching filenames, not the matched content itself. However, this option seems to be broken in bsdgrep, as it *does* display the matched content: $ gnugrep -l printf /usr/include/stdio.h /usr/include/stdio.h $ bsdgrep -l printf /usr/include/stdio.h #define __SSTR 0x0200 /* this is an sprintf/snprintf string */ /usr/include/stdio.h I did a quick check, and this option seems to have been accidentally broken by r317703 [1] ("bsdgrep: fix -w flag matching with an empty pattern"). Ed, Kyle, any idea where the problem might be? -Dimitry [1] https://svnweb.freebsd.org/base?view=revision&revision=317703 --Apple-Mail=_ABB39161-4836-4987-AA8E-E0A6E26FF92C Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.30 iEYEARECAAYFAlkMgJoACgkQsF6jCi4glqNu8ACg/a0QYIURmpY723bJxwEkS9xM KJ8An0wvccC+Ef45e+ZhG/fwFyLSbJwM =Vtxa -----END PGP SIGNATURE----- --Apple-Mail=_ABB39161-4836-4987-AA8E-E0A6E26FF92C--