Your message dated Mon, 28 Mar 2011 18:02:58 +0000
with message-id <e1q4gmi-0005jd...@franck.debian.org>
and subject line Bug#617321: fixed in gcc-defaults 1.100
has caused the Debian Bug report #617321,
regarding gcc: c99-gcc with -ansi option should be handled as a conflict
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
617321: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=617321
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: gcc
Version: 4:4.4.5-1
Severity: minor
Tags: patch


The c99-gcc wrapper script detects conflicting -std=* options and flags them as
errors before invoking gcc.  The same logic should extend to the -ansi option,
which is identical to -std=c89; otherwise, the -ansi option overrides -std=c99
and turns the compilation into ISO C90 instead of ISO C99.

Example session compiling the attached program with current c99-gcc:

$ c99 --version
gcc (Debian 4.4.5-8) 4.4.5
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$ c99 -Wall -D_XOPEN_SOURCE=600 democ99.c -lm
$ c99 -std=c89 -Wall -D_XOPEN_SOURCE=600 democ99.c -lm
c99 called with non ANSI/ISO C option -std=c89
$ c99 -ansi -Wall -D_XOPEN_SOURCE=600 democ99.c -lm
democ99.c:24: error: expected identifier or ‘(’ before ‘/’ token
democ99.c:27: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before 
‘static’
democ99.c: In function ‘main’:
democ99.c:36: error: ‘zarray’ undeclared (first use in this function)
democ99.c:36: error: (Each undeclared identifier is reported only once
democ99.c:36: error: for each function it appears in.)
democ99.c:38: error: ‘for’ loop initial declarations are only allowed in C99 
mode
democ99.c:38: note: use option -std=c99 or -std=gnu99 to compile your code
democ99.c:40: error: redefinition of ‘i’
democ99.c:38: note: previous definition of ‘i’ was here
democ99.c:40: error: ‘for’ loop initial declarations are only allowed in C99 
mode
democ99.c:40: warning: implicit declaration of function ‘zprint’


The included patch against the c99 script gives the desired behavior:

$ c99 -ansi -Wall -D_XOPEN_SOURCE=600 democ99.c -lm
c99 called with non ANSI/ISO C option -ansi

-- System Information:
Debian Release: 6.0
  APT prefers proposed-updates
  APT policy: (500, 'proposed-updates'), (500, 'stable'), (101, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages gcc depends on:
ii  cpp                           4:4.4.5-1  The GNU C preprocessor (cpp)
ii  gcc-4.4                       4.4.5-8    The GNU C compiler

Versions of packages gcc recommends:
ii  libc6-dev [libc-dev]          2.11.2-10  Embedded GNU C Library: Developmen

Versions of packages gcc suggests:
pn  autoconf                  <none>         (no description available)
pn  automake1.9               <none>         (no description available)
ii  bison                     1:2.4.1.dfsg-3 A parser generator that is compati
ii  flex                      2.5.35-10      A fast lexical analyzer generator.
ii  gcc-doc                   5:3            documentation for the GNU compiler
ii  gcc-multilib              4:4.4.5-1      The GNU C compiler (multilib files
ii  gdb                       7.0.1-2+b1     The GNU Debugger
pn  libtool                   <none>         (no description available)
ii  make                      3.81-8         An utility for Directing compilati
ii  manpages-dev              3.27-1         Manual pages about using GNU/Linux

-- no debconf information
/* democ99.c - Demonstration program to separate C89 from C99
 *
 * Copyright (C) 2011 Mike Miller
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#include <math.h>
#include <stdlib.h>
#include <stdio.h>
#include <complex.h>
#include <stdbool.h>

// File-scoped complex value array to be initialized at run-time.
static long double complex *zarray;

inline static void zprint(long double complex z, FILE *restrict stream)
{
	fprintf(stream, "(%Lf,%Lf)\n", creall(z), cimagl(z));
}

int main(int argc, char *argv[])
{
	bool ok = true;

	zarray = malloc(16 * sizeof(long double complex));

	for (int i = 0; i < 16; i++) zarray[i] = cexpl(I * M_PI * i / 8);

	for (int i = 0; i < 16; i++) zprint(zarray[i], stdout);

	free(zarray);

	exit(ok ? EXIT_SUCCESS : EXIT_FAILURE);
}
Index: c99
===================================================================
--- c99	(revision 5085)
+++ c99	(working copy)
@@ -14,7 +14,7 @@
 	-std=c9[9x]|-std=iso9899:199[9x])
 	    extra_flag=
 	    ;;
-	-std=*)
+	-std=*|-ansi)
 	    echo >&2 "`basename $0` called with non ANSI/ISO C option $i"
 	    exit 1
 	    ;;

--- End Message ---
--- Begin Message ---
Source: gcc-defaults
Source-Version: 1.100

We believe that the bug you reported is fixed in the latest version of
gcc-defaults, which is due to be installed in the Debian FTP archive:

cpp_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/cpp_4.5.2-3_amd64.deb
g++-multilib_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/g++-multilib_4.5.2-3_amd64.deb
g++_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/g++_4.5.2-3_amd64.deb
gcc-defaults_1.100.dsc
  to main/g/gcc-defaults/gcc-defaults_1.100.dsc
gcc-defaults_1.100.tar.gz
  to main/g/gcc-defaults/gcc-defaults_1.100.tar.gz
gcc-multilib_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gcc-multilib_4.5.2-3_amd64.deb
gcc_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gcc_4.5.2-3_amd64.deb
gccgo-multilib_4.6.0-1_amd64.deb
  to main/g/gcc-defaults/gccgo-multilib_4.6.0-1_amd64.deb
gccgo_4.6.0-1_amd64.deb
  to main/g/gcc-defaults/gccgo_4.6.0-1_amd64.deb
gcj-jdk_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/gcj-jdk_4.4.5-5_amd64.deb
gcj-jre-headless_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/gcj-jre-headless_4.4.5-5_amd64.deb
gcj-jre_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/gcj-jre_4.4.5-5_amd64.deb
gcj_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/gcj_4.4.5-5_amd64.deb
gdc_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/gdc_4.4.5-5_amd64.deb
gfortran-multilib_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gfortran-multilib_4.5.2-3_amd64.deb
gfortran_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gfortran_4.5.2-3_amd64.deb
gij_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/gij_4.4.5-5_amd64.deb
gobjc++-multilib_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gobjc++-multilib_4.5.2-3_amd64.deb
gobjc++_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gobjc++_4.5.2-3_amd64.deb
gobjc-multilib_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gobjc-multilib_4.5.2-3_amd64.deb
gobjc_4.5.2-3_amd64.deb
  to main/g/gcc-defaults/gobjc_4.5.2-3_amd64.deb
libgcj-bc_4.4.5-5_amd64.deb
  to main/g/gcc-defaults/libgcj-bc_4.4.5-5_amd64.deb
libgcj-common_4.4.5-5_all.deb
  to main/g/gcc-defaults/libgcj-common_4.4.5-5_all.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 617...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Matthias Klose <d...@debian.org> (supplier of updated gcc-defaults package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmas...@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Sun, 27 Mar 2011 13:05:18 +0200
Source: gcc-defaults
Binary: cpp g++ g++-multilib gobjc gobjc-multilib gobjc++ gobjc++-multilib 
gfortran gfortran-multilib gccgo gccgo-multilib libgcj-common gcj gij libgcj-bc 
gcj-jdk gcj-jre-headless gcj-jre gcc gcc-multilib gdc gcc-spu g++-spu 
gfortran-spu
Architecture: source all amd64
Version: 1.100
Distribution: unstable
Urgency: low
Maintainer: Debian GCC Maintainers <debian-gcc@lists.debian.org>
Changed-By: Matthias Klose <d...@debian.org>
Description: 
 cpp        - The GNU C preprocessor (cpp)
 g++        - The GNU C++ compiler
 g++-multilib - The GNU C++ compiler (multilib files)
 g++-spu    - SPU cross-compiler (C++ compiler)
 gcc        - The GNU C compiler
 gcc-multilib - The GNU C compiler (multilib files)
 gcc-spu    - SPU cross-compiler (preprocessor and C compiler)
 gccgo      - The GNU Go compiler
 gccgo-multilib - The GNU Go compiler (multilib files)
 gcj        - The GNU Java compiler (transitional package)
 gcj-jdk    - gcj and classpath development tools for Java(TM)
 gcj-jre    - Java runtime environment using GIJ/classpath
 gcj-jre-headless - Java runtime environment using GIJ/classpath (headless 
version)
 gdc        - The D compiler
 gfortran   - The GNU Fortran 95 compiler
 gfortran-multilib - The GNU Fortran 95 compiler (multilib files)
 gfortran-spu - SPU cross-compiler (Fortran compiler)
 gij        - The GNU Java bytecode interpreter (transitional package)
 gobjc      - The GNU Objective-C compiler
 gobjc++    - The GNU Objective-C++ compiler
 gobjc++-multilib - The GNU Objective-C++ compiler (multilib files)
 gobjc-multilib - The GNU Objective-C compiler (multilib files)
 libgcj-bc  - Link time only library for use with gcj
 libgcj-common - Java runtime library (common files)
Closes: 617321 618718
Changes: 
 gcc-defaults (1.100) unstable; urgency=low
 .
   * c99: Do not accept -ansi option (Mike Miller). Closes: #617321.
   * c99: Clarify c99 error message incorrectly refering to ANSI C
     (Mike Miller). Closes: #618718.
   * On hppa, default gcc, g++, gobjc, gobjc++, gfortran to GCC-4.5.
   * Build gccgo and gccgo-multilib packages.
Checksums-Sha1: 
 d89a55508b5efe0b8eaa63cb8fa9119faaa68d00 1387 gcc-defaults_1.100.dsc
 3cb1f158b01cebab4fb3828e2523681038fdfb7d 72265 gcc-defaults_1.100.tar.gz
 1dd88252e535c21c65390b037e1de46cdeac804f 121714 libgcj-common_4.4.5-5_all.deb
 d80ec0093fd672fcac6dfd616bca889c5d213509 15244 cpp_4.5.2-3_amd64.deb
 14398658833f735d9f3130b5efcf2cc02e413760 4988 gcc_4.5.2-3_amd64.deb
 d47ea1b23bf803ec715f71cdb64100d67fec850a 818 gcc-multilib_4.5.2-3_amd64.deb
 42d52222fc40a934a7fd98d12e011cd0396f9129 15286 gdc_4.4.5-5_amd64.deb
 c00552d85d1935e2528764dd49d7ac63874ea39b 1368 g++_4.5.2-3_amd64.deb
 0cf52e91bbc9a4a4046080d7161bbb3940071143 824 g++-multilib_4.5.2-3_amd64.deb
 1a85a8c685cdf5ad65f0d38fc3d0564376fb3b04 848 gobjc_4.5.2-3_amd64.deb
 d05c28decc084b1e9f1ef2fc416014e5fda19fa4 840 gobjc-multilib_4.5.2-3_amd64.deb
 4a111f5f1aa8f1d0f10c7f02d505715448845376 870 gobjc++_4.5.2-3_amd64.deb
 19a86708238bd7fe50f9f0e1d459b4313f77fcb3 844 gobjc++-multilib_4.5.2-3_amd64.deb
 e05ec1c4a39d46f65f97014e339e1aff317f3ac3 1128 gfortran_4.5.2-3_amd64.deb
 aa591f9b8355c267d119d262adf999e1210e076c 844 
gfortran-multilib_4.5.2-3_amd64.deb
 4d0be8eb1f6d50b34dc3179ded8385be668d5a1b 910 gccgo_4.6.0-1_amd64.deb
 bdfe17075a75a66bf180bbea03932a39c0136d52 866 gccgo-multilib_4.6.0-1_amd64.deb
 30939e91626ededbc9fa8b890bf771599f422d3f 870 gcj_4.4.5-5_amd64.deb
 a4ca572911457b03f9ae43fe3b341f56834d91a1 1044 gij_4.4.5-5_amd64.deb
 f52128c90b862d5c40a20cb92980a9b2ed091409 1126 libgcj-bc_4.4.5-5_amd64.deb
 067d6d797bbdbbf425ecde2d4fc3c5ae6b4eaebc 1472 
gcj-jre-headless_4.4.5-5_amd64.deb
 7b740a52f442c87cb5d5bc601415bc9402a16394 1018 gcj-jre_4.4.5-5_amd64.deb
 4328f2385b58475fc2c835cf695373c0ac3f4f1c 6212 gcj-jdk_4.4.5-5_amd64.deb
Checksums-Sha256: 
 a3cc3a1b03848063278163ce5f6081caec94236964c2377b8c0cea49d7a944b4 1387 
gcc-defaults_1.100.dsc
 c3e4fd998e08b154005b209936f0a6c0cabdd1f52e048bb68d2e6a0511afb0a4 72265 
gcc-defaults_1.100.tar.gz
 237548b0922e217c5068b578d297efdec9437d00c535a037681e9cd7d24708d7 121714 
libgcj-common_4.4.5-5_all.deb
 00648c3ed684a9bdab34403616fe11618c7dd93ba81723fc49b098218a136b10 15244 
cpp_4.5.2-3_amd64.deb
 9b069617f2b3adb631832e4adf9d7d3cfeb53d29cc83505bfa686e8c3afc015e 4988 
gcc_4.5.2-3_amd64.deb
 f3e02ec9b504433dda0f11633ae1d9c0514952572fb6d302c693b824585c33ad 818 
gcc-multilib_4.5.2-3_amd64.deb
 9266acb626da983700a0f834b2a3967701b0f9c17c02c745413869fdcdea28ff 15286 
gdc_4.4.5-5_amd64.deb
 01b0cc746a320aedfba24f332a48fb24f8008bfb4d176e7f5f1251e56ef308fa 1368 
g++_4.5.2-3_amd64.deb
 586816ef03567a520492b19c9d731e1d7825832041b2100cf9005d2aebd70905 824 
g++-multilib_4.5.2-3_amd64.deb
 b462f532d97dcdb487382ebae07dfeb1b334d3b7165ad857ccdf3b65c131911e 848 
gobjc_4.5.2-3_amd64.deb
 8936a9798de95ad8836a1e34e7913e86a4548dd43f5df1e314959b24d9f523de 840 
gobjc-multilib_4.5.2-3_amd64.deb
 4257aa9251a2b7e5ca4c905a04f0cf6f346ab3302802b2055eaf1fa69e3666ec 870 
gobjc++_4.5.2-3_amd64.deb
 969aa12b0df2c27850f6b99e8c662115f466377536c6dd72758e94578affbec9 844 
gobjc++-multilib_4.5.2-3_amd64.deb
 4f625bb81407bf4440dc40efefbe005cf6c630cf43b8e818ff953c70f4e45997 1128 
gfortran_4.5.2-3_amd64.deb
 8ff1c0e71a4d19a570b1071be8a257f9fec37e8ec305b5ba701b195ab86a7980 844 
gfortran-multilib_4.5.2-3_amd64.deb
 a0edbb78b415e2554a0c08c02147986298ad73872853da69f7881a0fc46741ab 910 
gccgo_4.6.0-1_amd64.deb
 49f33540a881235fc81af3d1d1f800b858fbaf3870c1c1c54a96a26a6d088809 866 
gccgo-multilib_4.6.0-1_amd64.deb
 f7a040fa0f65a616dcf7d6b90b5648f91b149332662f02ca20b9e6399db71b6e 870 
gcj_4.4.5-5_amd64.deb
 2c1bc378c5ae37e2e375750f80765f14ba640c67e45fa5644de2d68ffd235dd6 1044 
gij_4.4.5-5_amd64.deb
 97ca31d78ca545b026a1bc9e5879597928be6ec1ff596007e565820efa9af06b 1126 
libgcj-bc_4.4.5-5_amd64.deb
 acfa96ac0bb71a1f0a31ee22ac7b47ba6ab0d92a1ed8d3447c6aa96109537771 1472 
gcj-jre-headless_4.4.5-5_amd64.deb
 26f6caef82738972d7dd23c7d0641a036c77614ead951e380e8e6d61e081d8cb 1018 
gcj-jre_4.4.5-5_amd64.deb
 6ba1723aca8374232ac74ba6aaf2086e888bbbb49dad427f3a85e1078e6c2c9a 6212 
gcj-jdk_4.4.5-5_amd64.deb
Files: 
 d7a56de1d02e55da36344deefae6b7a4 1387 devel standard gcc-defaults_1.100.dsc
 c55d9f2e1b01e3ed4b30bf524e0698d4 72265 devel standard gcc-defaults_1.100.tar.gz
 b1a61919b19fba688c87384e6532ee22 121714 java optional 
libgcj-common_4.4.5-5_all.deb
 1da7cffbb36c0822d37cb7a68de6923c 15244 interpreters optional 
cpp_4.5.2-3_amd64.deb
 00561aba873e4b02901f4adb9f7607f5 4988 devel optional gcc_4.5.2-3_amd64.deb
 a864d47194dd5da66081d7d7436c2c98 818 devel optional 
gcc-multilib_4.5.2-3_amd64.deb
 11efdfbc3aa0b7bc527750c77c547177 15286 devel optional gdc_4.4.5-5_amd64.deb
 07052f6ac5fe5e75b022c0c630803911 1368 devel optional g++_4.5.2-3_amd64.deb
 6212f51f67a4607ad4c6d719b869dd78 824 devel optional 
g++-multilib_4.5.2-3_amd64.deb
 5a67bac1ca39ca27e34aa65ff5a41ebf 848 devel optional gobjc_4.5.2-3_amd64.deb
 f675d9222e38c01598c4c36acbe2ac4b 840 devel optional 
gobjc-multilib_4.5.2-3_amd64.deb
 c57cd81aa113016523cc38b4e976aaea 870 devel optional gobjc++_4.5.2-3_amd64.deb
 e0f94bcf84a11672dd839b70cc3bf73e 844 devel optional 
gobjc++-multilib_4.5.2-3_amd64.deb
 b651d115df728486744bff0cbd2df7ee 1128 devel optional gfortran_4.5.2-3_amd64.deb
 7b26056a761b36bf370efca17d02b858 844 devel optional 
gfortran-multilib_4.5.2-3_amd64.deb
 89f8df2f56ae1d35dfa62bf35247c3c9 910 devel optional gccgo_4.6.0-1_amd64.deb
 59de6a838fc1d2e804d77056d0be4f10 866 devel optional 
gccgo-multilib_4.6.0-1_amd64.deb
 d05dca5842f9b5cc9e709dcef12336e6 870 java optional gcj_4.4.5-5_amd64.deb
 114cb989c8f81b5612484ab524324208 1044 java optional gij_4.4.5-5_amd64.deb
 693b543d7d4f5b39bcc0b5d76050e56e 1126 java optional libgcj-bc_4.4.5-5_amd64.deb
 cdfece2ab0506bbaf8202b56b135aa38 1472 java optional 
gcj-jre-headless_4.4.5-5_amd64.deb
 1fff86e2f8c03229e49d03a97578ee06 1018 java optional gcj-jre_4.4.5-5_amd64.deb
 669bfd615934ebff4bb0b6c77d598937 6212 java optional gcj-jdk_4.4.5-5_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)

iEYEARECAAYFAk2PItYACgkQStlRaw+TLJzHzgCeK2OCTs7ekMcQYNVnT/nP+5IC
ycoAniZ3aLZOMgYh2UEXAcARz+1nVyW7
=9M/h
-----END PGP SIGNATURE-----



--- End Message ---

Reply via email to