public inbox for cygwin-xfree@sourceware.org
help / color / mirror / Atom feed
* RE: DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: c ompiling DDD
@ 2003-12-04 17:50 Richard Campbell
  2003-12-04 18:23 ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: compiling DDD Arnaud Desitter
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Campbell @ 2003-12-04 17:50 UTC (permalink / raw)
  To: cygwin-xfree; +Cc: bug-ddd

>So I guess that it should be something along the lines:
>gcc -Wall -I/usr/X11R6/include Xmcheck.c -L/usr/X11R6/lib
>.libs/libimp-cygXm-2.a
>using whather .libs/libimp-cygXm-2.a points to.

Ok, yeah, that seems to be the problem.  

bash-2.05b$ gcc -Wall -I/usr/X11R6/include Xmcheck.c -L/usr/X11R6/lib -lXm
Info: resolving _xmUseVersion by linking to __imp__xmUseVersion
(auto-import)
bash-2.05b$ ./a.exe 
xmUseVersion=2001 XmVersion=2001
bash-2.05b$ gcc -Wall -I/usr/X11R6/include Xmcheck.c -L/usr/X11R6/lib
ddd/.libs/libimp-cygXm-2.a 
bash-2.05b$ ./a.exe 
xmUseVersion=1089480191 XmVersion=2001

Now, I guess, to try and walk back all of the automatic steps to figure out
why ddd ended 
up linking against that libimp-cygXm-2.a file.

But first, I'll run that last g++ linking step for ddd after editing it to
remove those .libs
links.

-Richard Campbell.


^ permalink raw reply	[flat|nested] 6+ messages in thread
* RE: DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: c ompiling DDD
@ 2003-12-04 16:54 Richard Campbell
  2003-12-04 17:32 ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: compiling DDD Arnaud Desitter
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Campbell @ 2003-12-04 16:54 UTC (permalink / raw)
  To: cygwin-xfree; +Cc: bug-ddd

>Please try on Cygwin:
>>cat Xmcheck.c
>#include <Xm/Xm.h>
>#include <stdio.h>
>int main(void){
>  printf("xmUseVersion=%d XmVersion=%d\n",
>         xmUseVersion, XmVersion);
>  return 0;
>}
>>gcc -Wall -I/usr/X11R6/include Xmcheck.c -L/usr/X11R6/lib -lXm
>>./a.out
>xmUseVersion=2002 XmVersion=2002
>
>If it gives different numbers, there is a good chance that your lesstif
>library won't work properly.

bash-2.05b$ gcc -Wall -I/usr/X11R6/include Xmcheck.c -L/usr/X11R6/lib -lXm 
Info: resolving _xmUseVersion by linking to __imp__xmUseVersion
(auto-import)
bash-2.05b$ ./a.exe 
xmUseVersion=2001 XmVersion=2001

Same numbers.

-Richard Campbell.


^ permalink raw reply	[flat|nested] 6+ messages in thread
* RE: DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: c ompiling DDD
@ 2003-12-04 14:49 Richard Campbell
  2003-12-04 16:51 ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: compiling DDD Arnaud Desitter
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Campbell @ 2003-12-04 14:49 UTC (permalink / raw)
  To: 'cygwin-xfree@cygwin.com'; +Cc: bug-ddd

>That is a bug in gcc on cygwin related to "#pragma interface".
>Please look for help on the cygwin mailing list.

Arnaud, the problem is with both "#pragma interface" and "#pragma
implementation".
http://www.cygwin.com/ml/cygwin/2003-07/msg00463.html

Guarding all "#pragma interface" and "#pragma implementation" calls with 
ifndef __CYGWIN__

allows everything to compile cleanly - is this something that could be 
applied to the main baseline?


>Modifying ddd/config.h will not help. There is a problem with the
>lesstif distribution on cygwin. See:
>http://www.lesstif.org/INSTALL.html

Is the following what you are referring to?

"On windows using Cygwin, U/WIN or Interix, LessTif must be built as 
static libraries. Because, one of the biggest issues with X on Win32 
is the moronic DLL format. Specifically - it is not possible to export 
data from a Win32 DLL in a form that can be used to statically initialize 
another global variable. Data access from a DLL requires at least one 
pointer indirection, and hence executable code. This is why X11R6 doesn't 
have DLLs for Xt/Xmu/Xaw (and Motif) on Win32."

If yes, these rules have been changing.  Brian, isn't this what you 
were specifically working on recently?

-Richard Campbell.


^ permalink raw reply	[flat|nested] 6+ messages in thread
[parent not found: <1070478432.3fce34609f444@www.nexusmail.uwaterloo.ca>]

end of thread, other threads:[~2003-12-04 18:23 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-04 17:50 DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: c ompiling DDD Richard Campbell
2003-12-04 18:23 ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: compiling DDD Arnaud Desitter
  -- strict thread matches above, loose matches on Subject: below --
2003-12-04 16:54 DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: c ompiling DDD Richard Campbell
2003-12-04 17:32 ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: compiling DDD Arnaud Desitter
2003-12-04 14:49 DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: c ompiling DDD Richard Campbell
2003-12-04 16:51 ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS Re: compiling DDD Arnaud Desitter
     [not found] <1070478432.3fce34609f444@www.nexusmail.uwaterloo.ca>
2003-12-03 19:20 ` Brian Ford
2003-12-03 21:42   ` DDD 3.3.8 (i686-pc-cygwin) gets `Segmentation fault WAS " S Iyer
2003-12-04 10:19     ` Arnaud Desitter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).