public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* help with dynamic linkage?
@ 2006-02-11  5:23 skaller
  2006-02-11  5:31 ` skaller
  2006-02-11  6:47 ` Igor Peshansky
  0 siblings, 2 replies; 10+ messages in thread
From: skaller @ 2006-02-11  5:23 UTC (permalink / raw)
  To: cygwin

hi, I'm having some problem getting dynamic linkage to work.
The linkage model is like this:

mainline <----- load time ---- librtl.dll
^                               / 
 \                             /
dlopen                        /
   \                         /
  user.dll <-----------------

gdb indicates the code is crashing in dlopen. LoadLibrary
doesn't appear to work either :)

All the code is C++. It works on Linux, it works with 
the option -mnocygwin, and it works with MSVC++.

It *used* to work with Cygwin. The problem is almost
certainly just using the wrong linker switches.

The linkage technique is to follow Linux: no export libraries
are built, build time linkage is done directly against the
dll. This works fine for a simple C program.

In order to build according to the above model,
there are 3 compilation steps, and 3 linkage steps.
However, the crash is unrelated to building the user.dll,
since it occurs whenever mainline calls dlopen, even with
a garbage name.

I have cygwin installed on 2 comps and get the same result.

I have tried two methods: generate and link against export file
librtl.dll.a, and just linkagainst librtl.dll. Both methods
fail. Warnings like:

Info: resolving vtable for XXXby linking to __imp__XXX (auto-import)

occur when linking the executable.

Switches: -O3 -fomit-frame-pointer --inline 

Hosts: 
* AMD64 running XP pro SP1
* AMD64x2 running XP64

Cygwin: latest setup provides.

Any hints what is causing the problem or how to fix it?

-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  5:31 ` skaller
@ 2006-02-11  5:31   ` Brian Dessent
  2006-02-11  5:59     ` skaller
  2006-02-11  5:54   ` Igor Peshansky
  1 sibling, 1 reply; 10+ messages in thread
From: Brian Dessent @ 2006-02-11  5:31 UTC (permalink / raw)
  To: cygwin

skaller wrote:

> Program received signal SIGSEGV, Segmentation fault.
> 0x610ae938 in pthread_key_create () from /usr/bin/cygwin1.dll
> (gdb) bt

*sigh* Not an actual fault.

http://www.cygwin.com/ml/cygwin-xfree/2005-12/msg00065.html
http://www.cygwin.com/ml/cygwin/2006-01/msg01147.html
http://www.cygwin.com/ml/cygwin/2006-02/msg00015.html
http://www.cygwin.com/ml/cygwin/2006-01/msg00464.html

and there is a fix:
http://www.cygwin.com/ml/cygwin-patches/2006-q1/msg00048.html

Brian

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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  5:23 help with dynamic linkage? skaller
@ 2006-02-11  5:31 ` skaller
  2006-02-11  5:31   ` Brian Dessent
  2006-02-11  5:54   ` Igor Peshansky
  2006-02-11  6:47 ` Igor Peshansky
  1 sibling, 2 replies; 10+ messages in thread
From: skaller @ 2006-02-11  5:31 UTC (permalink / raw)
  To: cygwin

On Sat, 2006-02-11 at 16:11 +1100, skaller wrote:
> hi, I'm having some problem getting dynamic linkage to work.

Oops .. hmm .. just got gdb backtrace on another experiment.
Now we're crashing initialising standard I/O in the rtl.
BTW the rtl dll name is libflx_dynamic.dll.

Program received signal SIGSEGV, Segmentation fault.
0x610ae938 in pthread_key_create () from /usr/bin/cygwin1.dll
(gdb) bt
#0  0x610ae938 in pthread_key_create () from /usr/bin/cygwin1.dll
#1  0x6108dd7f in _sigfe () from /usr/bin/cygwin1.dll
#2  0x59432d52 in ?? ()
#3  0x100b2008 in ?? ()
#4  0x00000001 in ?? ()
#5  0x100b2008 in ?? ()
#6  0x0022eda8 in ?? ()
#7  0x610af6b7 in pthread::once () from /usr/bin/cygwin1.dll
#8  0x610af6b7 in pthread::once () from /usr/bin/cygwin1.dll
#9  0x6108dd7f in _sigfe () from /usr/bin/cygwin1.dll
#10 0x0022edd8 in ?? ()
#11 0x100448e5 in _Unwind_SjLj_Register () from 
/cygdrive/c/felix/flx/bin/libflx_dynamic.dll
#12 0x100448e5 in _Unwind_SjLj_Register () from 
/cygdrive/c/felix/flx/bin/libflx_dynamic.dll
#13 0x10038e73 in std::ios_base::Init::Init () from 
/cygdrive/c/felix/flx/bin/libflx_dynamic.dll
#14 0x10035631 in __static_initialization_and_destruction_0 () from 
/cygdrive/c/felix/flx/bin/libflx_dynamic.dll
#15 0x100879d0 in std::__ioinit ()
#16 0x0000001a in ?? ()
#17 0x1007cc80 in virtual thunk to 
flx::gc::collector::malloc_free::~malloc_free() ()
   from /cygdrive/c/felix/flx/bin/libflx_dynamic.dll
#18 0x61010253 in per_module::run_ctors () from /usr/bin/cygwin1.dll
#19 0x00000001 in ?? ()
#20 0x610102a0 in dll::init () from /usr/bin/cygwin1.dll
#21 0x280b0008 in ?? ()
#22 0x0000002f in ?? ()
#23 0x0022ee98 in ?? ()
#24 0x610d8ef7 in strrchr () from /usr/bin/cygwin1.dll
#25 0x61005eb3 in _dll_crt0@0 () from /usr/bin/cygwin1.dll
#26 0x00000000 in ?? () from 
(gdb) 
[1]+  Stopped                 gdb bin/flx_run.exe



-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  5:31 ` skaller
  2006-02-11  5:31   ` Brian Dessent
@ 2006-02-11  5:54   ` Igor Peshansky
  1 sibling, 0 replies; 10+ messages in thread
From: Igor Peshansky @ 2006-02-11  5:54 UTC (permalink / raw)
  To: skaller; +Cc: cygwin

On Sat, 11 Feb 2006, skaller wrote:

> On Sat, 2006-02-11 at 16:11 +1100, skaller wrote:
> > hi, I'm having some problem getting dynamic linkage to work.
>
> Oops .. hmm .. just got gdb backtrace on another experiment.
> Now we're crashing initialising standard I/O in the rtl.
> BTW the rtl dll name is libflx_dynamic.dll.
>
> Program received signal SIGSEGV, Segmentation fault.
> 0x610ae938 in pthread_key_create () from /usr/bin/cygwin1.dll
> (gdb) bt
> #0  0x610ae938 in pthread_key_create () from /usr/bin/cygwin1.dll
> [snip]

John,

This one's benign -- just "continue" from there.  Search this month's
archives for details.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha@cs.nyu.edu | igor@watson.ibm.com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"

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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  5:31   ` Brian Dessent
@ 2006-02-11  5:59     ` skaller
  0 siblings, 0 replies; 10+ messages in thread
From: skaller @ 2006-02-11  5:59 UTC (permalink / raw)
  To: cygwin

On Fri, 2006-02-10 at 21:31 -0800, Brian Dessent wrote:
> skaller wrote:
> 
> > Program received signal SIGSEGV, Segmentation fault.
> > 0x610ae938 in pthread_key_create () from /usr/bin/cygwin1.dll
> > (gdb) bt
> 
> *sigh* Not an actual fault.

Ah, ok. Thanks. But now it is worse! I type continue and the
program aborts with a core dump. The statically linked version
doesn't. The code IS different: the cygwin dynamic link version
is the same as the linux code (which works). There is one difference
though: on Linux I'm using gcc 4.0, Cygwin is using gcc 3.4.4.

Curious -- seems like the dll isn't loaded until it is referenced,
is that right? (Thats bad .. is there any way to force all the
symbols to resolve at startup?)


-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  5:23 help with dynamic linkage? skaller
  2006-02-11  5:31 ` skaller
@ 2006-02-11  6:47 ` Igor Peshansky
  2006-02-11  7:42   ` skaller
  1 sibling, 1 reply; 10+ messages in thread
From: Igor Peshansky @ 2006-02-11  6:47 UTC (permalink / raw)
  To: skaller; +Cc: cygwin

On Sat, 11 Feb 2006, skaller wrote:

> hi, I'm having some problem getting dynamic linkage to work.
> The linkage model is like this:
>
> mainline <----- load time ---- librtl.dll
> ^                               /
>  \                             /
> dlopen                        /
>    \                         /
>   user.dll <-----------------
>
> gdb indicates the code is crashing in dlopen. LoadLibrary
> doesn't appear to work either :)
>
> All the code is C++. It works on Linux, it works with
> the option -mnocygwin, and it works with MSVC++.

You mean "-mno-cygwin", right?

> It *used* to work with Cygwin. The problem is almost
> certainly just using the wrong linker switches.

It would help if you told us what linker switches you're using.  In fact,
a small example program, buildable with a makefile into two DLLs and a
main application, would be even more helpful.

> The linkage technique is to follow Linux: no export libraries
> are built, build time linkage is done directly against the
> dll. This works fine for a simple C program.
>
> In order to build according to the above model,
> there are 3 compilation steps, and 3 linkage steps.
> However, the crash is unrelated to building the user.dll,
> since it occurs whenever mainline calls dlopen, even with
> a garbage name.

Then wouldn't you be able to reproduce it with only one DLL and one main
application?  Can we see a small complete example that shows the problem?

> I have cygwin installed on 2 comps and get the same result.
>
> I have tried two methods: generate and link against export file
> librtl.dll.a, and just linkagainst librtl.dll. Both methods
> fail. Warnings like:
>
> Info: resolving vtable for XXXby linking to __imp__XXX (auto-import)
>
> occur when linking the executable.

Those are informational.  You can either ignore them, or give the
"-Wl,--enable-auto-import" flag to the linker to quiet them.

> Switches: -O3 -fomit-frame-pointer --inline
>
> Hosts:
> * AMD64 running XP pro SP1
> * AMD64x2 running XP64
>
> Cygwin: latest setup provides.

Umm, setup can provide quite a few versions ranging from ancient to
latest, depending on your mirror.  Why not follow the guidelines at
<http://cygwin.com/problems.html> and attach (as an uncompressed text
attachment) the output of "cygcheck -svr"?

> Any hints what is causing the problem or how to fix it?

Not until we have enough information to allow us to reproduce the problem.
FWIW, I was unable to reproduce this with a trivial instance of your
scheme above and default linker options.  One quick question: how are you
invoking functions from user.dll, are you getting the right function
pointer, and are you taking care of C++ name mangling when loading symbols
from the DLL?
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha@cs.nyu.edu | igor@watson.ibm.com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"

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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  6:47 ` Igor Peshansky
@ 2006-02-11  7:42   ` skaller
  2006-02-11  8:22     ` skaller
  2006-02-12  3:27     ` Igor Peshansky
  0 siblings, 2 replies; 10+ messages in thread
From: skaller @ 2006-02-11  7:42 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: Type: text/plain, Size: 5096 bytes --]

On Sat, 2006-02-11 at 00:59 -0500, Igor Peshansky wrote:
> On Sat, 11 Feb 2006, skaller wrote:
> 
> > hi, I'm having some problem getting dynamic linkage to work.
> > The linkage model is like this:
> >
> > mainline <----- load time ---- librtl.dll
> > ^                               /
> >  \                             /
> > dlopen                        /
> >    \                         /
> >   user.dll <-----------------
> >
> > gdb indicates the code is crashing in dlopen. LoadLibrary
> > doesn't appear to work either :)
> >
> > All the code is C++. It works on Linux, it works with
> > the option -mnocygwin, and it works with MSVC++.
> 
> You mean "-mno-cygwin", right?

Yes, sorry, my build scripts call that platform 'nocygwin'.

> It would help if you told us what linker switches you're using. 

No special switches, just -L and -l.

>  In fact,
> a small example program, buildable with a makefile into two DLLs and a
> main application, would be even more helpful.

I have tried that .. it works :) Basically the original instructions
on the website say to use -Wl,-auto-import ... blah blah in the advanced
explanations suff. But the simplified example doesn't use that.
Neither do I. I did try building an export/import lib. That does seem
to change the time and way the system crashes.

The crash occurs when an attempt is made to load the user.dll,
even when the filename given is rubbish .. so the problem isn't
related to that dll. The program WORKS when no filename is
given, in which case it just prints the usual 'usage' information.

In the case of a garbage filename, the rtl should be throwing
a C++ exception. Perhaps that's causing the problem. However 
in the case of a valid filename it should work .. but I get
the same result.

Unfortunately the only easy way to reproduce the problem is to
download and install Felix:

	http://felix.sf.net/flx_1.1.2_rc1.tgz

which requires Python and Ocaml. After that ./configure, make
should work. Then make test. BTW: if any Cygwin expert would
like to join the project that would be great!

> Then wouldn't you be able to reproduce it with only one DLL and one main
> application?  Can we see a small complete example that shows the problem?

As above .. small C example, as given on the Cygwin website, works
just fine. 

The problem could be related to C++ RTTI, since I know
ELF/gcc 4.0 doesn't work correctly it would be unfair to expect
gcc 3.4 on Cygwin to do all that nasty emulation and work.

(The problem here is related to duplicate typeinfo records,
which cannot be avoided in general with dynamic linkage.
Some care is needed in the code to ensure the RTTI is only
instantiated once, and properly imported from that one
location, because gcc's method of catching exceptions 
is broken)

However no exception should be thrown when loading one
of the proper dlls with dlopen(), so there could be
two distinct faults.

It's also possible -O3 -fomit-frame-pointer is the problem:
gcc's -O3 is known to not work reliably. (however if I recall
I got rid of both, and it made no difference).

> > Info: resolving vtable for XXXby linking to __imp__XXX (auto-import)
> >
> > occur when linking the executable.
> 
> Those are informational.  You can either ignore them, or give the
> "-Wl,--enable-auto-import" flag to the linker to quiet them.

I admit being confused what that does. According to my understanding
of it, this auto-import thing should only apply to variables.
vtables and code are read only, they should be in the code (text)
segment shouldn't they?

> > Cygwin: latest setup provides.
> 
> Umm, setup can provide quite a few versions ranging from ancient to
> latest, depending on your mirror.  Why not follow the guidelines at
> <http://cygwin.com/problems.html> and attach (as an uncompressed text
> attachment) the output of "cygcheck -svr"?

Done, for the XP64 machine. The other I can't get atm, since
its dual booted with Linux which is running my mail client :)

> > Any hints what is causing the problem or how to fix it?
> 
> Not until we have enough information to allow us to reproduce the problem.

I need some hint of what it could be to try to reduce
the 100KLoc to a manageable size :) It has to be something
related to different ways Linux and Cygwin handle dynamic linkage,
interacting with some other feature -- such as threads, exception
handling, linkage technique/dll startup code, etc etc.

One difference: on Linux I have to use -lpthread, on Cygwin
that seems unnecessary. I did try rebuilding with it.

> FWIW, I was unable to reproduce this with a trivial instance of your
> scheme above and default linker options.

Neither was I.

>   One quick question: how are you
> invoking functions from user.dll, are you getting the right function
> pointer, and are you taking care of C++ name mangling when loading symbols
> from the DLL?

I think so: it works on Linux, OSX, -mno-cygwin, MSVC++ etc. 
All the dlsym() symbols are extern "C". 

However, the rtl is not dlopen()ed.


-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net

[-- Attachment #2: cycheckout.txt --]
[-- Type: text/plain, Size: 24466 bytes --]


Cygwin Configuration Diagnostics
Current System Time: Sat Feb 11 17:27:59 2006

Windows 2003 Server Ver 5.2 Build 3790 Service Pack 1

Running under WOW64 on AMD64

Path:	C:\cygwin\usr\local\bin
	C:\cygwin\bin
	C:\cygwin\bin
	C:\cygwin\usr\X11R6\bin
	C:\cygwin\usr\local\bin
	C:\cygwin\bin
	C:\cygwin\bin
	C:\cygwin\usr\X11R6\bin
	c:\WINDOWS\system32
	c:\WINDOWS
	c:\WINDOWS\System32\Wbem

Output from C:\cygwin\bin\id.exe (nontsec)
UID: 1002(skaller)  GID: 513(None)
0(root)             513(None)           544(Administrators) 545(Users)

Output from C:\cygwin\bin\id.exe (ntsec)
UID: 1002(skaller)  GID: 513(None)
0(root)             513(None)           544(Administrators) 545(Users)

SysDir: C:\WINDOWS\system32
WinDir: C:\WINDOWS

USER = 'skaller'
PWD = '/cygdrive/c/felix/flx'
HOME = '/home/skaller'
MAKE_MODE = 'unix'

HOMEPATH = '\Documents and Settings\skaller'
MANPATH = '/usr/local/man:/usr/share/man:/usr/man:/usr/local/man:/usr/share/man:/usr/man::/usr/ssl/man:/usr/ssl/man'
APPDATA = 'C:\Documents and Settings\skaller\Application Data'
PROGRAMW6432 = 'C:\Program Files'
HOSTNAME = 'budgie'
XKEYSYMDB = '/usr/X11R6/lib/X11/XKeysymDB'
TERM = 'xterm'
PROCESSOR_IDENTIFIER = 'AMD64 Family 15 Model 47 Stepping 2, AuthenticAMD'
WINDIR = 'C:\WINDOWS'
COMMONPROGRAMW6432 = 'C:\Program Files\Common Files'
WINDOWID = '12582926'
USERDOMAIN = 'BUDGIE'
COMMONPROGRAMFILES(X86) = 'C:\Program Files (x86)\Common Files'
OS = 'Windows_NT'
ALLUSERSPROFILE = 'C:\Documents and Settings\All Users'
XAPPLRESDIR = '/usr/X11R6/lib/X11/app-defaults'
!:: = '::\'
XCMSDB = '/usr/X11R6/lib/X11/Xcms.txt'
XTERM_SHELL = '/bin/bash'
TEMP = '/cygdrive/c/DOCUME~1/skaller/LOCALS~1/Temp'
COMMONPROGRAMFILES = 'C:\Program Files (x86)\Common Files'
XNLSPATH = '/usr/X11R6/lib/X11/locale'
TERMCAP = 'xterm-r6|xterm|xterm X11R6 version:am:km:mi:ms:xn:co#80:it#8:li#24:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:DO=\E[%dB:LE=\E[%dD:RI=\E[%dC:UP=\E[%dA:ae=^O:al=\E[L:as=^N:bl=^G:cd=\E[J:ce=\E[K:cl=\E[H\E[2J:cm=\E[%i%d;%dH:cr=^M:cs=\E[%i%d;%dr:ct=\E[3g:dc=\E[P:dl=\E[M:do=^J:ei=\E[4l:ho=\E[H:im=\E[4h:is=\E7\E[r\E[m\E[?7h\E[?1;3;4;6l\E[4l\E8\E>:k1=\EOP:k2=\EOQ:k3=\EOR:k4=\EOS:k5=\E[15~:k6=\E[17~:k7=\E[18~:k8=\E[19~:k9=\E[20~:kD=\E[3~:kI=\E[2~:kN=\E[6~:kP=\E[5~:kd=\EOB:ke=\E[?1l\E>:kh=\E[1~:kl=\EOD:kr=\EOC:ks=\E[?1h\E=:ku=\EOA:le=^H:md=\E[1m:me=\E[m:mr=\E[7m:nd=\E[C:rc=\E8:sc=\E7:se=\E[m:sf=^J:so=\E[7m:sr=\EM:ta=^I:te=\E[2J\E[?47l\E8:ti=\E7\E[?47h:ue=\E[m:up=\E[A:us=\E[4m:kb=\010:'
USERNAME = 'skaller'
PROCESSOR_LEVEL = '15'
FP_NO_HOST_CHECK = 'NO'
SYSTEMDRIVE = 'C:'
PROCESSOR_ARCHITEW6432 = 'AMD64'
USERPROFILE = 'C:\Documents and Settings\skaller'
CLIENTNAME = 'Console'
LOGONSERVER = '\\BUDGIE'
PS1 = '\[\e]0;\w\a\]\n\[\e[32m\]\u@\h \[\e[33m\]\w\[\e[0m\]\n\$ '
PROCESSOR_ARCHITECTURE = 'x86'
!C: = 'C:\cygwin\bin'
XTERM_VERSION = 'Cygwin 6.8.2.0(202)'
SHLVL = '4'
PATHEXT = '.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH'
HOMEDRIVE = 'C:'
PROMPT = '$P$G'
COMSPEC = 'C:\WINDOWS\system32\cmd.exe'
TMP = '/cygdrive/c/DOCUME~1/skaller/LOCALS~1/Temp'
SYSTEMROOT = 'C:\WINDOWS'
LOGNAME = 'skaller'
CVS_RSH = '/bin/ssh'
PROCESSOR_REVISION = '2f02'
INFOPATH = '/usr/local/info:/usr/share/info:/usr/info:/usr/local/info:/usr/share/info:/usr/info:'
PROGRAMFILES = 'C:\Program Files (x86)'
DISPLAY = ':0.0'
NUMBER_OF_PROCESSORS = '1'
PROGRAMFILES(X86) = 'C:\Program Files (x86)'
SESSIONNAME = 'Console'
COMPUTERNAME = 'BUDGIE'
XAUTHORITY = '/home/skaller/.Xauthority'
_ = '/usr/bin/cygcheck'
POSIXLY_CORRECT = '1'

HKEY_CURRENT_USER\Software\Cygnus Solutions
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\Program Options
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2
  (default) = '/cygdrive'
  cygdrive flags = 0x00000022
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/
  (default) = 'C:\cygwin'
  flags = 0x0000000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/usr/bin
  (default) = 'C:\cygwin/bin'
  flags = 0x0000000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/usr/lib
  (default) = 'C:\cygwin/lib'
  flags = 0x0000000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\Program Options

a:  fd             N/A    N/A                    
c:  hd  NTFS     60000Mb  12% CP CS UN PA FC     
d:  cd             N/A    N/A                    
e:  hd  FAT32     8502Mb   1% CP    UN           

C:\cygwin      /          system  binmode
C:\cygwin/bin  /usr/bin   system  binmode
C:\cygwin/lib  /usr/lib   system  binmode
.              /cygdrive  system  binmode,cygdrive

Found: C:\cygwin\bin\awk.exe
Found: C:\cygwin\bin\bash.exe
Found: C:\cygwin\bin\cat.exe
Found: C:\cygwin\bin\cp.exe
Found: C:\cygwin\bin\cpp.exe
Not Found: crontab
Found: C:\cygwin\bin\find.exe
Found: C:\cygwin\bin\gcc.exe
Found: C:\cygwin\bin\gdb.exe
Found: C:\cygwin\bin\grep.exe
Found: C:\cygwin\bin\kill.exe
Found: C:\cygwin\bin\ld.exe
Found: C:\cygwin\bin\ls.exe
Found: C:\cygwin\bin\make.exe
Found: C:\cygwin\bin\mv.exe
Not Found: patch
Not Found: perl
Found: C:\cygwin\bin\rm.exe
Found: C:\cygwin\bin\sed.exe
Found: C:\cygwin\bin\ssh.exe
Found: C:\cygwin\bin\sh.exe
Found: C:\cygwin\bin\tar.exe
Found: C:\cygwin\bin\test.exe
Not Found: vi
Found: C:\cygwin\bin\vim.exe

  113k 2005/07/16 C:\cygwin\bin\cygatk-1.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygatk-1.0-0.dll" v0.0 ts=2005/7/16 5:37
   56k 2005/07/09 C:\cygwin\bin\cygbz2-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygbz2-1.dll" v0.0 ts=2005/7/9 15:09
    7k 2005/11/20 C:\cygwin\bin\cygcharset-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygcharset-1.dll" v0.0 ts=2005/11/20 13:24
    7k 2003/10/19 C:\cygwin\bin\cygcrypt-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygcrypt-0.dll" v0.0 ts=2003/10/19 17:57
 1108k 2005/10/17 C:\cygwin\bin\cygcrypto-0.9.7.dll - os=4.0 img=1.0 sys=4.0
                  "cygcrypto-0.9.7.dll" v0.0 ts=2005/10/17 19:16
 1047k 2005/10/11 C:\cygwin\bin\cygcrypto-0.9.8.dll - os=4.0 img=1.0 sys=4.0
                  "cygcrypto-0.9.8.dll" v0.0 ts=2005/10/11 22:47
  895k 2004/04/28 C:\cygwin\bin\cygdb-4.2.dll - os=4.0 img=1.0 sys=4.0
                  "cygdb-4.2.dll" v0.0 ts=2004/4/28 1:31
 1156k 2004/04/28 C:\cygwin\bin\cygdb_cxx-4.2.dll - os=4.0 img=1.0 sys=4.0
                  "cygdb_cxx-4.2.dll" v0.0 ts=2004/4/28 1:35
  174k 2004/10/14 C:\cygwin\bin\cygexpat-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygexpat-0.dll" v0.0 ts=2004/10/14 18:34
  129k 2004/03/11 C:\cygwin\bin\cygfontconfig-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygfontconfig-1.dll" v0.0 ts=2004/3/11 11:12
   40k 2005/09/29 C:\cygwin\bin\cygform-8.dll - os=4.0 img=1.0 sys=4.0
                  "cygform-8.dll" v0.0 ts=2005/9/29 12:15
   45k 2001/04/25 C:\cygwin\bin\cygform5.dll - os=4.0 img=1.0 sys=4.0
                  "cygform5.dll" v0.0 ts=2001/4/25 15:28
   35k 2002/01/09 C:\cygwin\bin\cygform6.dll - os=4.0 img=1.0 sys=4.0
                  "cygform6.dll" v0.0 ts=2002/1/9 17:03
   48k 2003/08/09 C:\cygwin\bin\cygform7.dll - os=4.0 img=1.0 sys=4.0
                  "cygform7.dll" v0.0 ts=2003/8/9 19:25
  375k 2005/09/06 C:\cygwin\bin\cygfreetype-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygfreetype-6.dll" v0.0 ts=2005/9/7 8:51
   28k 2003/07/20 C:\cygwin\bin\cyggdbm-3.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdbm-3.dll" v0.0 ts=2003/7/20 17:58
   30k 2003/08/11 C:\cygwin\bin\cyggdbm-4.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdbm-4.dll" v0.0 ts=2003/8/11 12:12
   19k 2003/03/22 C:\cygwin\bin\cyggdbm.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdbm.dll" v0.0 ts=2002/2/20 14:05
   15k 2003/07/20 C:\cygwin\bin\cyggdbm_compat-3.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdbm_compat-3.dll" v0.0 ts=2003/7/20 18:00
   15k 2003/08/11 C:\cygwin\bin\cyggdbm_compat-4.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdbm_compat-4.dll" v0.0 ts=2003/8/11 12:13
  451k 2005/12/27 C:\cygwin\bin\cyggdk-x11-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdk-x11-2.0-0.dll" v0.0 ts=2005/12/26 22:20
   77k 2005/12/27 C:\cygwin\bin\cyggdk_pixbuf-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdk_pixbuf-2.0-0.dll" v0.0 ts=2005/12/26 22:11
   54k 2005/12/27 C:\cygwin\bin\cyggdk_pixbuf_xlib-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggdk_pixbuf_xlib-2.0-0.dll" v0.0 ts=2005/12/26 23:03
  557k 2006/01/04 C:\cygwin\bin\cygglib-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygglib-2.0-0.dll" v0.0 ts=2006/1/4 20:48
   10k 2006/01/04 C:\cygwin\bin\cyggmodule-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggmodule-2.0-0.dll" v0.0 ts=2006/1/4 20:49
  229k 2006/01/04 C:\cygwin\bin\cyggobject-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggobject-2.0-0.dll" v0.0 ts=2006/1/4 20:49
   14k 2006/01/04 C:\cygwin\bin\cyggthread-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggthread-2.0-0.dll" v0.0 ts=2006/1/4 20:50
 2764k 2005/12/27 C:\cygwin\bin\cyggtk-x11-2.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cyggtk-x11-2.0-0.dll" v0.0 ts=2005/12/26 22:43
   17k 2001/06/28 C:\cygwin\bin\cyghistory4.dll - os=4.0 img=1.0 sys=4.0
                  "cyghistory4.dll" v0.0 ts=2001/1/7 15:34
   29k 2003/08/10 C:\cygwin\bin\cyghistory5.dll - os=4.0 img=1.0 sys=4.0
                  "cyghistory5.dll" v0.0 ts=2003/8/11 9:16
   24k 2006/02/08 C:\cygwin\bin\cyghistory6.dll - os=4.0 img=1.0 sys=4.0
                  "cyghistory6.dll" v0.0 ts=2006/2/9 0:03
  947k 2005/11/20 C:\cygwin\bin\cygiconv-2.dll - os=4.0 img=1.0 sys=4.0
                  "cygiconv-2.dll" v0.0 ts=2005/11/20 13:24
   22k 2001/12/13 C:\cygwin\bin\cygintl-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygintl-1.dll" v0.0 ts=2001/12/13 20:28
   37k 2003/08/10 C:\cygwin\bin\cygintl-2.dll - os=4.0 img=1.0 sys=4.0
                  "cygintl-2.dll" v0.0 ts=2003/8/11 7:50
   31k 2005/11/20 C:\cygwin\bin\cygintl-3.dll - os=4.0 img=1.0 sys=4.0
                  "cygintl-3.dll" v0.0 ts=2005/11/20 13:04
   21k 2001/06/20 C:\cygwin\bin\cygintl.dll - os=4.0 img=1.0 sys=4.0
                  "cygintl.dll" v0.0 ts=2001/6/21 3:09
  132k 2003/08/11 C:\cygwin\bin\cygjpeg-62.dll - os=4.0 img=1.0 sys=4.0
                  "cygjpeg-62.dll" v0.0 ts=2003/8/11 10:37
   21k 2005/09/29 C:\cygwin\bin\cygmenu-8.dll - os=4.0 img=1.0 sys=4.0
                  "cygmenu-8.dll" v0.0 ts=2005/9/29 12:15
   26k 2001/04/25 C:\cygwin\bin\cygmenu5.dll - os=4.0 img=1.0 sys=4.0
                  "cygmenu5.dll" v0.0 ts=2001/4/25 15:27
   20k 2002/01/09 C:\cygwin\bin\cygmenu6.dll - os=4.0 img=1.0 sys=4.0
                  "cygmenu6.dll" v0.0 ts=2002/1/9 17:03
   29k 2003/08/09 C:\cygwin\bin\cygmenu7.dll - os=4.0 img=1.0 sys=4.0
                  "cygmenu7.dll" v0.0 ts=2003/8/9 19:25
   21k 2004/10/22 C:\cygwin\bin\cygminires.dll - os=4.0 img=1.0 sys=4.0
                  "cygminires.dll" v0.0 ts=2004/10/23 6:28
   67k 2005/09/29 C:\cygwin\bin\cygncurses++-8.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses++-8.dll" v0.0 ts=2005/9/29 12:16
  156k 2001/04/25 C:\cygwin\bin\cygncurses++5.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses++5.dll" v0.0 ts=2001/4/25 15:29
  175k 2002/01/09 C:\cygwin\bin\cygncurses++6.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses++6.dll" v0.0 ts=2002/1/9 17:03
  226k 2005/09/29 C:\cygwin\bin\cygncurses-8.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses-8.dll" v0.0 ts=2005/9/29 12:02
  226k 2001/04/25 C:\cygwin\bin\cygncurses5.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses5.dll" v0.0 ts=2001/4/25 15:17
  202k 2002/01/09 C:\cygwin\bin\cygncurses6.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses6.dll" v0.0 ts=2002/1/9 17:03
  224k 2003/08/09 C:\cygwin\bin\cygncurses7.dll - os=4.0 img=1.0 sys=4.0
                  "cygncurses7.dll" v0.0 ts=2003/8/9 19:24
   11k 2005/09/29 C:\cygwin\bin\cygpanel-8.dll - os=4.0 img=1.0 sys=4.0
                  "cygpanel-8.dll" v0.0 ts=2005/9/29 12:15
   15k 2001/04/25 C:\cygwin\bin\cygpanel5.dll - os=4.0 img=1.0 sys=4.0
                  "cygpanel5.dll" v0.0 ts=2001/4/25 15:27
   12k 2002/01/09 C:\cygwin\bin\cygpanel6.dll - os=4.0 img=1.0 sys=4.0
                  "cygpanel6.dll" v0.0 ts=2002/1/9 17:03
   19k 2003/08/09 C:\cygwin\bin\cygpanel7.dll - os=4.0 img=1.0 sys=4.0
                  "cygpanel7.dll" v0.0 ts=2003/8/9 19:24
  198k 2005/07/18 C:\cygwin\bin\cygpango-1.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpango-1.0-0.dll" v0.0 ts=2005/7/18 21:26
  134k 2005/07/18 C:\cygwin\bin\cygpangoft2-1.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpangoft2-1.0-0.dll" v0.0 ts=2005/7/18 21:28
   33k 2005/07/18 C:\cygwin\bin\cygpangowin32-1.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpangowin32-1.0-0.dll" v0.0 ts=2005/7/18 21:29
   36k 2005/07/18 C:\cygwin\bin\cygpangox-1.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpangox-1.0-0.dll" v0.0 ts=2005/7/18 21:27
   22k 2005/07/18 C:\cygwin\bin\cygpangoxft-1.0-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpangoxft-1.0-0.dll" v0.0 ts=2005/7/18 21:29
  176k 2005/09/06 C:\cygwin\bin\cygpcre-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpcre-0.dll" v0.0 ts=2005/9/7 6:49
  299k 2005/09/06 C:\cygwin\bin\cygpcrecpp-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpcrecpp-0.dll" v0.0 ts=2005/9/7 7:26
    6k 2005/09/06 C:\cygwin\bin\cygpcreposix-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpcreposix-0.dll" v0.0 ts=2005/9/7 7:26
  230k 2005/07/11 C:\cygwin\bin\cygpng12.dll - os=4.0 img=1.0 sys=4.0
                  "cygpng12.dll" v0.0 ts=2005/7/12 9:50
   22k 2002/06/09 C:\cygwin\bin\cygpopt-0.dll - os=4.0 img=1.0 sys=4.0
                  "cygpopt-0.dll" v0.0 ts=2002/6/9 15:45
  108k 2001/06/28 C:\cygwin\bin\cygreadline4.dll - os=4.0 img=1.0 sys=4.0
                  "cygreadline4.dll" v0.0 ts=2001/1/7 15:34
  148k 2003/08/10 C:\cygwin\bin\cygreadline5.dll - os=4.0 img=1.0 sys=4.0
                  "cygreadline5.dll" v0.0 ts=2003/8/11 9:16
  152k 2006/02/08 C:\cygwin\bin\cygreadline6.dll - os=4.0 img=1.0 sys=4.0
                  "cygreadline6.dll" v0.0 ts=2006/2/9 0:03
  231k 2005/10/17 C:\cygwin\bin\cygssl-0.9.7.dll - os=4.0 img=1.0 sys=4.0
                  "cygssl-0.9.7.dll" v0.0 ts=2005/10/17 19:16
  215k 2005/10/11 C:\cygwin\bin\cygssl-0.9.8.dll - os=4.0 img=1.0 sys=4.0
                  "cygssl-0.9.8.dll" v0.0 ts=2005/10/11 22:47
  282k 2003/08/11 C:\cygwin\bin\cygtiff4.dll - os=4.0 img=1.0 sys=4.0
                  "cygtiff4.dll" v0.0 ts=2003/8/11 12:32
   65k 2005/08/23 C:\cygwin\bin\cygz.dll - os=4.0 img=1.0 sys=4.0
                  "cygz.dll" v0.0 ts=2005/8/23 12:03
 1763k 2006/01/20 C:\cygwin\bin\cygwin1.dll - os=4.0 img=1.0 sys=4.0
                  "cygwin1.dll" v0.0 ts=2006/1/21 5:28
    Cygwin DLL version info:
        DLL version: 1.5.19
        DLL epoch: 19
        DLL bad signal mask: 19005
        DLL old termios: 5
        DLL malloc env: 28
        API major: 0
        API minor: 150
        Shared data: 4
        DLL identifier: cygwin1
        Mount registry: 2
        Cygnus registry name: Cygnus Solutions
        Cygwin registry name: Cygwin
        Program options name: Program Options
        Cygwin mount registry name: mounts v2
        Cygdrive flags: cygdrive flags
        Cygdrive prefix: cygdrive prefix
        Cygdrive default prefix: 
        Build date: Fri Jan 20 13:28:43 EST 2006
        CVS tag: cr-0x5ef
        Shared id: cygwin1S4

  243k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygdps-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygdps-1.dll" v0.0 ts=2005/2/24 1:42
   26k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygdpstk-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygdpstk-1.dll" v0.0 ts=2005/2/24 1:42
   21k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygfontenc-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygfontenc-1.dll" v0.0 ts=2005/2/24 1:45
   36k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygFS-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygFS-6.dll" v0.0 ts=2005/2/24 1:34
  358k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygGL-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygGL-1.dll" v0.0 ts=2005/2/24 1:39
  438k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygGLU-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygGLU-1.dll" v0.0 ts=2005/2/24 1:41
   75k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygICE-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygICE-6.dll" v0.0 ts=2005/2/24 1:28
    9k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygoldX-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygoldX-6.dll" v0.0 ts=2005/2/24 1:28
 1413k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygOSMesa-4.dll - os=4.0 img=1.0 sys=4.0
                  "cygOSMesa-4.dll" v0.0 ts=2005/2/24 1:39
   20k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygpsres-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygpsres-1.dll" v0.0 ts=2005/2/24 1:42
   30k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygSM-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygSM-6.dll" v0.0 ts=2005/2/24 1:28
  877k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygX11-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygX11-6.dll" v0.0 ts=2005/2/24 1:28
  254k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXaw-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXaw-6.dll" v0.0 ts=2005/2/24 1:31
  356k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXaw-7.dll - os=4.0 img=1.0 sys=4.0
                  "cygXaw-7.dll" v0.0 ts=2005/2/24 1:32
  363k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXaw-8.dll - os=4.0 img=1.0 sys=4.0
                  "cygXaw-8.dll" v0.0 ts=2005/2/24 1:33
    9k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXcomposite-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXcomposite-1.dll" v0.0 ts=2005/2/24 1:44
   30k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXcursor-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXcursor-1.dll" v0.0 ts=2005/2/24 1:43
    9k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXdamage-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXdamage-1.dll" v0.0 ts=2005/2/24 1:44
    7k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXevie-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXevie-1.dll" v0.0 ts=2005/2/24 1:43
   49k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXext-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXext-6.dll" v0.0 ts=2005/2/24 1:28
   16k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXfixes-3.dll - os=4.0 img=1.0 sys=4.0
                  "cygXfixes-3.dll" v0.0 ts=2005/2/24 1:43
   56k 2004/03/11 C:\cygwin\usr\X11R6\bin\cygXft-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXft-1.dll" v0.0 ts=2003/11/18 12:42
   63k 2004/03/23 C:\cygwin\usr\X11R6\bin\cygXft-2.dll - os=4.0 img=1.0 sys=4.0
                  "cygXft-2.dll" v0.0 ts=2004/3/24 9:20
   27k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXi-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXi-6.dll" v0.0 ts=2005/2/24 1:34
  125k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygxkbfile-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygxkbfile-1.dll" v0.0 ts=2005/2/24 1:34
   12k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygxkbui-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygxkbui-1.dll" v0.0 ts=2005/2/24 1:34
   76k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXmu-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXmu-6.dll" v0.0 ts=2005/2/24 1:30
   11k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXmuu-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXmuu-1.dll" v0.0 ts=2005/2/24 1:30
   26k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXp-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXp-6.dll" v0.0 ts=2005/2/24 1:31
   52k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXpm-4.dll - os=4.0 img=1.0 sys=4.0
                  "cygXpm-4.dll" v0.0 ts=2005/2/24 1:30
   12k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXrandr-2.dll - os=4.0 img=1.0 sys=4.0
                  "cygXrandr-2.dll" v0.0 ts=2005/2/24 1:43
   28k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXrender-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXrender-1.dll" v0.0 ts=2005/2/24 1:42
    8k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXRes-1.dll - os=4.0 img=1.0 sys=4.0
                  "cygXRes-1.dll" v0.0 ts=2005/2/24 1:43
   40k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygxrx-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygxrx-6.dll" v0.0 ts=2005/2/24 1:53
   25k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygxrxnest-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygxrxnest-6.dll" v0.0 ts=2005/2/24 1:53
  282k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXt-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXt-6.dll" v0.0 ts=2005/2/24 1:29
   27k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXTrap-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXTrap-6.dll" v0.0 ts=2005/2/24 1:43
   17k 2005/02/23 C:\cygwin\usr\X11R6\bin\cygXtst-6.dll - os=4.0 img=1.0 sys=4.0
                  "cygXtst-6.dll" v0.0 ts=2005/2/24 1:34

No Cygwin services found.


Cygwin Package Information
Last downloaded files to: C:\Documents and Settings\skaller\Desktop
Last downloaded files from: ftp://mirror.internode.on.net/pub/cygwin

Package              Version
_update-info-dir     00355-1
alternatives         1.3.20a-2
ash                  20040127-3
atk                  1.9.1-1
atk-runtime          1.9.1-1
base-files           3.7-1
base-passwd          2.2-1
bash                 3.0-14
binutils             20050610-1
bzip2                1.0.3-1
coreutils            5.93-3
crypt                1.1-1
cvs                  1.11.17-1
cygrunsrv            1.12-1
cygutils             1.2.10-1
cygwin               1.5.19-4
cygwin-doc           1.4-3
diffutils            2.8.7-1
editrights           1.01-1
expat                1.95.8-1
findutils            4.2.27-1
fontconfig           2.2.2-1
freetype2            2.1.9-1
gawk                 3.1.5-2
gcc                  3.4.4-1
gcc-core             3.4.4-1
gcc-g++              3.4.4-1
gcc-mingw-core       20050522-1
gcc-mingw-g++        20050522-1
gdb                  20041228-3
gdbm                 1.8.3-7
gettext              0.14.5-1
glib2                2.6.6-2
glib2-runtime        2.6.6-2
grep                 2.5.1a-2
groff                1.18.1-2
gtk2-x11             2.6.10-1
gtk2-x11-runtime     2.6.10-1
gvim                 6.4-1
gzip                 1.3.5-1
less                 381-1
libbz2_1             1.0.3-1
libcharset1          1.9.2-2
libdb4.2             4.2.52-1
libfontconfig1       2.2.2-1
libfreetype26        2.1.9-1
libgdbm              1.8.0-5
libgdbm-devel        1.8.3-7
libgdbm3             1.8.3-3
libgdbm4             1.8.3-7
libiconv             1.9.2-2
libiconv2            1.9.2-2
libintl              0.10.38-3
libintl1             0.10.40-1
libintl2             0.12.1-3
libintl3             0.14.5-1
libjpeg62            6b-11
libncurses-devel     5.4-4
libncurses5          5.2-1
libncurses6          5.2-8
libncurses7          5.3-4
libncurses8          5.4-4
libpcre0             6.3-1
libpng12             1.2.8-2
libpopt0             1.6.4-4
libreadline4         4.1-2
libreadline5         4.3-5
libreadline6         5.1-3
libtiff4             3.6.0-5
libXft               2.1.6-1
libXft1              1.0.0-1
libXft2              2.1.6-1
login                1.9-7
make                 3.80-1
man                  1.5p-1
mingw-runtime        3.9-2
minires              1.00-1
mktemp               1.5-3
nano                 1.2.2-1
nasm                 0.98.39-1
ncurses              5.4-4
ocaml                3.08.1-1
openssh              4.3p1-2
openssl              0.9.8a-1
openssl097           0.9.7i-1
pango                1.8.1-1
pango-runtime        1.8.1-1
pcre                 6.3-1
pcre-devel           6.3-1
pcre-doc             6.3-1
ping                 1.0-1
pkgconfig            0.17.2-2
python               2.4.1-1
run                  1.1.6-1
sed                  4.1.5-1
tar                  1.15.1-3
tcltk                20030901-1
termcap              20050421-1
terminfo             5.4_20041009-1
texinfo              4.8-1
vim                  6.4-4
w32api               3.6-1
which                1.7-1
X-startup-scripts    1.0.11-1
xorg-x11-base        6.8.2.0-1
xorg-x11-bin         6.8.2.0-1
xorg-x11-bin-dlls    6.8.2.0-1
xorg-x11-bin-lndir   6.8.2.0-1
xorg-x11-etc         6.8.2.0-1
xorg-x11-fenc        6.8.1.0-2
xorg-x11-fnts        6.8.1.0-3
xorg-x11-libs-data   6.8.2.0-1
xorg-x11-xwin        6.8.2.0-4
xterm                202-1
zlib                 1.2.3-1
Use -h to see help about each section


[-- Attachment #3: Type: text/plain, Size: 218 bytes --]

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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  7:42   ` skaller
@ 2006-02-11  8:22     ` skaller
  2006-02-12  3:27     ` Igor Peshansky
  1 sibling, 0 replies; 10+ messages in thread
From: skaller @ 2006-02-11  8:22 UTC (permalink / raw)
  To: cygwin

On Sat, 2006-02-11 at 17:46 +1100, skaller wrote:
> cripts call that platform 'nocygwin'.
> 
> > It would help if you told us what linker switches you're using. 
> 
> No special switches, just -L and -l.

Sorry, small lie: I'm using -shared to build the dll.


-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-11  7:42   ` skaller
  2006-02-11  8:22     ` skaller
@ 2006-02-12  3:27     ` Igor Peshansky
  2006-02-12  6:25       ` skaller
  1 sibling, 1 reply; 10+ messages in thread
From: Igor Peshansky @ 2006-02-12  3:27 UTC (permalink / raw)
  To: skaller; +Cc: cygwin

[-- Attachment #1: Type: TEXT/PLAIN, Size: 6802 bytes --]

On Sat, 11 Feb 2006, skaller wrote:

> On Sat, 2006-02-11 at 00:59 -0500, Igor Peshansky wrote:
> > On Sat, 11 Feb 2006, skaller wrote:
> >
> > > hi, I'm having some problem getting dynamic linkage to work.
> > > The linkage model is like this:
> > >
> > > mainline <----- load time ---- librtl.dll
> > > ^                               /
> > >  \                             /
> > > dlopen                        /
> > >    \                         /
> > >   user.dll <-----------------
> > >
> > > gdb indicates the code is crashing in dlopen. LoadLibrary
> > > doesn't appear to work either :)
>
> > In fact, a small example program, buildable with a makefile into two
> > DLLs and a main application, would be even more helpful.
>
> I have tried that .. it works :) Basically the original instructions
> on the website say to use -Wl,-auto-import ... blah blah in the advanced
> explanations suff. But the simplified example doesn't use that.
> Neither do I. I did try building an export/import lib. That does seem
> to change the time and way the system crashes.
>
> The crash occurs when an attempt is made to load the user.dll,
> even when the filename given is rubbish .. so the problem isn't
> related to that dll. The program WORKS when no filename is
> given, in which case it just prints the usual 'usage' information.
>
> In the case of a garbage filename, the rtl should be throwing
> a C++ exception. Perhaps that's causing the problem. However
> in the case of a valid filename it should work .. but I get
> the same result.
>
> Unfortunately the only easy way to reproduce the problem is to
> download and install Felix:
>
> 	http://felix.sf.net/flx_1.1.2_rc1.tgz

Well, you could have done *some* work on cutting the testcase down,
especially since you know the code better than I do.  But, since I'm the
Cygwin O'Caml maintainer, I was curious, so I downloaded it (turns out the
problem has nothing to do with O'Caml).  Starting with the make log and
the generated C++ version of the code, I ended up with the attached files.
FWIW, it seems to be crashing in the flx_dynlink_t destructor (not in
dlopen) -- in fact, even before I cut it down to the attached, commenting
out any mention of dlopen still caused the crash.  Stepping through the
code in gdb quickly gets you to the place where it crashes.

> which requires Python and Ocaml. After that ./configure, make
> should work. Then make test. BTW: if any Cygwin expert would
> like to join the project that would be great!
>
> > Then wouldn't you be able to reproduce it with only one DLL and one
> > main application?  Can we see a small complete example that shows the
> > problem?
>
> As above .. small C example, as given on the Cygwin website, works
> just fine.
>
> The problem could be related to C++ RTTI, since I know
> ELF/gcc 4.0 doesn't work correctly it would be unfair to expect
> gcc 3.4 on Cygwin to do all that nasty emulation and work.
>
> (The problem here is related to duplicate typeinfo records,
> which cannot be avoided in general with dynamic linkage.
> Some care is needed in the code to ensure the RTTI is only
> instantiated once, and properly imported from that one
> location, because gcc's method of catching exceptions
> is broken)
>
> However no exception should be thrown when loading one
> of the proper dlls with dlopen(), so there could be
> two distinct faults.
>
> It's also possible -O3 -fomit-frame-pointer is the problem:
> gcc's -O3 is known to not work reliably. (however if I recall
> I got rid of both, and it made no difference).
>
> > > Info: resolving vtable for XXXby linking to __imp__XXX (auto-import)
> > >
> > > occur when linking the executable.
> >
> > Those are informational.  You can either ignore them, or give the
> > "-Wl,--enable-auto-import" flag to the linker to quiet them.
>
> I admit being confused what that does. According to my understanding
> of it, this auto-import thing should only apply to variables.
> vtables and code are read only, they should be in the code (text)
> segment shouldn't they?

I'm not sure.  Technically, vtables are data (though they contain pointers
to the code).  But I'm not a C++ internals expert, and this is not a C++
internals list... :-)  Besides, that's irrelevant to your crash.

> > > Cygwin: latest setup provides.
> >
> > Umm, setup can provide quite a few versions ranging from ancient to
> > latest, depending on your mirror.  Why not follow the guidelines at
> > <http://cygwin.com/problems.html> and attach (as an uncompressed text
> > attachment) the output of "cygcheck -svr"?
>
> Done, for the XP64 machine. The other I can't get atm, since
> its dual booted with Linux which is running my mail client :)
>
> > > Any hints what is causing the problem or how to fix it?
> >
> > Not until we have enough information to allow us to reproduce the
> > problem.
>
> I need some hint of what it could be to try to reduce
> the 100KLoc to a manageable size :) It has to be something

As I said above, this has nothing to do with dynamic linkage.  And cutting
this down was relatively easy (if tedious) -- just start with main(), keep
removing functionality until it doesn't crash anymore, then put the last
removed piece back in and start removing finer-grained functionality.

> related to different ways Linux and Cygwin handle dynamic linkage,
> interacting with some other feature -- such as threads, exception
> handling, linkage technique/dll startup code, etc etc.
>
> One difference: on Linux I have to use -lpthread, on Cygwin
> that seems unnecessary. I did try rebuilding with it.

The pthreads functionality is built into cygwin1.dll.

> > FWIW, I was unable to reproduce this with a trivial instance of your
> > scheme above and default linker options.
>
> Neither was I.
>
> >   One quick question: how are you
> > invoking functions from user.dll, are you getting the right function
> > pointer, and are you taking care of C++ name mangling when loading symbols
> > from the DLL?
>
> I think so: it works on Linux, OSX, -mno-cygwin, MSVC++ etc.
> All the dlsym() symbols are extern "C".
>
> However, the rtl is not dlopen()ed.

This looks to me like another instance of
<http://cygwin.com/ml/cygwin/2006-01/msg00113.html> (follow that thread
through -- it has a reference to another thread, too).
HTH,
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha@cs.nyu.edu | igor@watson.ibm.com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"

[-- Attachment #2: Type: TEXT/PLAIN, Size: 685 bytes --]

CXXFLAGS=-g -Wall -Wno-invalid-offsetof -O3 -fomit-frame-pointer --inline -DNDEBUG -DFLX_BUILD_DYNAMIC_RTL
LDFLAGS=-Wl,--enable-auto-import -L.
LDLIBS=-lflx_dynamic

.DEFAULT: all
	
all: flx_run libflx_dynamic.dll

FLX_RUN_OBJS=\
	flx_run_dynamic.o

FLX_DYNAMIC_OBJS=\
	flx_dynlink_dynamic.o

flx_run: $(FLX_RUN_OBJS) libflx_dynamic.dll
	$(LINK.cc) $(FLX_RUN_OBJS) $(LDLIBS) -o $@

libflx_dynamic.dll: $(FLX_DYNAMIC_OBJS)
	$(LINK.cc) -shared -o $@ -Wl,--out-implib=$@.a $^

.PHONY: clean
.SUFFIXES: _dynamic.o .cxx

%_dynamic.o: %.cxx
	$(COMPILE.cc) $< -o $@

%_dynamic.o: %.cpp
	$(COMPILE.cc) $< -o $@

clean:
	-rm $(FLX_RUN_OBJS) $(FLX_DYNAMIC_OBJS)


[-- Attachment #3: Type: TEXT/PLAIN, Size: 504 bytes --]

//#line 1354 "lpsrc/flx_rtl.ipk"
#include <cstdlib>
#include <stdio.h>
#include <vector>
#include <list>
#include <map>
#include <cstring>
#include <cassert>

#include <string>
//#include <unistd.h>
//#include "flx_rtl.hpp"

#include "flx_dynlink.hpp"
using namespace std;
using namespace flx::rtl;

int main(int argc, char** argv)
{
  if (argc<2)
  {
    printf("usage: flx_run [--debug] dll_filename options ..\n");
    return 1;
  }
  flx_dynlink_t library;
  return 0;
}


[-- Attachment #4: Type: TEXT/PLAIN, Size: 158 bytes --]

//#line 1167 "lpsrc/flx_rtl.ipk"
#include "flx_dynlink.hpp"

namespace flx { namespace rtl {

flx_dynlink_t::~flx_dynlink_t(){}

}} // namespaces



[-- Attachment #5: Type: TEXT/PLAIN, Size: 414 bytes --]

//#line 990 "lpsrc/flx_rtl.ipk"
#ifndef FLX_DYNLINK
#define FLX_DYNLINK
#define FLX_RTL_EXTERN __declspec(dllexport)
#include <string>
using namespace std;

namespace flx { namespace rtl {

struct FLX_RTL_EXTERN flx_dynlink_t;

/// dynamic object loader.

struct FLX_RTL_EXTERN flx_dynlink_t
{
public:
  // data
  string filename;

  virtual ~flx_dynlink_t();
};

}} // namespaces
#endif


[-- Attachment #6: Type: text/plain, Size: 218 bytes --]

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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: help with dynamic linkage?
  2006-02-12  3:27     ` Igor Peshansky
@ 2006-02-12  6:25       ` skaller
  0 siblings, 0 replies; 10+ messages in thread
From: skaller @ 2006-02-12  6:25 UTC (permalink / raw)
  To: cygwin; +Cc: felix

On Sat, 2006-02-11 at 20:38 -0500, Igor Peshansky wrote:

> > 	http://felix.sf.net/flx_1.1.2_rc1.tgz
> 
> Well, you could have done *some* work on cutting the testcase down,

I spent lots of time on it ;( That problem has been bugging
me for over 6 months.

> This looks to me like another instance of
> <http://cygwin.com/ml/cygwin/2006-01/msg00113.html> (follow that thread
> through -- it has a reference to another thread, too).

Ah! Thank you!! That makes sense!! I had trouble with std::string
before. Now why didn't I think of that .. only recently I removed
the manual template instantiation forcing instantiation in the RTL
(because it gave link errors on OSX 10.3)

Thanks very much! Flx_dynlink_t is indeed in error!!

My policy has been to force instantiation of destructors,
constructors and all virtual or otherwise significant
functions of constructible rtl types in the rtl, 
but flx_dynlink_t has a compiler generated default constructor.

flx_libinit_t has the same problem (no default or copy ctors,
no assignment operator).

I fixed flx_dynlink_t and initialised the string 'filename' to ""
and now all the non-pthread tests work!

-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net


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

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2006-02-12  4:24 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-11  5:23 help with dynamic linkage? skaller
2006-02-11  5:31 ` skaller
2006-02-11  5:31   ` Brian Dessent
2006-02-11  5:59     ` skaller
2006-02-11  5:54   ` Igor Peshansky
2006-02-11  6:47 ` Igor Peshansky
2006-02-11  7:42   ` skaller
2006-02-11  8:22     ` skaller
2006-02-12  3:27     ` Igor Peshansky
2006-02-12  6:25       ` skaller

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