← Back to team overview

touch-packages team mailing list archive

[Bug 1401836] Re: -Wno-format ignored in Ubuntu 14.04 release

 

This bug is a duplicate of bug 1317305, which has already been verified
successfully. Marking this bug as verified as well.

** Tags removed: verification-needed
** Tags added: verification-done

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to gcc-4.8 in Ubuntu.
https://bugs.launchpad.net/bugs/1401836

Title:
  -Wno-format ignored in Ubuntu 14.04 release

Status in gcc-4.8 package in Ubuntu:
  Confirmed

Bug description:
  lsb_release -rd
  Description:    Ubuntu 14.04.1 LTS
  Release:        14.04

  gcc --version
  gcc (Ubuntu 4.8.2-19ubuntu1) 4.8.2
  ...

  Trying to run a recent glibc testsuite (from glibc trunk) results in
  testsuite errors because the compiler is overriding the -Wno-format
  option on the command line.  Running the compiler with -v shows that
  it is appending an additional -Wformat after the user option and that
  there is no obvious way to override this behaviour.  This is a bug.

  #include <stdio.h>

  int f()
  {
    int n;
    return scanf ("%llllld", &n);
  }

  The above testcase should compile when compiled with -Wall -Werror
  -Wno-format, but instead generates errors for the unrecognized format
  specifier (note that this is a deliberate part of the test).

  gcc -v -Wall -Werror -Wno-format /tmp/test.c -c -o /tmp/test.o
  Using built-in specs.
  COLLECT_GCC=gcc
  Target: x86_64-linux-gnu
  Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.8.2-19ubuntu1' --with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.8 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.8 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libmudflap --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64 --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.8-amd64 --with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
  Thread model: posix
  gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1) 
  COLLECT_GCC_OPTIONS='-v' '-Wall' '-Werror' '-Wformat=0' '-c' '-o' '/tmp/test.o' '-mtune=generic' '-march=x86-64'
   /usr/lib/gcc/x86_64-linux-gnu/4.8/cc1 -quiet -v -imultiarch x86_64-linux-gnu /tmp/test.c -quiet -dumpbase test.c -mtune=generic -march=x86-64 -auxbase-strip /tmp/test.o -Wall -Werror -Wformat=0 -version -fstack-protector -Wformat -Wformat-security -o /tmp/ccGaCxtC.s
  GNU C (Ubuntu 4.8.2-19ubuntu1) version 4.8.2 (x86_64-linux-gnu)
          compiled by GNU C version 4.8.2, GMP version 5.1.3, MPFR version 3.1.2-p3, MPC version 1.0.1
  GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
  ignoring nonexistent directory "/usr/local/include/x86_64-linux-gnu"
  ignoring nonexistent directory "/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../x86_64-linux-gnu/include"
  #include "..." search starts here:
  #include <...> search starts here:
   /usr/lib/gcc/x86_64-linux-gnu/4.8/include
   /usr/local/include
   /usr/lib/gcc/x86_64-linux-gnu/4.8/include-fixed
   /usr/include/x86_64-linux-gnu
   /usr/include
  End of search list.
  GNU C (Ubuntu 4.8.2-19ubuntu1) version 4.8.2 (x86_64-linux-gnu)
          compiled by GNU C version 4.8.2, GMP version 5.1.3, MPFR version 3.1.2-p3, MPC version 1.0.1
  GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
  Compiler executable checksum: dc75e0628c9356affcec059d0c81cc01
  /tmp/test.c: In function ‘f’:
  /tmp/test.c:6:3: error: unknown conversion type character ‘l’ in format [-Werror=format=]
     return scanf ("%llllld", &n);
     ^
  /tmp/test.c:6:3: error: too many arguments for format [-Werror=format-extra-args]
  cc1: all warnings being treated as errors

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gcc-4.8/+bug/1401836/+subscriptions


References