Rim brakes need an appropriate braking surface on the rim -- if you apply rim brakes to a rim which doesn't have an appropriate braking surface, it'll wear down the rims quickly to be unsafe to ride on (or possibly damage the rims in other ways).
Disc brakes need a hub that can mount a disc rotor.
As you can note from the two points above, they're basically independent requirements -- you can easily build a wheel which has a rim suitable for rim brakes and a disc brake hub so you can use disc brakes.
People do build and sell wheels with a disc brake hub and a rim suitable for rim brakes. These used to be more common than they are now since disc brakes are cheap, but you can still find them.
The question of why you want one is another matter -- in the past, it was relatively common to find bikes spec'd with rim brakes from the factory, but the frames were suitable for mounting a disc brake (for the user to upgrade). These days, a lot of bikes that would have come in that configuration have dropped the rim brake bosses and just gone disc brake only to begin with because the public expects discs.
In regards to the edit: " I want to get new wheels, and I want to be able to swap them between frames. I don't want to convert all my frames to disc brakes, but I do want parts compatible between all my bikes."
Obviously, you need to make sure all bikes can physically accept the wheels ( compatible frame spacing, rim size are the main things; if you had a more specialized case e.g. 1 bike using regular QR and another thru axles, you'd know about that and deal with it; EDIT: Carel has done more details in the comments for road bikes, for example).
But even assuming this is the case, you may not want to do this. Why? Usually, the (non-custom) wheels that are sold this way are on the low end of the quality spectrum (which raises reliability issues). If you are going to build custom wheels this way, you can get very good wheels BUT there is a decent likelihood that you could get a good disc wheel and a good rim wheel for less than the cost of going custom, unless you have special needs (e.g. you're very heavy).