Strange compile errors

I am trying to build mxnet from source and I get a couple of strange errors.

The first error is this

Running: OpWrapperGenerator.py
argument "begin" of operator "slice" has unknown type "tuple of <>, required"
argument "end" of operator "slice" has unknown type "tuple of <>, required"
argument "step" of operator "slice" has unknown type "tuple of <>, optional, default=[]"
argument "end" of operator "slice_axis" has unknown type ", required"

This then results in the tests and the cpp examples failing to build as the function signature for slice doesn’t have any types for the begin and end parameters.

The second error occurs when trying to build the cython modules

/usr/bin/cmake -E env MXNET_LIBRARY_PATH=/home/bidski/Projects/mxnet/build/libmxnet.so 
/usr/bin/python3 setup.py build_ext --inplace --with-cython
free(): invalid pointer
Child aborted

The error seems to occur when on this line of python/setup.py. Which kicks off a massive chain of imports in python/mxnet, but I have yet to track down exactly what it causing the error. My assumption is that somewhere along the line, the mxnet library is being loaded and that is causing the error, but as i haven’t been able to track down the exact source I have nothing to back this assumption up.

I have made some changes to the CMake build system in an attempt to resolve some of other build issues I have been having, so I am not sure if I have messed something up in the build system or if this is some other issue that I just haven’t seen before.

Has anyone ever seen either of these issues before, or have I screwed something up mightily?