Configure snap-py on MacOS

I had the same issue. Since I don’t have gcc installed, I added the line void JPy_free(); to the top of src/main/c/jni/org_jpy_PyLib.c, and then clang compiled correctly. Note: I used anaconda python, and some things with brew.

Note: make sure to run the python setup.py install command.

Some notes on a further issue I had that I want to dump in case it’s helpful to anyone.

After I installed when trying to import the library, I got the following output:
`Python 3.6.13 | packaged by conda-forge | (default, Sep 23 2021, 07:55:15)
[GCC Clang 11.1.0] on darwin
Type “help”, “copyright”, “credits” or “license” for more information.

import snappy
No Java runtime present, requesting install.`

I was using openjdk15. The most important change seemed to be switching to openjdk8 (see How can I install java openjdk 8 on High Sierra or newer macOS - Ask Different). Remember to update your java environment paths, and I reran the install command to be safe.

Some other things I did that may or may not have helped:
I added m.dylib as an option as in Snappy installation on OS.X Sierra failing (or asking for legacy Java SE 6) - #2 by forman

I also removed the jre paths in jpyconfig.py.