delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/06/10/09:17:02

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-ID: <001a01beb342$cb2c15b0$29acdfd0@InspirePharm.Com>
From: "Suhaib M. Siddiqi" <ssiddiqi AT ipass DOT net>
To: "Araujo, Isaque G." <Isaque DOT Araujo AT alcoa DOT com DOT br>,
<cygwin AT sourceware DOT cygnus DOT com>
References: <7F756A7F899DD11187BF0000C07018E5019F43C9 AT soaspw1 DOT soa DOT alcoa DOT com>
Subject: Re: Execution problem
Date: Thu, 10 Jun 1999 09:11:45 -0400
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 5.00.2014.211
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2014.211

Do you have libX11.dll in the PATH so your executable can find it?

Beside the info you provided is not usefull.  you compile with a -g flag and
do a debuging.

gcc -g -o prog-1 prog-1.cc -lX11 -L/usr/X11/lib

--sms


----- Original Message -----
From: Araujo, Isaque G. <Isaque DOT Araujo AT alcoa DOT com DOT br>
To: <cygwin AT sourceware DOT cygnus DOT com>
Sent: Thursday, June 10, 1999 9:11 AM
Subject: Execution problem


> Hi, I'm starting programming with Xlib and I tried to compile a simple
> program which came with a tutorial:
>
> // program: prog-1.cc
> #include <X11/Xlib.h>
> #include <assert.h>
> #include <unistd.h>
> #define NIL (0)       // A name for the void pointer
> main()
> {
>       Display *dpy = XOpenDisplay(NIL);
>       assert(dpy);
>       Window w = XCreateWindow(dpy, DefaultRootWindow(dpy), 0, 0,
>        200, 100, 0,
>        CopyFromParent, CopyFromParent,
> CopyFromParent,
>        NIL, 0);
>       XMapWindow(dpy, w);
>       XFlush(dpy);
>       sleep(10);
> }
>
> I compiled:
>
> gcc -o prog-1 prog-1.cc -lX11 -L/usr/X11/lib
>
> but when I ran:
>
> ~/./prog-1
>     0       0 [main] C:\usr\local\xlib-tutorial\prog-1.exe 1054
> handle_exceptions: Exception: STATUS_ACCESS_VIOLATION
>     0   16529 [main] prog-1 1054 handle_exceptions: Dumping stack trace to
> prog-1.exe.core
>
> here goes the prog-1.exe.core:
> 12180   28709 [main] prog-1 1054 exception: trapped!
> 29314   58023 [main] prog-1 1054 exception: code 0xC0000005 at 0x4010BB
> 28475   86498 [main] prog-1 1054 exception: ax 0x1 bx 0x244FF60 cx
> 0x20F6B580 dx 0x320F6B58
> 33271  119769 [main] prog-1 1054 exception: si 0x0 di 0x246E8A0 bp
0x244FF44
> sp 0x244FF0C
> 33346  153115 [main] prog-1 1054 exception: exception is:
> STATUS_ACCESS_VIOLATION
> 49720  202835 [main] prog-1 1054 stack: Stack trace:
> 16945  219780 [main] prog-1 1054 stack: frame 0: sp = 0x244FD20, pc =
> 0x6100A11B
> 33525  253305 [main] prog-1 1054 stack: frame 1: sp = 0x244FD5C, pc =
> 0x77F94512
> 33268  286573 [main] prog-1 1054 stack: frame 2: sp = 0x244FD80, pc =
> 0x77F88EEB
> 49781  336354 [main] prog-1 1054 stack: frame 3: sp = 0x244FE0C, pc =
> 0x77F76266
> 27958  364312 [main] prog-1 1054 stack: frame 4: sp = 0x244FF44, pc =
> 0x6100442E
> 33274  397586 [main] prog-1 1054 stack: frame 5: sp = 0x244FF88, pc =
> 0x61004517
> 33341  430927 [main] prog-1 1054 stack: frame 6: sp = 0x244FF94, pc =
> 0x40124E
> 50136  481063 [main] prog-1 1054 stack: frame 7: sp = 0x244FFA4, pc =
> 0x40103A
> 16526  497589 [main] prog-1 1054 stack: frame 8: sp = 0x244FFC0, pc =
> 0x77F1B304
> 33317  530906 [main] prog-1 1054 stack: frame 9: sp = 0x244FFF0, pc = 0x0
> 33326  564232 [main] prog-1 1054 stack: End of stack trace
>
> Do you have any idea about this ?
> Oh yeah, I'm using cygwin-b20.1 and X11R6.4 libraries.
>
> Thank you.
>
> ~/isaque>
>
>
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
>
>


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


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