www.delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,T_TO_NO_BRKTS_FREEMAIL |
X-Spam-Check-By: | sourceware.org |
MIME-Version: | 1.0 |
In-Reply-To: | <4CAC8A1E.5090803@redhat.com> |
References: | <4CAC636E DOT 9070405 AT redhat DOT com> <AANLkTi=NFinUPVzHjaRGhY4P7Pd=NFq+NDM3mLsW-1F2 AT mail DOT gmail DOT com> <4CAC8A1E DOT 5090803 AT redhat DOT com> |
Date: | Wed, 6 Oct 2010 19:44:09 +0100 |
Message-ID: | <AANLkTimmfkVCXwkJ8kDTtFUxLw3QDDNpaNZjODxUNOYg@mail.gmail.com> |
Subject: | Re: mintty postinstall failure - attn: cygutils maintainer |
From: | Andy Koppe <andy DOT koppe AT gmail DOT com> |
To: | cygwin AT cygwin DOT com |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
On 6 October 2010 15:39, Eric Blake wrote: > On 10/06/2010 06:28 AM, Andy Koppe wrote: >> >> On 6 October 2010 12:54, Eric Blake wrote: >>> >>> Any reason why with my setup, mintty.sh exits with status 3 when run by >>> setup.exe, but with status 0 when I run it by hand? >>> /var/log/setup.log.full >>> doesn't give any hints; what else can I try to debug the issue? >> >> Assuming you were installing for All Users, try setting >> CYGWINFORALL=3D-A when running it by hand. > > Hmm, no I wasn't remembering to do that; but even when I add that in, I'm > still getting status 0 by hand: > > $ CYGWINFORALL=3D-A sh -vx /etc/postinstall/mintty.sh > ALL=3D$CYGWINFORALL > + ALL=3D-A > PROGS=3D$(/bin/cygpath -P $ALL) > /bin/cygpath -P $ALL > ++ /bin/cygpath -P -A > + PROGS=3D'/cygdrive/c/Documents and Settings/All Users/Start Menu/Progra= ms' > /bin/mkdir -p "$PROGS/Cygwin" && > /bin/mkshortcut -P $ALL -n Cygwin/mintty -a - -d Terminal /bin/mintty && > if [ "$ALL" ]; then > =C2=A0/bin/chmod a+r "$PROGS/Cygwin/mintty.lnk" > fi > + /bin/mkdir -p '/cygdrive/c/Documents and Settings/All Users/Start > Menu/Programs/Cygwin' > + /bin/mkshortcut -P -A -n Cygwin/mintty -a - -d Terminal /bin/mintty > + '[' -A ']' > + /bin/chmod a+r '/cygdrive/c/Documents and Settings/All Users/Start > Menu/Programs/Cygwin/mintty.lnk' > > But this time, I looked in /var/log/setup.log.full, and got this hint: > > 2010/10/06 08:25:18 running: k:\cygwin-2\bin\bash.exe --norc --noprofile > /etc/postinstall/mintty.sh > mkshortcut: Saving "C:\Documents and Settings\All Users\Start > Menu\Programs\K:\cygwin-2\Cygwin\mintty.lnk" failed; does the target > directory exist? > 2010/10/06 08:25:18 abnormal exit: exit code=3D3 > > Hmm - this looks like it could be a bug in mkshortcut. =C2=A0Why is the '= -n > Cygwin/mintty' argument showing up as an absolute pathname appended to the > tail of the start menu prefix? =C2=A0Is it a bug that is dependent on the= current > working directory? I can't see anything obviously wrong with mkshortcut. It converts the link name with cygwin_conv_to_win32_path(), adds '.lnk', and prepends the start menu path. cygwin_conv_to_win32_path() is supposed to turn a relative POSIX path such as 'Cygwin/mintty' into a relative Window path. That appears to work fine most of the time, at least I haven't seen this issue in my tests. Can anyone think of a reason why it might turn it into an absolute path such as 'K:\cygwin-2\Cygwin\mintty.lnk' instead? Does it make a difference if you run the script from the root directory of the install (which I think is where setup.exe runs then from) or from a cmd shell? Andy -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |