Depending on modules you’re trying to compile from outside of kernel dirs, maybe you can face the following erros:
Building modules, stage 2. MODPOST 1 modules /bin/sh: scripts/mod/modpost: not found make: *** [__modpost] Error 127 make: Target `_modpost’ not remade because of errors. make: *** [modules] Error 2
The trouble can be fixed by doing the following sequence commands in the kernel source directory.
# cd /usr/src/linux # make modules_prepare