[PATCH v2] tools/nolibc: fix missing strlen() definition and infinite loop with gcc-12