Unable to install source packages when running setup from command line
Tue Mar 22 14:39:50 GMT 2022
On Tue, Mar 22, 2022 at 01:54:48PM +0000, Jon Turney wrote:
> On 20/03/2022 18:20, Adam Dinwoodie wrote:
> > Hi,
> > I *suspect* this is a bug, but it might just be this isn't supposed to
> > work: there doesn't seem to be a way to download a source package for an
> > already-installed Cygwin package when using setup from the command line.
> > If I run, for example:
> > /bin/setup-x86_64.exe -d -l 'C:\Users\Adam\Downloads' -s http://www.mirrorservice.org/sites/sourceware.org/pub/cygwin/ -IP bash-completion -R 'C:\cygwin64'
> > I'd expected this to select and automatically install the source package
> > for bash-completion. In fact, "bash-completion" does show up in the
> > list of pending packages, but the "Src?" column is unchecked and greyed
> > out; I can't even select it manually in the GUI selection tool.
> > Unsurprisingly, when I continue through the installer, the source
> > package doesn't get installed. I see similar behaviour if -M or -q are
> > also added to the argument list.
> > Everything works as expected if I don't specify a package on the command
> > line, and just select the source package from the GUI manually. And
> > while selecting a package that isn't currently installed seems to hit
> > the same bug I've previously described with not showing up in the
> > "Pending" list, it does successfully install both the requested
> > package and the source package.
> > I've attached the setup.log and setup.log.full files, in case they're
> > useful for working out what's going wrong.
> Yeah, this is a bug.
> The design of '--include-source' is a bit weird, being "also install source
> for everything we are installing" not "also install source of named
> packages" (so '-IP foo' does nothing if foo is already installed) (see )
> As usual, PTC :)
Urgh, fine! I've been long avoiding looking at any of the actual Cygwin
DLL or setup code -- pretty much all my code-wrangling experience has
been on Linux or other POSIX-y systems -- but I suspect I'm increasingly
hitting the point of my desire and interest in fixing things overtaking
my wariness of Windows APIs :P
More information about the Cygwin