delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/11/06/04:37:46

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: <30E10C5E4EE6D31181EF00508B8B5BBB117AF6@EXCHANGE-SERVER.ddg.de>
From: =?iso-8859-1?Q?=22Schn=F6rr=2C_Claudius_Dr=2E=22?=
<Claudius DOT Schnoerr AT DDG DOT de>
To: "'cygwin AT cygwin DOT com'" <cygwin AT cygwin DOT com>
Subject: Re: Re: Q: python compiled with gcc-3.2?
Date: Wed, 6 Nov 2002 10:35:38 +0100
MIME-Version: 1.0
Note-from-DJ: This may be spam

Hello Norman,

that sounds interesting!

1) --------------------------------------------------------
First the versions of the used tools: gcc, swig, python:

@PC169/.../simple$ gcc -v
Reading specs from /bin/../lib/gcc-lib/i686-pc-cygwin/3.2/specs
Configured with: /netrel/src/gcc-3.2-1/configure
--enable-languages=c,c++,f77,java --enable-libgcj --enable-threads=posix
--with-system-zlib --enable-nls --without-included-gettext
--enable-interpreter --disable-sjlj-exceptions
--disable-version-specific-runtime-libs --enable-shared
--build=i686-pc-linux --host=i686-pc-cygwin --target=i686-pc-cygwin
--enable-haifa --prefix=/usr --exec-prefix=/usr --sysconfdir=/etc
--libdir=/usr/lib --includedir=/nonexistent/include --libexecdir=/usr/sbin
Thread model: posix
gcc version 3.2 20020818 (prerelease)

@PC169/.../simple$ ../../../swig -version

SWIG Version 1.3.16u-20021019-1050
Copyright (c) 1995-1998
University of Utah and the Regents of the University of California
Copyright (c) 1998-2002
University of Chicago

Compiled with CC

@PC169/.../simple$ python
Python 2.2.1 (#1, Jun 25 2002, 10:55:46)
[GCC 2.95.3-5 (cygwin special)] on cygwin
Type "help", "copyright", "credits" or "license" for more information.


2) --------------------------------------------------------
I first try to compile the python example 'simple' in the
swig-1.3.16-distribution:
After running configure, I copied swig.exe from /bin/swig from cygwin to the
directory SWIG-1.3.16 (building swig myself failed due to an error in some
yacc-file I am not familiar with).
Now, in SWIG-1.3.16/Examples/python/simple, the result of make:

@PC169/.../simple$ make
make -f ../../Makefile SRCS='example.c' SWIG='../../../swig' \
TARGET='example' INTERFACE='example.i' python
make[1]: Entering directory
`/u/schnoerr/Source/C++/Tools/SWIG-1.3.16/Examples/python/simple'
../../../swig -python  example.i
g++ -c   example_wrap.c example.c  -DHAVE_CONFIG_H -DUSE_DL_IMPORT
-I/hd/schnoerr/local/Installs/Programmierung/Shells/cygwin/lib/python2.2/inc
lude/python2.2
-I/hd/schnoerr/local/Installs/Programmierung/Shells/cygwin/lib/python2.2/lib
/python2.2/config
gcc -shared example.o  example_wrap.o
-L/hd/schnoerr/local/Installs/Programmierung/Shells/cygwin/lib/python2.2/lib
/python2.2/config -lpython2.2  -o _example.dll
example_wrap.o(.eh_frame+0x11):example_wrap.c: undefined reference to
`___gxx_personality_v0'
collect2: ld returned 1 exit status
make[1]: *** [python] Error 1
make[1]: Leaving directory
`/u/schnoerr/Source/C++/Tools/SWIG-1.3.16/Examples/python/simple'
make: *** [all] Error 2



The swig call works, and the compilation of the example_wrap.c and example.c
works too.
But the linkage of the _example.dll fails.

The same procedure for gcc-2.95 worked! Unfortunately, I cannot use it with
my gcc-3.2-based library.


It would be interesting whether you can confirm this behaviour with the
simple-example of swig, and in what your environment differs.

Claudius


---------------------------------------------------------
This Mail has been checked for Viruses
Attention: Encrypted mails can NOT be checked!

**

Diese Mail wurde auf Viren geprueft
Hinweis: Verschluesselte mails koennen NICHT auf Viren geprueft werden!
---------------------------------------------------------


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.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