I nearly understand what is happening, but I still haven't a workaround.
What is happening?
During installaton of the newly compiled ncurses "cd" changes into the
image directory. There are three files:
cygncurses5.dll
tic.exe
toe.exe
"Bash" depends on cygncurses5.dll. In the moment "ln" is called (part
of bash), "bash" forks. It notices that there is the new
cygncurses5.dll in the PATH now, because the current directory is
always in PATH. It findes out, that this one has a different address.
Certainly this is not a perfect description of what is going on. What
does it examine the new cygncurses5.dll? Why doesn't it simply use
that one, that is already memory. Maybe my explanation is completely
wrong.
I tried to emerge from ash to avoid bash, but that doesn't help. I
think bash is always drawn in by "ln".
Have you been faced with a similar issue on INTERIX? What did you do
as workaround?
Thanks
Al
09-25-2010, 08:16 PM
Fabian Groffen
Cygwin: emerge -u system issues
On 25-09-2010 15:50:09 +0200, Al wrote:
> I nearly understand what is happening, but I still haven't a workaround.
>
> What is happening?
>
> During installaton of the newly compiled ncurses "cd" changes into the
> image directory. There are three files:
>
> cygncurses5.dll
> tic.exe
> toe.exe
>
> "Bash" depends on cygncurses5.dll. In the moment "ln" is called (part
> of bash), "bash" forks. It notices that there is the new
> cygncurses5.dll in the PATH now, because the current directory is
> always in PATH. It findes out, that this one has a different address.
Why would $ED/... be in PATH? Is . in PATH?
> Certainly this is not a perfect description of what is going on. What
> does it examine the new cygncurses5.dll? Why doesn't it simply use
> that one, that is already memory. Maybe my explanation is completely
> wrong.
>
> I tried to emerge from ash to avoid bash, but that doesn't help. I
> think bash is always drawn in by "ln".
>
> Have you been faced with a similar issue on INTERIX? What did you do
> as workaround?
no, but they do suffer from "file in use" problems, see:
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/profiles/prefix/windows/interix/profile.bashrc?revision=1.4&view=markup
--
Fabian Groffen
Gentoo on a different level
09-25-2010, 08:26 PM
Al
Cygwin: emerge -u system issues
>> "Bash" depends on cygncurses5.dll. In the moment "ln" is called *(part
>> of bash), "bash" forks. It notices that there is the new
>> cygncurses5.dll in the PATH now, because the current directory is
>> always in PATH. *It findes out, that this one has a different address.
>
> Why would $ED/... be in PATH? *Is . in PATH?
In the sense I mean it, the way windows finds dynamic libraries, yes:
>>Is . in PATH?
>
> In the sense I mean it, the way windows finds dynamic libraries, yes:
>
> http://msdn.microsoft.com/en-us/library/7d83bc18%28VS.71%29.aspx
>
> See point 2.
To check that
Point 1) The directory where the executable module for the current
process is located.
cd /home/prefix/gentoo/var/tmp/portage/sys-libs/ncurses-5.7-r5/image//home/prefix/gentoo/usr/bin
ls
cygncurses5.dll tic.exe toe.exe
HIT on point 2.
Al
10-11-2010, 10:55 AM
Al
Cygwin: emerge -u system issues
> This question is about reemerging ncurses and I hope to find some
> experience from side of the INTERIX team.
>
> While installing ncurses there is a step that burns down to this failure:
>
> <------------------->
> *(cd /home/prefix/gentoo/var/tmp/portage/sys-libs/ncurses-5.7-r5/image//home/prefix/gentoo/usr/bin
> && ln -s tic.exe *infotocap.exe)
>
> * * *2 [main] bash 2044 child_copy: linked dll data write copy
> failed, 0x6CA88000..0x6CA9493C, done 0, windows pid 2044, Win32 error
> 487
> /home/prefix/gentoo/bin/bash: fork: retry: Resource temporarily unavailable
> <------------------->
>
Meanwhile I found a workaround. I have to replace "emake" with "make"
in the ebuild.
Still I have not found out what is the reason. For those who are
interested, there a two important points,
1.) Sheebang-line: #!/home/prefix/gentoo/bin/bash
While the bootstrapping itself still runs with Cygwins Bash
"/bin/bash", emake tries to switch to Prefix Bash by means of its
sheebang-line. That explains why the first built of ncurses is
successfull. There is no Prefix Bash at that time. Cygwins Bash is
used.
$SHELL evalutes to the current BASH which is the Prefix Bash if the
sheebang-line was successfull.
So it's either the exec call or the different Bash which causes the issue.
I didn't investigate any further here, as it makes no sense to change
the emake script and there is a workaround. Anaway, maybe somebody has
an idea what really goes wrong.
Al
--
Caution crosser: *Runnig Gentoo/Prefix on Cygwin/Vista.
All stupid questions are related to that context.