public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/20575] New: g++ 3.3.3 compiled program segmention fault when run on HPUX system not having gcc
@ 2005-03-21 10:19 nileshrg at hotmail dot com
  2005-03-22  6:12 ` [Bug libstdc++/20575] " nileshrg at hotmail dot com
  2005-03-24  1:17 ` pcarlini at suse dot de
  0 siblings, 2 replies; 3+ messages in thread
From: nileshrg at hotmail dot com @ 2005-03-21 10:19 UTC (permalink / raw)
  To: gcc-bugs

Problem Statement:
==================
When a simple C++ program containg one "cout", is compoled with following 
command. It runs fine on system where gcc is installed but not on different 
HPUX system where no GCC component are present. libstdc++.sl.5 and libgcc_s.sl 
are also copied along with program so that "ldd program" resolves fine.

Compilation command:
====================
g++ -Wall -o mtest -lstdc++ test.cpp 

System options, gcc configuration options, and Version
g++ -v:
===============
Reading specs from /usr/local/lib/gcc-lib/hppa2.0w-hp-hpux11.11/3.3.3/specs
Configured with: /scratch/zack/pkgbuild/3.3.1/hpux-11/gcc-3.3.3/configure --
enable-languages=c,c++ --enable-threads=posix --disable-nls --with-gnu-as --
without-gnu-ld --with-as=/usr/local/bin/as --prefix=/usr/local
Thread model: posix
gcc version 3.3.3

uname -a:
=========
HP-UX hpsms02 B.11.11 U 9000/800 2298023925 unlimited-user license

Compiler output:
=================
No outpput. Programm compiled successfully.

PROGRAM FILE:
=============
#include<iostream> 
#include<string> 
using namespace std; 
int main() 
{ 
        string str("test"); 
        cout << "test string " << str << endl; 


} 

CORE:
======
hpsms05$gdb mtest core
HP gdb 3.3 for PA-RISC 1.1 or 2.0 (narrow), HP-UX 11.00.
Copyright 1986 - 2001 Free Software Foundation, Inc.
Hewlett-Packard Wildebeest 3.3 (based on GDB) is covered by the
GNU General Public License. Type "show copying" to see the conditions to
change it and/or distribute copies. Type "show warranty" for warranty/support.
..Autoloading size threshold (in megabytes) of shared library symbols is 804.
/home/ngujarat/.gdbinit:2: Error in sourced command file:
No symbol table is loaded.  Use the "file" command.

Core was generated by `mtest'.
Program terminated with signal 11, Segmentation fault.

warning: The shared libraries were not privately mapped; setting a
breakpoint in a shared library will not work until you rerun the program.


warning: Can't find file /opt/graphics/OpenGL/lib/libogltls.sl referenced in 
dld_list.

/opt/graphics/OpenGL/lib/libogltls.sl: No such file or directory.
#0  0xc5c16500 in _ZNSo6sentryC1ERSo+0x20 () from /usr/local/lib/libstdc++.sl.5
(gdb) bt
#0  0xc5c16500 in _ZNSo6sentryC1ERSo+0x20 () from /usr/local/lib/libstdc++.sl.5
#1  0xc5c16bec in _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc+0xec 
()
   from /usr/local/lib/libstdc++.sl.5
#2  0x2ebc in main () at mtest.cpp:8
(gdb) 




Thanks.

-- 
           Summary: g++ 3.3.3 compiled program segmention fault when run on
                    HPUX system not having gcc
           Product: gcc
           Version: 3.3.3
            Status: UNCONFIRMED
          Severity: critical
          Priority: P1
         Component: libstdc++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: nileshrg at hotmail dot com
                CC: gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20575


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug libstdc++/20575] g++ 3.3.3 compiled program segmention fault when run on HPUX system not having gcc
  2005-03-21 10:19 [Bug libstdc++/20575] New: g++ 3.3.3 compiled program segmention fault when run on HPUX system not having gcc nileshrg at hotmail dot com
@ 2005-03-22  6:12 ` nileshrg at hotmail dot com
  2005-03-24  1:17 ` pcarlini at suse dot de
  1 sibling, 0 replies; 3+ messages in thread
From: nileshrg at hotmail dot com @ 2005-03-22  6:12 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From nileshrg at hotmail dot com  2005-03-22 06:11 -------
Hi GNU GCC developer,

To keep this updated, i resolved this bug myself, by applying following 
resolution.

I first applied the HPUX 11.11 Quality Pack (Base and App) 412 , latest 
available as on March 22nd, 2005. This did not resovle the program crash, but 
then applying the patch for ld and linker tools patch , this crash with core 
got resolved completely. And program works fine now.
PHSS_30970 (s700_800 11.11 ld(1) and linker tools cumulative patch)

Latest patches can be found at HP's website.
http://www2.itrc.hp.com/service/patch/mainPage.do

Regards,
Nilesh Gujarathi

(In reply to comment #0)
> Problem Statement:
> ==================
> When a simple C++ program containg one "cout", is compoled with following 
> command. It runs fine on system where gcc is installed but not on different 
> HPUX system where no GCC component are present. libstdc++.sl.5 and 
libgcc_s.sl 
> are also copied along with program so that "ldd program" resolves fine.
> Compilation command:
> ====================
> g++ -Wall -o mtest -lstdc++ test.cpp 
> System options, gcc configuration options, and Version
> g++ -v:
> ===============
> Reading specs from /usr/local/lib/gcc-lib/hppa2.0w-hp-hpux11.11/3.3.3/specs
> Configured with: /scratch/zack/pkgbuild/3.3.1/hpux-11/gcc-3.3.3/configure --
> enable-languages=c,c++ --enable-threads=posix --disable-nls --with-gnu-as --
> without-gnu-ld --with-as=/usr/local/bin/as --prefix=/usr/local
> Thread model: posix
> gcc version 3.3.3
> uname -a:
> =========
> HP-UX hpsms02 B.11.11 U 9000/800 2298023925 unlimited-user license
> Compiler output:
> =================
> No outpput. Programm compiled successfully.
> PROGRAM FILE:
> =============
> #include<iostream> 
> #include<string> 
> using namespace std; 
> int main() 
> { 
>         string str("test"); 
>         cout << "test string " << str << endl; 
> } 
> CORE:
> ======
> hpsms05$gdb mtest core
> HP gdb 3.3 for PA-RISC 1.1 or 2.0 (narrow), HP-UX 11.00.
> Copyright 1986 - 2001 Free Software Foundation, Inc.
> Hewlett-Packard Wildebeest 3.3 (based on GDB) is covered by the
> GNU General Public License. Type "show copying" to see the conditions to
> change it and/or distribute copies. Type "show warranty" for warranty/support.
> ..Autoloading size threshold (in megabytes) of shared library symbols is 804.
> /home/ngujarat/.gdbinit:2: Error in sourced command file:
> No symbol table is loaded.  Use the "file" command.
> Core was generated by `mtest'.
> Program terminated with signal 11, Segmentation fault.
> warning: The shared libraries were not privately mapped; setting a
> breakpoint in a shared library will not work until you rerun the program.
> warning: Can't find file /opt/graphics/OpenGL/lib/libogltls.sl referenced in 
> dld_list.
> /opt/graphics/OpenGL/lib/libogltls.sl: No such file or directory.
> #0  0xc5c16500 in _ZNSo6sentryC1ERSo+0x20 () 
from /usr/local/lib/libstdc++.sl.5
> (gdb) bt
> #0  0xc5c16500 in _ZNSo6sentryC1ERSo+0x20 () 
from /usr/local/lib/libstdc++.sl.5
> #1  0xc5c16bec in 
_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc+0xec 
> ()
>    from /usr/local/lib/libstdc++.sl.5
> #2  0x2ebc in main () at mtest.cpp:8
> (gdb) 
> Thanks.



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20575


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug libstdc++/20575] g++ 3.3.3 compiled program segmention fault when run on HPUX system not having gcc
  2005-03-21 10:19 [Bug libstdc++/20575] New: g++ 3.3.3 compiled program segmention fault when run on HPUX system not having gcc nileshrg at hotmail dot com
  2005-03-22  6:12 ` [Bug libstdc++/20575] " nileshrg at hotmail dot com
@ 2005-03-24  1:17 ` pcarlini at suse dot de
  1 sibling, 0 replies; 3+ messages in thread
From: pcarlini at suse dot de @ 2005-03-24  1:17 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pcarlini at suse dot de  2005-03-24 01:17 -------
Ok, thanks. Then closing as not a libstdc++ bug.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20575


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-03-24  1:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-03-21 10:19 [Bug libstdc++/20575] New: g++ 3.3.3 compiled program segmention fault when run on HPUX system not having gcc nileshrg at hotmail dot com
2005-03-22  6:12 ` [Bug libstdc++/20575] " nileshrg at hotmail dot com
2005-03-24  1:17 ` pcarlini at suse dot de

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).