Why not try it and see what obstacles you encounter?
Maybe just the C pre-processor? Or the linker or assembler from binutils?Perhaps you could try a partial build using the NuttX header files only. If you could a relocatable object with just the NuttX header files, then you could link that in later.