If you plan to build yourself, it might make sense to get some background info on wheelbuilding, such this site I like:
https://spokecalc.io/articles.php
You will have to dish the wheel in front if it has disc brakes, The back wheel also needs dish ("offset" of the rims from being directly between the spoke flanges). You also need to choose a lacing pattern (3 cross most common on MTB). The type of axle has no direct effect on spoke length. It is all about hub measurements (width, position of spoke flanges, and diameter of flanges)
I build my own wheels. It is not too difficult, but one needs to understand the process, make careful measurements of the hubs and rims to get accurate spoke lengths, and then develop a process for truing the wheel. Patience helps. To build your own wheel, you will need some sort of truing stand (doesn't have to be top of the line if you use it carefully), a spoke tension meter, and spoke wrenches. I also like using a dishing tool.
Hope that helps
Emmit