code: public Content getPackageLink(PackageDoc pkg, Content label) {
          boolean included = pkg != null && pkg.isIncluded();
          if (! included) {
              for (PackageDoc p : configuration.packages) {
                  if (p.equals(pkg)) {
                      included = true;
                      break;
                  }
              }
          }
          if (included || pkg == null) {
              return getHyperLink(pathString(pkg, DocPaths.PACKAGE_SUMMARY),
                      label);
          } else {
              DocLink crossPkgLink = getCrossPackageLink(utils.getPackageName(pkg));
              if (crossPkgLink != null) {
                  return getHyperLink(crossPkgLink, label);
              } else {
                  return label;
              }
          }
      }
docs: Return the link to the given package.
  
  @param pkg the package to link to.
  @param label the label for the link.
  @return a content tree for the package link.