Add __assert_func

* issue #692
Add __assert_func only if DEBUG=1
Make __assert_func weak
Merge pull request #693 from iabdalkader/assert

Add __assert_func