Compiling scikit-geometry for Dynamo

i’ll pull this out of the other python package thread, maybe someone here has some insight to help: I’m trying to build the scikit-geometry python module from source not using anaconda to see if i can use it in Dynamo.

it builds correctly and i’m able to use the library through Anaconda (the specific thing i’m after is the straight skeleton algorithm), so this does what i need it to, i just have to hook the parts together… i’ve built CGAL according to the manual using vcpkg, but the scikit-geometry instructions just say

CGAL 5.0 needs to be available

when i run

python -m pip install -e . -v

to build the package, it fails with some errors indicating that it can’t find CGAL (see attachment) i have a short list of things to try, but i am in a bit over my head.
any recommendations?

scikit-geometry_installation_failure_log.txt (6.4 KB)

dug into this some more. looking into setup.py (identified as the failing script in error log, above), it seems like the initial search for CGAL looks for a conda environment, which dynamo’s embedded python doesn’t have.

it has some ‘backup’ paths to search, but i think the above issue stems from the fact that they are linux/unix formatted paths

conda_prefix = os.getenv('CONDA_PREFIX')
if not conda_prefix:
    conda_prefix = os.getenv('MINICONDAPATH')

if conda_prefix:
    cgal_include = os.path.join(conda_prefix, 'include', 'CGAL')

    if not os.path.exists(cgal_include):
        cgal_include = os.path.join(conda_prefix, 'Library', 'include', 'CGAL')
        include_dirs.append(os.path.join(conda_prefix, 'Library', 'include'))
elif os.path.exists(**'/usr/include/CGAL/'**):
    cgal_include = **'/usr/include/CGAL/'**
elif os.path.exists(**'/opt/homebrew/include/CGAL/'**):
    cgal_include = **'/opt/homebrew/include/CGAL/'**
else:
    cgal_include = **'/usr/local/include/CGAL/'**

so i guess i could add an elif for my designated path? probably better to try and at least make it build the user path.