We consider the two-layer form of the planetary geostrophic equations, in which a simple Rayleigh friction replaces the inertia, on a western continental slope. In the frictionless limit, these equations can be written as characteristic equations in which the potential vorticities of the top and bottom layers play the role of Riemann invariants. The general solution is of two types. In the first type, the characteristics can cross, and friction is required to resolve the resulting shocks. In the second type, one of the two Riemann invariants is uniform, the remaining characteristic is a line of constant f/H, and the solutions take a simple explicit form. A solution resembling the Gulf Stream can be formed by combining three solutions of the second type. Compared to the corresponding solution for homogeneous fluid, the Gulf Stream and its seaward countercurrent are stronger, and the latter is concentrated in a thin frictional layer on the eastern edge of the Stream.