BUG: linalg: do not assume that GIL is enabled in xerbla_

With the new ufunc-based linalg, GIL is released in ufuncs, and needs to
be reacquired when raising errors in xerbla_.
BUG: linalg: fix LAPACK error handling in lapack_litemodule

If an exception is pending (raised from xerbla), the routines must
return NULL.
Merge pull request #3712 from juliantaylor/lapack-errors

backport Lapack error handling to 1.7.x