Fixed crash when linked method are not properly removed. Fixed OSX builder script.