delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/02/12/21:49:11

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/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: <402C3B62.6000902@cwilson.fastmail.fm>
Date: Thu, 12 Feb 2004 21:50:10 -0500
From: Charles Wilson <cygwin AT cwilson DOT fastmail DOT fm>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030630
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Building dll's and executables in same package
References: <402C2069 DOT 7070403 AT users DOT sourceforge DOT net>
In-Reply-To: <402C2069.7070403@users.sourceforge.net>

Yaakov Selkowitz wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> OK, after a lot of time looking at the user guide, FAQ, and Google, I
> finally figured out (I think) how to get DLLs to build with the
> autotools.  But now I'm having troubles with building the executables
> from the same package that depend on this library.
> 
> My "test case" is fribidi.  In short:
> 
> 1) I added -no-undefined to libfribidi_la_LDFLAGS in Makefile.in
> (there's only one, no subdirs).

You might want to use automake+autoconf+libtool, instead of just 
autoconf+libtool.

> 2) I added an empty main function to one of the src .c files:
> 
> +int main ()
> +{ return 0; }

You don't need to do this.

> dlltool seems to build cygfribidi-0.dll properly, then make continues to
> build fribidi.exe, which depends on libfribidi, and the following happens:

Don't use dlltool.  It's old and crotchety.  Use gcc -shared (or 
libtool).  For examples, see the dllhelpers 
here:http://www.neuro.gatech.edu/users/cwilson/cygutils/dll-stuff/index.html

And make sure you're using a new(er) libtool/autoconf, like 
autoconf-devel-2.59 and libtool-devel-1.5.

--
Chuck


--
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