delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/07/30/13:44:07

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00
X-Spam-Check-By: sourceware.org
X-Spam-Score: -75.792
Message-ID: <4A71DBC8.4070807@sh.cvut.cz>
Date: Thu, 30 Jul 2009 19:43:36 +0200
From: =?UTF-8?B?VsOhY2xhdiBIYWlzbWFu?= <v DOT haisman AT sh DOT cvut DOT cz>
User-Agent: Thunderbird 2.0.0.22 (Windows/20090605)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Creation of a shared module (gcc -shared) , undefined references
References: <4A71A396 DOT 8060300 AT bull DOT net>
In-Reply-To: <4A71A396.8060300@bull.net>
X-IsSubscribed: yes
Reply-To: cygwin AT cygwin DOT com
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
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

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Martine Carannante wrote, On 30.7.2009 15:43:
> Hi
> 
> I try to port on CYGWIN an open source which runs correctly  on Linux.
> In this open source, a shared module (linked with option -shared) is
> created and after it's loaded by the main program with lt_dlopen()
> function.
> 
> On CYGWIN, I have a problem when I create the module (gcc option
> -shared). I have always some undefined references to functions which
> belongs to the main program. On Linux it's not a problem, there are no
> errors.
> I try to add the option -Wl,-allow-shlib-undefined. I have always the
> problem.
> 
> I don't know what to do. Are there other options to add to the gcc
> command ?I tried several..or do I have to modify the source code of the
> module?
> I'm not very familiar with shared modules.
Basically, you will have to fix the source of the application so that it does
not try to provide symbols for the modules from the main executable. Windows
DLLs cannot have undefined symbols like Linux in its shared objects.

- --
VH
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)

iEYEAREIAAYFAkpx28gACgkQr2CghdezFMl+SwCdFFXvm9DAXyuma25eCMP4Os3I
5dkAn0RMNF1ydVNIxGP2XOlxDKCSNPTP
=u5pm
-----END PGP SIGNATURE-----

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

- Raw text -


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