Using --with-sysroot alone is enough to let pkgconf's configure script figure out the sysroot from the compiler, and since you've already passed --with-sysroot="$ROOTFS" to the compiler (to test it, run $CC --print-sysroot and see if you get $ROOTFS), there's no need to specify sysroot here.
From pkgconf's configure scripts
--with-sysroot[=DIR] Search for dependent libraries within DIR (or the compiler's sysroot if not specified).
Using
--with-sysroot
alone is enough to let pkgconf's configure script figure out the sysroot from the compiler, and since you've already passed--with-sysroot="$ROOTFS"
to the compiler (to test it, run$CC --print-sysroot
and see if you get$ROOTFS
), there's no need to specify sysroot here.From pkgconf's configure scripts