Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 56232

Summary: ecosconfig finds the wrong solution. Inverted
Product: [Retired] eCos Reporter: Andrew Lunn <andrew.lunn>
Component: ecosconfigAssignee: Bart Veer <bartv>
Status: CLOSED CURRENTRELEASE QA Contact: Bart Veer <bartv>
Severity: medium Docs Contact:
Priority: medium    
Version: 1.5.2CC: bartv, jlarmour
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-12-06 17:04:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
ecos.ecc which makes it go wrong
none
Patch for host/tools/configtool/standalone/common/cdl_exec.cxx none

Description Andrew Lunn 2001-11-14 13:23:41 UTC
Description of Problem:

If you use the -v flag to ecosconfig it will show possible solutions to
conflicts. Its getting the solutions wrong. It suggests turning an option
off, when it should turn it on.

eg...

~>ecosconfig -v resolve
C CYGPKG_OPENSSL, "requires" constraint not satisfied:  (CYGPKG_OPENSSL_SHA
&& C
YGPKG_OPENSSL_SHA1) ||
                      CYGPKG_OPENSSL_MD5 ||
                      (CYGPKG_OPENSSL_MDC2 && CYGPKG_OPENSSL_DES) ||
                      (CYGPKG_OPENSSL_MD2)
  Possible solution:
    CYGPKG_OPENSSL_MD5 -> 0
C CYGPKG_OPENSSL, "requires" constraint not satisfied: CYGPKG_OPENSSL_BUFFER
  Possible solution:
    CYGPKG_OPENSSL_BUFFER -> 0

~>ecosconfig --version
ecosconfig 1.5.2 (Oct 31 2001 10:42:53)
Copyright (c) 2001 Red Hat, Inc.

The correct solution for both of these is -> 1, not 0.

Attached is the ecos.ecc file. Sorry, its huge!

Comment 1 Andrew Lunn 2001-11-14 13:25:47 UTC
Created attachment 37502 [details]
ecos.ecc which makes it go wrong

Comment 2 Bart Veer 2001-12-06 14:17:12 UTC
Created attachment 39867 [details]
Patch for host/tools/configtool/standalone/common/cdl_exec.cxx

Comment 3 Bart Veer 2001-12-06 14:21:59 UTC
The analysis was not quite correct. The code that reported possible
solutions was ignoring the different flavors of CDL options. It
would report the right thing for options with the data flavor,
but not for bool or booldata options. A patch has been attached
and should show up in anoncvs for the next update.


Comment 4 Jonathan Larmour 2001-12-06 16:24:11 UTC
Andrew, feel free to close this when you're happy...
anoncvs will be updated tomorrow if that helps.
Bart, did you build a new ecosconfig binary you could just give Andrew?



Comment 5 Andrew Lunn 2001-12-06 16:39:41 UTC
It not gets the correct answer when check is used.

Should resolve use this answer? When i use the resolve command it just reports
the conflict. If -v is used it reports the solution. But it will not use the
solution. Is the code which uses the solution broken in the same way as the code
that printed the solution?

Comment 6 Bart Veer 2001-12-06 17:04:26 UTC
"ecosconfig resolve" will never overwrite a user setting - the same applies
for all of the configuration technology. In this example the solutions cannot
be applied automatically because both CYGPKG_OPENSSL_BUFFER and
CYGPKG_OPENSSL_MD5 have user values. So it is the user that must apply
the changes.

It would be possible to add a flag to "ecosconfig resolve" giving it
permission to override user values, but I am somewhat reluctant to
give batch tools that much power. Interactive tools such as the GUI
are more suited for such situations.