kholtman/afio — Issue #3: 2.5.1 Build log with warnings (Debian hardened flags)
Author: jaalto
Created: 2012-02-05 23:50:15+00:00
State: open

FYI,

Here is build log that displays couple of warnign with Debian hardened gcc (4.6.2) flags

gcc -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DMEMCPY -DMKDIR -DVOIDFIX -DHAVEFCNTL -DHAVEMEMCMP -DDEFFMTCMD='"fdformat /dev/fd0H1440"' -DHAVE_LCHOWN -DPRG_COMPRESS='"gzip"' -DHAVEFNMATCH -D_FORTIFY_SOURCE=2 -c -o afio.o afio.c
afio.c: In function 'incheckdata':
afio.c:1561:13: warning: variable 'oops' set but not used [-Wunused-but-set-variable]
afio.c: In function 'outflush':
afio.c:3970:7: warning: variable 'wrstat' set but not used [-Wunused-but-set-variable]
afio.c: In function 'writedisk':
afio.c:5125:4: warning: ignoring return value of 'nice', declared with attribute warn_unused_result [-Wunused-result]
afio.c: In function 'pipechld':
afio.c:4312:7: warning: ignoring return value of 'dup', declared with attribute warn_unused_result [-Wunused-result]
afio.c:4323:7: warning: ignoring return value of 'dup', declared with attribute warn_unused_result [-Wunused-result]
afio.c: In function 'openotty':
afio.c:3345:5: warning: ignoring return value of 'dup', declared with attribute warn_unused_result [-Wunused-result]
afio.c: In function 'opencontrolscript':
afio.c:3090:2: warning: ignoring return value of 'dup', declared with attribute warn_unused_result [-Wunused-result]
afio.c: In function 'incheckdata':
afio.c:1604:2: warning: ignoring return value of 'dup', declared with attribute warn_unused_result [-Wunused-result]
afio.c: In function 'dirmake':
afio.c:990:5: warning: ignoring return value of 'chown', declared with attribute warn_unused_result [-Wunused-result]
gcc -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DMEMCPY -DMKDIR -DVOIDFIX -DHAVEFCNTL -DHAVEMEMCMP -DDEFFMTCMD='"fdformat /dev/fd0H1440"' -DHAVE_LCHOWN -DPRG_COMPRESS='"gzip"' -DHAVEFNMATCH -D_FORTIFY_SOURCE=2 -c -o compfile.o compfile.c
compfile.c: In function 'compressfile':
compfile.c:229:7: warning: variable 'namelen' set but not used [-Wunused-but-set-variable]
awk -f exten_make.awk afio.1 >exten_default.h
gcc -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DMEMCPY -DMKDIR -DVOIDFIX -DHAVEFCNTL -DHAVEMEMCMP -DDEFFMTCMD='"fdformat /dev/fd0H1440"' -DHAVE_LCHOWN -DPRG_COMPRESS='"gzip"' -DHAVEFNMATCH -D_FORTIFY_SOURCE=2 -c -o exten.o exten.c
gcc -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DMEMCPY -DMKDIR -DVOIDFIX -DHAVEFCNTL -DHAVEMEMCMP -DDEFFMTCMD='"fdformat /dev/fd0H1440"' -DHAVE_LCHOWN -DPRG_COMPRESS='"gzip"' -DHAVEFNMATCH -D_FORTIFY_SOURCE=2 -c -o match.o match.c
gcc -Wl,-z,relro afio.o compfile.o exten.o match.o -o afio