Building openCV from either Jetsonhacks and Jkjung results an error

I’ve been strugling for days, I’ve tried to follow instructions by jkjung and Jetsonhacks to install opencv on the Jetson TX2, but everytime it came to the building step and results an error:

Configuring incomplete, errors occurred!

Here is the CMakeOutput.log:

And the CMakeError.log:

Thanks in advance

On r32.3.1, it is OpenCV4.1.1 with WITH_GSTREAMER=ON after SDKManager installation. If you need CUDA functions, please try re-install through the script: