Added a decent require / define implementation