This is the mail archive of the mailing list for the eCos project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: CDL question

John Dallaway wrote:
> The following should work, but there may be a more elegant approach:
>   default_value { (board == "A") ? "A" : "X" }
>   legal_values {
>     ((board == "A") ? "A" : "")
>     ((board == "A") ? "B" : "")
>     ((board == "A") ? "C" : "")
>     ((board == "B") ? "X" : "")
>     ((board == "B") ? "Y" : "")
>     ((board == "B") ? "Z" : "")
>   }


Thank you. I'm sorry, I was being AFK. Hm, your pseudo-CDL code is like
mine. Perhaps, my mixture was too comprecated and I missed the brackets
in the expression, true speaking in my check were many many is_substr()
concatenations, I will try it again.

I will going to try some stupid? thing. I wonder, if I will create some
fake tree (~ecos repository):

|-- ecos.db
|-- baz
|   `-- current
|       `-- cdl
|           `-- baz.cdl
`-- templates
    `-- bar
        `-- current.cdl

and my ecos.db will be contain only single fake target `foo' with
CYGPKG_BAR. Will I be able to validate CDL-pseudo code just using
`ecosconfig' as

ECOS_REPOSITORY=`pwd` ecosconfig new foo bar

Will ecosconfig complain? Well, I'll try it.

Thank you,


Before posting, please read the FAQ:
and search the list archive:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]