I notice that your STM8 port seems to rely on the STM8S peripheral library from ST.
Do you know if this will run on an STM8L? I haven't used an S-series part before, so before I did the research to find out how compatible they are I figured I'd ask. -Spencer