Here’s the complete code.  This should go in your master stylesheet that is shared by all the languages (i.e., layer-2.dsl).
In the first line, we define a new variable.  This variable is boolean, and will be used to determine whether or not the link should be created.  It defaults to false, so we retain backwards compatability.  After looking at the other code relating to refentry’s, the name %refentry-xref-link% seemed like a good choice.

In the second line we define a function.  This function’s purpose is to generate the URL that will be used in the link.  At the moment, all this function does is return the empty string.  This is because it is the responsibility of the per-language stylesheets to define their own version of this function that can do the right thing.

The new code for the citerefentry element is obviously the most complex thing here at first glance.  But it’s really quite simple.  First, we create a new variable called href, which is set to the return value of the $create-refentry-xref-link$ function.  Then we check to see whether or not a link should actually be created.  If it shouldn’t, then control jumps down to the bottom, and we’re in code that’s straight from the original definition of citerefentry.
If the link should be created then we make an HTML A element, setting the HREF attribute to the contents of the href variable.  Then, again, we jump in to code copied from the original citerefentry definition, to choose whether or not to put the results in italic.