🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.interviews
Article #1673

building shared library with g++

#1673
From: Michael Pichler
Date: Wed, 18 Jan 1995 18:18
56 lines
4017 bytes
Hello InterViews and GNU experts,

We are trying to build a shared version of the InterViews library
using g++ (2.6.3) on a SUN Solaris system (SUNOS 5.3).
Has anyone succeeded in doing this before?

For compiling the .o we call  g++ -fpic.

For linking we tried  gcc -z text -G, but get a lot of warnings like

Text relocation remains                       referenced
    against symbol                  offset      in file
atexit                              0x1c        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crt1.o
_fini                               0x24        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crt1.o
_fini                               0x28        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crt1.o
...
main                                0x5c        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crt1.o
exit                                0x64        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crt1.o
_exit                               0x6c        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crt1.o
__CTOR_LIST__                       0x8         /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crtbegin.o
__CTOR_LIST__                       0xc         /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/crtbegin.o
...
fprintf                             0x1c        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/libgcc.a(_eprintf.o)
fflush                              0x24        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/libgcc.a(_eprintf.o)
abort                               0x2c        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/libgcc.a(_eprintf.o)
free                                0x10        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/libgcc.a(_op_delete.o)
malloc                              0x10        /usr/local/lib/gcc-lib/sparc-sun-solaris2.3/2.6.3/libgcc.a(_op_new.o)
...
_GLOBAL_.I.__7DragBoxP7ivGlyphPC7ivColor 0x0            xdrag.o
ld: fatal: relocations remain against allocatable but non-writable sections


What does "relocation against non-writeable sections" mean?

Can these relocations be ignored (what is done with omitting -z text)
or are they harmful (e.g. when several programs are using the shared
library)? Are we doing something wrong?

Thanks in advance for any help.

                                        greetings,
--
                                        Michael Pichler

*--------------------------------------------------------------------*
DI Michael Pichler                         mpichler@iicm.tu-graz.ac.at
IICM                               ______
Graz University of Technology       / /        Tel: ++43-316-832551-36
Schieszstattgasse 4a               / / 95         Fax: ++43-316-824394
A-8010 Graz                   "reality inside"
Austria                             Austria -- in the heart of EU-rope
*--------------------------------------------------------------------*
  Hyper-G: the first second generation hypermedia information system
   For info on Hyper-G look in ftp://iicm.tu-graz.ac.at/pub/Hyper-G
 ED-MEDIA 95, Graz, Austria, June 18-21 1995, info: aace@virginia.edu
*--------------------------------------------------------------------*
Technical Details
Message-ID: <MPICHLER.95Jan18191808@merkur.tu-graz.ac.at>
Path: arc1-ca.pugleaf.net!nntp.gmd.de!Germany.EU.net!EU.net!Austria.EU.net!newsfeed.ACO.net!fstgds15.tu-graz.ac.at!iicm.tu-graz.ac.at!mpichler

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10ba33,9d3aa89d0bd6b46a,start
X-Google-Attributes: gid10ba33,public
X-Google-Thread: 101a2b,9d3aa89d0bd6b46a,start
X-Google-Attributes: gid101a2b,public
X-Google-ArrivalTime: 1995-01-18 10:18:08 PST
Path: arc1-ca.pugleaf.net!nntp.gmd.de!Germany.EU.net!EU.net!Austria.EU.net!newsfeed.ACO.net!fstgds15.tu-graz.ac.at!iicm.tu-graz.ac.at!mpichler
From: mpichler@iicm.tu-graz.ac.at (Michael Pichler)
Newsgroups: comp.windows.interviews,gnu.g++.help
Subject: building shared library with g++
Date: 18 Jan 1995 18:18:08 GMT
Organization: IICM, Graz University of Technology, Austria
Lines: 56
Distribution: world
Message-ID: <MPICHLER.95Jan18191808@merkur.tu-graz.ac.at>
NNTP-Posting-Host: fiicmsg02.tu-graz.ac.at