Restore #pragma weak main when main defined