According to the documentation, Saxon accepts a collation URI in the form http://saxon.sf.net/collation?rules=xxxxx, where xxxxx gives the collation rules in the format defined for a Java RuleBasedCollation. In practice, this doesn't work. The rules will almost invariably include special characters, meaning that they have to be percent-encoded to create a valid URI, and Saxon is not applying percent-decoding before passing the value to Java.
A patch is being raised for the 9.1 and 9.2 branches. Once fixed, the attachment to this bug shows a stylesheet that uses the facility successfully (it establishes a collation in which N precedes M).