Any ideas on my previous questions?
I manually added --trace --trace-expand to the cmake command line and have noticed that the problem with the version check is that when it tries to compile its little test files to test/extract the version it fails to find the NCCL and CUDA headers. This seems to be a systematic issue with the current PyTorch build that will come up whenever using a locally pre-installed NCCL and CUDA.
In order to get PyTorch to compile in my situation I had to do:
Edit cmake/Modules_CUDA_fix/upstream/FindCUDA.cmake
	Right before: #  End of unset()
	Add line: unset(CUDA_cublas_device_LIBRARY CACHE)

Edit cmake/Modules/FindNCCL.cmake
	Change:
		-  list (APPEND CMAKE_REQUIRED_INCLUDES ${NCCL_INCLUDE_DIRS})
		+  list (APPEND CMAKE_REQUIRED_INCLUDES ${NCCL_INCLUDE_DIRS} ${CUDA_INCLUDE_DIRS})
	Change:
		+          CMAKE_FLAGS "-DINCLUDE_DIRECTORIES=${NCCL_INCLUDE_DIRS};${CUDA_INCLUDE_DIRS}"
		           RUN_OUTPUT_VARIABLE NCCL_VERSION_FROM_HEADER
		-          LINK_LIBRARIES ${NCCL_LIBRARIES})
		+          LINK_LIBRARIES ${NCCL_LIBRARIES} ${CUDA_LIBRARIES})

Edit tools/setup_helpers/cmake.py
	Change: elif var.startswith(('BUILD_', 'USE_', 'CMAKE_')):
	To: elif var.startswith(('BUILD_', 'USE_', 'CMAKE_', 'TENSORRT_')):