Created attachment 24823 [details] Header file with bom gcc -v: Using built-in specs. Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 4.4.4-14ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.4 --enable-shared --enable-multiarch --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc --disable-werror --with-arch-32=i686 --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.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5) Failed attempt: g++ -x c++-header -c stable.h -o stable.gch/c++ g++ -include ./stable 1.cpp Output: In file included from stable.h:1, from 1.cpp:1: 1.h:4: error: redefinition of ‘template<class A, class B> B convert(A)’ 1.h:4: error: ‘template<class A, class B> B convert(A)’ previously declared here Successful: g++ 1.cpp Empty output.
Created attachment 24824 [details] Main file
Created attachment 24825 [details] Precompiled header
Bug 56549 has better description of the error. *** This bug has been marked as a duplicate of bug 56549 ***