Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
From: kiddg@sealcorp.com.au (Glen Kidd)
Subject: Problems creating executables using shared libraries.
Date: 1996/09/03	[thread overview]
Message-ID: <50gc30$eg2@news.mel.aone.net.au> (raw)


Hiya All

I am having trouble with creating /using shared libraries. Everything
seems to compile OK, I can produce shared objects, linking these
shared objects to another object to produce an executable works. When
I run the executable, it loads the symbols OK, but the program always
cores. 

I know the program works, 'cause it works alright statically linked.
so something in how I am generating or using the shared objects is
flawed.

The system I am using is a DEC Alpha running OSF1 V3.2 148. The
compiler is gnu g++ v2.7.2

To generate objects to place into the shared object file I am using:
	g++ -c -shared filename.c
I create an 'ar' achive out of all these objects.
To generate the shared object:
	g++ -o libcommon.so -shared -no_archive -all common.a 
	    -none libg++.a libstdc++.a
To  create the executable:
	g++ -c -shared myprog.c
	g++ -o myprog myprog.o libcommon.so 
No step complains, the executable is generated, but on execution a
core always results - I am unable to determine why!

Any help would be greatly appreciated.

...Ciao for now

...Glen Kidd





                 reply	other threads:[~1996-09-03  4:00 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox