Test fix.

+review REVIEW-5058
Better search for JDK homes on Ubuntu.

Use canonicalized paths to match Java home with one reported by JVM.
Inject FunctionalSourceSet into ComponentSpec at creation time

- introduce ComponentSpecInternal to access "mainSourceSet"

+review REVIEW-5076
add some test coverage for DefaultLibrarySpec

+review REVIEW-5076
More speccing of the conflict resolution. Fixed the guava-collections typos. Tidied up the mock-up DSL.
fix component reporting

+review REVIEW-5076
Addressing open issues for 'Make branch attribute available when publishing and resolving Ivy modules'

- Adding ivyStatus to IvyModuleDescriptor
- Adding validation for status
+review REVIEW-5059
Changed the method signature so that it returns ModuleVersionIdentifier instead of String. I will need this later. Also it just makes sense to avoid duplicating formatting of the mvi.
Removed redundant getSelectedId() since we have getId() method. 'Selected' is implied so I don't think there's a reason to keep the second method that returns the same information.
Decoupled most parts of conflict resolution from the dependency graph builder. This is needed to make place for improvements in conflict resolution (module replacements).

1. Responsibilities pushed out:
 - the decision when conflict occurs
 - the selection of a version from candidates (it is still delegated to the respective resolver)
 - the choice of modules that are involved in the conflict resolution
2. This refactoring does not change the existing behavior. It will be easier to grow the conflict-resolution features when decoupled from DependencyGraphBuilder
3. The complexity was pushed to a separate package. Classes from that package don't use DependencyGraphBuilder internals. DependencyGraphBuilder talks to the conflict resolution via interfaces (mostly).
Took a first stab at module replacements. The information about replacements is passed via dependency resolve rules but it can be changed. It was an clean way to get the information into the DependencyGraphBuilder. Nothing was added to the public API yet. Please review if the direction makes sense.
REVIEW-5057 Turn CancellationTokenSource into interface.
Only run UbuntuJvmLocatorTest w/ links on Linux.
Simplify 'can cancel distribution download' test a bit.
Graceful HttpServer shutdown for test that cancels download.
Mention contributions in release notes
+ review REVIEW-5063
REVIEW-5073 Drop callback references after cancel() is processed.

Some minor tweaks (comments).
Addressing open issues for 'Make branch attribute available when publishing and resolving Ivy modules'

- Adding support for publishing extra info elements
- Change extra info map to use composite key for namespacing
+review REVIEW-5059
Addressing open issues for 'Make branch attribute available when publishing and resolving Ivy modules'

- Adding documentation
- Tweaking tests
+review REVIEW-5059
Adding some verbiage to the release notes about extra info elements and withXML closures.

+review REVIEW-5059