Overview
| Artifact ID: | 910dad49f80e88adbc12ce9fde71ab3ea78d7c9b |
|---|---|
| Ticket: | 442920ffffffffffffffffffffffffffffffffff
gcc warnings on FreeBSD |
| User & Date: | lloydlim on 2001-07-19 22:51:53 |
Changes
- assignee changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
Compiling Tcl on FreeBSD 2.x, 3.x, and 4.x gives the following warnings: ./../generic/tclIOSock.c: In function `TclSockMinimumBuffers': ./../generic/tclIOSock.c:103: warning: passing arg 5 of `setsockopt' as signed due to prototype ./../generic/tclIOSock.c:109: warning: passing arg 5 of `setsockopt' as signed due to prototype ./../unix/tclUnixFCmd.c: In function `DoCopyFile': ./../unix/tclUnixFCmd.c:389: warning: passing arg 2 of `mknod' with different width due to prototype ./../unix/tclUnixFCmd.c:395: warning: passing arg 2 of `mkfifo' with different width due to prototype ./../unix/tclUnixFCmd.c: In function `DoCreateDirectory': ./../unix/tclUnixFCmd.c:593: warning: passing arg 1 of `umask' with different width due to prototype ./../unix/tclUnixFCmd.c:594: warning: passing arg 1 of `umask' with different width due to prototype ./../unix/tclUnixFCmd.c:602: warning: passing arg 2 of `mkdir' with different width due to prototype ./../unix/tclUnixFCmd.c: In function `CopyFileAtts': ./../unix/tclUnixFCmd.c:1038: warning: passing arg 2 of `chmod' with different width due to prototype ./../unix/tclUnixFCmd.c:1040: warning: passing arg 2 of `chmod' with different width due to prototype ./../unix/tclUnixFCmd.c: In function `SetPermissionsAttribute': ./../unix/tclUnixFCmd.c:1383: warning: passing arg 2 of `chmod' with different width due to prototype (The tclIOSock.c warnings are only on FreeBSD 2.x and 3.x.) These warnings are caused by the -Wconversion flag. I don't think this warning option is very useful. The bad thing is that these warnings cannot be eliminated by modifying the code. Therefore, I would recommend removing -Wconversion. Here is a patch to remove -Wconversion: --- tcl.m4.old Thu Jul 19 15:16:21 2001 +++ tcl.m4 Thu Jul 19 15:17:38 2001 @@ -605,7 +605,7 @@ CFLAGS_DEBUG=-g CFLAGS_OPTIMIZE=-O if test "$using_gcc" = "yes" ; then - CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int" + CFLAGS_WARNING="-Wall -Wno-implicit-int" else CFLAGS_WARNING="" fi - foundin changed to: "obsolete: 8.3.3"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "lloydlim"
- subsystem changed to: "53. Configuration and Build Tools"
- title changed to: "gcc warnings on FreeBSD"
- type changed to: "Bug"