Better handling of arguments to the define function.
Add the define.amd property for compatibility with libraries that rely on this being present.