public inbox for cygwin-apps@cygwin.com
 help / color / mirror / Atom feed
* setup and 'provides:'
@ 2018-10-07 22:02 Ken Brown
  2018-10-08 14:41 ` cyg Simple
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Ken Brown @ 2018-10-07 22:02 UTC (permalink / raw)
  To: cygwin-apps

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

I've been experimenting with setup's support for the 'provides:' tag, and it's 
not behaving the way I expect [*].  I'm not sure if something in setup's 
interface with libsolv needs to be tweaked or if I'm just misunderstanding how 
this should work.  Here's what I tried:

I created a test repo with packages A, B, and C.  I made A require foo (not a 
package), and I made B and C provide foo.  The attached script does all this 
[**].  I then ran setup and selected A for installation.

The result was that libsolv simply chose B for installation, and setup showed 
this in the "Confirm" dialog.  What I expected was that libsolv would report a 
problem ("A requires foo but no selected or installed packages provide it"), 
with two possible solutions ("Install B or C").  Is that expectation unreasonable?

I plan to look into the libsolv sources to see if I can fix this, but I'm hoping 
that someone already knows the answer.

Ken

[*] I actually have a use in mind for 'provides:' in the emacs packaging, so I'd 
like to get this working.

[**] This requires using mksetupini from the calm git repo.  The released 
version of calm doesn't support 'provides:'.

[-- Attachment #2: make_test.sh --]
[-- Type: text/plain, Size: 979 bytes --]

#!/bin/sh
arch=x86_64
mkdir -p testrepo/${arch}/release/{A,B,C}
pushd testrepo/${arch}/release/A
tar -Jcf A-1-1.tar.xz --files-from /dev/null
tar -Jcf A-1-1-src.tar.xz --files-from /dev/null
cat > A-1-1.hint << EOF
sdesc: "Test package A"
ldesc: "Test package A"
category: Libs
depends: foo
EOF
popd
pushd testrepo/${arch}/release/B
tar -Jcf B-1-1.tar.xz --files-from /dev/null
tar -Jcf B-1-1-src.tar.xz --files-from /dev/null
cat > B-1-1.hint << EOF
sdesc: "Test package B"
ldesc: "Test package B"
category: Libs
depends: cygwin
provides: foo
EOF
popd
pushd testrepo/${arch}/release/C
tar -Jcf C-1-1.tar.xz --files-from /dev/null
tar -Jcf C-1-1-src.tar.xz --files-from /dev/null
cat > C-1-1.hint << EOF
sdesc: "Test package C"
ldesc: "Test package C"
category: Libs
depends: cygwin
provides: foo
EOF
popd
cd testrepo
mksetupini --arch ${arch} --inifile=${arch}/setup.ini --releasearea=. \
	   --disable-check=missing-depended-package 
xz -c ${arch}/setup.ini > ${arch}/setup.xz

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

end of thread, other threads:[~2018-10-09 18:03 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-07 22:02 setup and 'provides:' Ken Brown
2018-10-08 14:41 ` cyg Simple
2018-10-08 15:05   ` Ken Brown
2018-10-08 15:17     ` cyg Simple
2018-10-08 16:24       ` Ken Brown
2018-10-09 15:11         ` cyg Simple
2018-10-09 17:32           ` Ken Brown
2018-10-09 18:03           ` Achim Gratz
2018-10-08 18:07 ` Ken Brown
2018-10-08 20:04 ` Achim Gratz
2018-10-08 21:31   ` Ken Brown
2018-10-09 18:01     ` Achim Gratz

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