The first step would be to generate an html version of your data. A quick search found
this script (their server was down when I looked, but the Google cache is
here).
Once you have the data in html format, import it into Sigil then save as an ePub.