yield.pl: selfconfiguring instead of using arguments

It also adds more checks and error messages regarding correct setup in h/cpp files