Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Subject: Re: SIGSEGV in cygwin1.dll From: Marco Canini To: cygwin AT cygwin DOT com In-Reply-To: <4045E1A4.6080109@corpit.ru> References: <40454B4E DOT 8070606 AT fastwebnet DOT it> <4045E1A4 DOT 6080109 AT corpit DOT ru> Content-Type: text/plain Message-Id: <1078325897.1626.5.camel@debian> Mime-Version: 1.0 Date: Wed, 03 Mar 2004 15:58:17 +0100 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Hello Egor, On Wed, 2004-03-03 at 14:46, Egor Duda wrote: > Marco Canini wrote: > > Hi list, this is my first post here. > > I'm writing an application that uses SDL, lib3ds and glib > > I've installed SDL and lib3ds from sources, both compiled with > > -mno-cygwin, while glib (2.2) comes from here > > http://web.sfc.keio.ac.jp/~s01397ms/cygwin/ > > I wasn't able to compile it from sources, still need to understand why. > > Anyway after I actually compiled my application I run it and ... SIGSEGV > > So, your application is linked both with cygwin1.dll, and with > Microsoft's C library (msvcrt or crtldd) indirectly, via sdl and lib3ds > which are built with -mno-cygwin. > You can't do that. See http://cygwin.com/faq/faq_4.html#SEC99 > Yeah, I realized that today. After trying to compile SDL with host, target cygwin I noticed that it will always call gcc with -mno-cygwin Since I don't want to spend my time in figuring out how to configure all 3 libs I'm trying with mingw32 version of sdl, glib. It's working, great! > > (The application works in my linux box) > > With gdb I was able to collect this stack trace: > > > > Program received signal SIGSEGV, Segmentation fault. > > 0x61021a8b in unsetenv () from /usr/bin/cygwin1.dll > > (gdb) bt > > #0 0x61021a8b in unsetenv () from /usr/bin/cygwin1.dll > > #1 0x6101f9b2 in dlfork () from /usr/bin/cygwin1.dll > > That probable means that cygwin's version of unsetenv() is called on > variable that was set by Microsoft's runtime. That is what I couldn't understand, thanks > You have to build cygwin > versions of those 3rd-party libraries you use. > > [...] > > > interestend in compiling only src/winsup/cygwin and not all cygwin. > > Is it possible? How? > > src/winsup/cygwin is basically all cygwin. You can tweak build process > to avoid building misc utilities such as cygcheck etc., but it won't > save you much time or disk space. > > If i can compile it I'll able to understand where's the problem > > -- > 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/ -- Marco Canini -- 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/