[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#696506: marked as done (error on using a pch: had text segment at different address)



Your message dated Fri, 21 Aug 2015 13:43:08 +0000
with message-id <[🔎] E1ZSmb6-0004jv-26@franck.debian.org>
and subject line Bug#796274: Removed package(s) from unstable
has caused the Debian Bug report #696506,
regarding error on using a pch: had text segment at different address
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 owner@bugs.debian.org
immediately.)


-- 
696506: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=696506
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: src:gcc-4.6
Version: 4.6.3-11
Severity: serious



The gcc/g++-compiler has a bug that prevents a precompiled header (pch) from being used. It occurred on all ia64 Debian buildds while building the qt4-x11 package. Bug#696096 is already filed for that.
The log reads:

g++ -c -include .pch/release-shared/QtCore -Winvalid-pch -g -O2 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -I/usr/include/freetype2 -pthread -I/usr/include/glib-2.0 -I/usr/lib/ia64-linux-gnu/glib-2.0/include -O2 -fvisibility=hidden -fvisibility-inlines-hidden -Wall -W -D_REENTRANT -fPIC -DQT_SHARED -DQT_BUILD_CORE_LIB -DQT_NO_USING_NAMESPACE -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT3_SUPPORT -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -DELF_INTERPRETER=\"/lib/ld-linux-ia64.so.2\" -DQLIBRARYINFO_EPOCROOT -DQT_USE_ICU -DHB_EXPORT=Q_CORE_EXPORT -DQT_NO_DEBUG -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -I../../mkspecs/linux-g++ -I. -I../../include -I../../include/QtCore -I.rcc/release-shared -Iglobal -I../../tools/shared -I../3rdparty/harfbuzz/src -I../3rdparty/md5 -I../3rdparty/md4 -I.moc/release-shared -o .obj/release-shared/qlibraryinfo.o global/qlibraryinfo.cpp cc1plus: warning: ./.pch/release-shared/QtCore.gch/c: not for GNU C++ [enabled by default] cc1plus: warning: ./.pch/release-shared/QtCore.gch/c++: had text segment at different address [enabled by default]
cc1plus: error: one or more PCH files were found, but they were invalid
cc1plus: fatal error: .pch/release-shared/QtCore: No such file or directory
compilation terminated.


When you are using precompiled headers (pch), you invoke gcc/g++ at least twice. The first time to create the pch file - to write out the file. Second time to use the pch file - to read it in. Gcc expects that its binary image is always mapped at the same address in the virtual address space of the process. But when gcc's image is mapped to another address when reading in the pch than it was on writing out the pch, it reports the seen message.

The source code file src/gcc/c-family/c-pch.c of the src:gcc-4.6 gives more details:


/* Check the PCH file called NAME, open on FD, to see if it can be
   used in this compilation.  Return 1 if valid, 0 if the file can't
   be used now but might be if it's seen later in the compilation, and
   2 if this file could never be used in the compilation.  */

int
c_common_valid_pch (cpp_reader *pfile, const char *name, int fd)
{
...
  /* If the text segment was not loaded at the same address as it was
     when the PCH file was created, function pointers loaded from the
     PCH will not be valid.  We could in theory remap all the function
     pointers, but no support for that exists at present.
     Since we have the same executable, it should only be necessary to
     check one function.  */
  if (v.pch_init != &pch_init)
    {
      if (cpp_get_options (pfile)->warn_invalid_pch)
	cpp_error (pfile, CPP_DL_WARNING,
		   "%s: had text segment at different address", name);
      return 2;
    }

...
}


It is experienced on ia64 here, but the bug affects any arch.

Stephan

--- End Message ---
--- Begin Message ---
Version: 4.6.4-7+rm

Dear submitter,

as the package gcc-4.6 has just been removed from the Debian archive
unstable we hereby close the associated bug reports.  We are sorry
that we couldn't deal with your issue properly.

For details on the removal, please see https://bugs.debian.org/796274

The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.

This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing
ftpmaster@ftp-master.debian.org.

Debian distribution maintenance software
pp.
Scott Kitterman (the ftpmaster behind the curtain)

--- End Message ---

Reply to: