delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/10/20/18:26:36

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <43581990.2090108@users.sourceforge.net>
Date: Thu, 20 Oct 2005 17:26:24 -0500
From: "Yaakov S (Cygwin Ports)" <yselkowitz AT users DOT sourceforge DOT net>
User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: making .so files...
References: <Pine DOT LNX DOT 4 DOT 62 DOT 0510171807380 DOT 5147 AT ns DOT pyerotechnics DOT com>
In-Reply-To: <Pine.LNX.4.62.0510171807380.5147@ns.pyerotechnics.com>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Jason Pyeron wrote:
> I am working with the Asterisk application, it uses "modules" these are
> .so files which are linked against the main executable.
> 
> Asterisk will load a module, which may or may not make use of code
> exported by the main executable.

If I understand you correctly, then it's not so difficult; I've done it
myself with bmp, gedit, gthumb, liferea, and xmms.

I don't know Asterisk, but it doesn't appear to use autotools; this
makes things more difficult, especially if you want to make a portable
patch.

First, make sure that the asterisk executable is built *first*; you may
need to precede '.' to the SUBDIRS variable (i.e. SUBDIRS = . subdir1
subdir2 etc.)

Add the following to the asterisk executable's LDFLAGS:
'-Wl,--export-all-symbols,--out-implib,libasterisk.dll.a'

Then, add the following to all the modules LDFLAGS, specifying the
correct location: '-Wl,/path/to/libasterisk.dll.a'.

Of course, make sure that all requisite link libraries are specified in
LIBS for both the executable and the modules.

You'll still need to find some way of making all this dependent on
Cygwin in the Makefiles in order to make this portable.


Yaakov
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Cygwin)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDWBmQpiWmPGlmQSMRAmL3AKDsK1MMNFSvPA4GLcvC5NJ0ZqOpAACg+uWe
lS4WeqeOxgs5yMCDG/r1Dms=
=ievK
-----END PGP SIGNATURE-----

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019