From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 72687 invoked by alias); 21 Dec 2017 05:50:33 -0000 Mailing-List: contact test-list-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: , Sender: test-list-owner@sourceware.org Received: (qmail 72666 invoked by uid 89); 21 Dec 2017 05:50:32 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=ALL_TRUSTED,BAYES_00,DATE_IN_PAST_12_24 autolearn=no version=3.3.2 spammy=H*p:D*net, PDF, Home X-HELO: localhost.localdomain Received: from localhost (HELO localhost.localdomain) (127.0.0.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 21 Dec 2017 05:50:31 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Thu, 21 Dec 2017 05:50:00 -0000 From: Enrique Perez-Terron To: test-list@sourceware.org Subject: [ANNOUNCEMENT] mkshortcut fails when run from setup, postinstall/cygwin-doc.sh - not otherwise Message-Id: Reply-To: test-list@sourceware.org X-SW-Source: 2017/txt/msg00022.txt.bz2 Lately, whenever I run setup (x86), my /var/log/setup.log.full contains: 2017/12/20 03:07:44 running: C:\cygwin\bin\bash.exe --norc --noprofile "/etc/postinstall/cygwin-doc.sh" mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/User Guide (PDF).lnk" failed; does the target directory exist? mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/User Guide (HTML).lnk" failed; does the target directory exist? mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/API (PDF).lnk" failed; does the target directory exist? mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/API (HTML).lnk" failed; does the target directory exist? mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/Home Page.lnk" failed; does the target directory exist? mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/FAQ.lnk" failed; does the target directory exist? 2017/12/20 03:07:45 abnormal exit: exit code=3 Please notice the extra C:/ in front of the target link name. So I have added a line "set -x" at the top in postinstall/cygwin-doc.sh, and the relevant section becomes + read target name desc + '[' -r ']' + /bin/mkshortcut -A -P -n 'Cygwin/User Guide (PDF)' -d 'Cygwin User Guide PDF' -- /usr/share/doc/cygwin-doc/cygwin-ug-net.pdf mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/User Guide (PDF).lnk" failed; does the target directory exist? + read target name desc + '[' -r ']' + /bin/mkshortcut -A -P -n 'Cygwin/User Guide (HTML)' -d 'Cygwin User Guide HTML' -- /usr/share/doc/cygwin-doc/html/cygwin-ug-net/index.html mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/User Guide (HTML).lnk" failed; does the target directory exist? + read target name desc + '[' -r ']' + /bin/mkshortcut -A -P -n 'Cygwin/API (PDF)' -d 'Cygwin API Reference PDF' -- /usr/share/doc/cygwin-doc/cygwin-api.pdf mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/API (PDF).lnk" failed; does the target directory exist? + read target name desc + '[' -r ']' + /bin/mkshortcut -A -P -n 'Cygwin/API (HTML)' -d 'Cygwin API Reference HTML' -- /usr/share/doc/cygwin-doc/html/cygwin-api/index.html mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/API (HTML).lnk" failed; does the target directory exist? + read target name desc + read target name desc + /bin/mkshortcut -A -P -n 'Cygwin/Home Page' -d 'Cygwin Home Page Link' -a https://cygwin.com/index.html -- /bin/cygstart mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/Home Page.lnk" failed; does the target directory exist? + read target name desc + /bin/mkshortcut -A -P -n Cygwin/FAQ -d 'Cygwin Frequently Asked Questions Link' -a https://cygwin.com/faq.html -- /bin/cygstart mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/C:/cygwin/FAQ.lnk" failed; does the target directory exist? (by the way -- this reveals another bug too: The script says "[ -r $t ] && $mks ..." where I am sure it should be "[ -r $target ] && $mks ...") (and again btw, I am not sure bash should count "[ -r ]" as a true statement) The script issues mkshortcut commands with sane arguments, no extra "C:/" in there. So I just tried to run the script from an elevated-privilege mintty shell: $ CYGWINFORALL=-A /bin/bash /etc/postinstall/cygwin-doc.sh But then it does NOT fail, and the shortcuts do get installed -- they were not present before. I am still running the 32-bit cygwin, though on a 64-bit windows 10 Home edition, version 1709, OS build 16299.125. Any ideas about what could be the problem? -Enrique