You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@mynewt.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2017/02/05 20:19:42 UTC

[jira] [Commented] (MYNEWT-558) newt - depgraph should indicate soft vs. hard dependency

    [ https://issues.apache.org/jira/browse/MYNEWT-558?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15853343#comment-15853343 ] 

ASF subversion and git services commented on MYNEWT-558:
--------------------------------------------------------

Commit e4ac2617615ad95fc5b56591b2576fc0ee978332 in incubator-mynewt-newt's branch refs/heads/develop from [~ccollins476]
[ https://git-wip-us.apache.org/repos/asf?p=incubator-mynewt-newt.git;h=e4ac261 ]

MYNEWT-558 newt - depgraph should show api / hard

The `target dep` and `target revdep` commands only indicated package
names in the dependency graph.  This change enhances the output of these
commands to show what created the dependency in the first place.
Specifically, they now show whether the dependency is "hard" (package
explicitly depends on another) or "soft" (package requires an API; other
package happens to implement that API).  This is useful when trying to
completely remove a package from a build.

In the future, we should also indicate which, if any, syscfg settings
generated a particular dependency.

The fix required a lot of changes to the newt code.  The major change
was to scale back the responsibilities of the pkg.LocalPackage type.
This struct was being used during build and depgraph resolution, and its
client relied on its inheritance of the pkg.Package interface.
Consequently, it was difficult to add new features without breaking
everything or bloating the LocalPackage struct.

Now, instances of LocalPackage get converted to resolve.ResolvePackage
during dependency and API resolution.  Furthermore, builder.BuildPackage
and resolve.ResolvePackage no longer inherit from LocalPackage.
Instead, each contains a pointer to its corresponding LocalPackage or
ResolvePackage.  Since these types never need to be treated as generic
package types, the code is simplified by eliminating these edges from
the inheritance tree.


> newt - depgraph should indicate soft vs. hard dependency
> --------------------------------------------------------
>
>                 Key: MYNEWT-558
>                 URL: https://issues.apache.org/jira/browse/MYNEWT-558
>             Project: Mynewt
>          Issue Type: Bug
>            Reporter: Christopher Collins
>            Assignee: Christopher Collins
>             Fix For: v1_0_0_rel
>
>
> The `target dep` and `target revdep` commands only indicate package names in the dependency graph.  It would be helpful to see what created the dependency in the first place.  Specifically, it would be good to know if the dependency is "hard" (package explicitly depends on another) or "soft" (package requires an API; other package happens to implement that API).  This is useful when trying to completely remove a package from a build.
> Unfortunately, this information is lost at the time dependency graphs are generated.  Rather than use a builder's package map, dependency generation should operate on an intermediate form produced by the `resolve` package. 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)