Subject: mbrlabel won't build for amd64
To: None <current-users@netbsd.org>
From: Steven M. Bellovin <smb@cs.columbia.edu>
List: current-users
Date: 12/27/2005 23:22:43
# compile mbrlabel/mbrlabel.o
/usr/BUILD64/tools/bin/x86_64--netbsd-gcc -O2 -Wall -Wstrict-prototypes -Wmissi
ng-prototypes -Wpointer-arith -Wno-sign-compare -Wno-traditional -Wreturn-type -
Wswitch -Wshadow -Wcast-qual -Wwrite-strings -Werror -I/usr/src/sbin/disklabe
l -nostdinc -isystem /usr/BUILD64/netbsd/usr/include -c /usr/src/sbin/mbrla
bel/mbrlabel.c
/usr/src/sbin/mbrlabel/mbrlabel.c: In function `main':
/usr/src/sbin/mbrlabel/mbrlabel.c:283: warning: comparison is always false due t
o limited range of data type
*** Failed target: mbrlabel.o
The statement in question is
if ((errno == ERANGE && sector == ULONG_MAX) ||
sector > UINT32_MAX)
sector is declared uint32_t, which is probably wrong.
--Steven M. Bellovin, http://www.cs.columbia.edu/~smb