replace exec by eval to ensure the c variable is defined for all relevant python versions
Merge pull request #3229 from jdkloe/master

Fix for issue 3192