Here is an easy way to make a Hirth joint with Inkscape and the perforate module I made for Openscad.
First I made a square in Inkscape and stretched it out so it was a diamond shape:
Then I imported it into openscad and used the perforate module to arrange the pattern:
Next I used the circle module to make a cylinder the size I needed for the outside and a cylinder for the hole in the center, and used difference to subtract the pattern from the circle:
It's also pretty easy to change the profile:
Here is an experimental bolt or screw head with a hirth joint as the driver: