So you are trying to compile NuttX and when you run tools/configure.sh you got this error message:
Kconfig:2299: can't open file "/Kconfig"
make: *** [tools/Unix.mk:680: olddefconfig] Error 1
ERROR: failed to refresh
This basically means you have the nuttx/ directory but you don’t have apps/ directory at the same directory. Just clone nuttx-apps as apps and enter inside nuttx and try again.
Source: https://nuttx.yahoogroups.narkive.com/CFSEJETF/make-menuconfig-can-t-open-file-kconfig