Примеры SED: http://sed.sourceforge.net/sed1line.txt
Получение только нужного куска строки, например путей начинающихся с /var:
cat /etc/passwd | sed -nr 's@^.*(/var[^ :]*).*$@\1@p'
Пересборка skeleton
#/bin/sh
echo pre build cleanup script
echo removing stamps, output/target, output/images,
find -name .stamp_target_installed | xargs rm
rm -rf output/target
rm -rf output/images/
rm output/build/.root
rm output/stamps/ct-ng-toolchain-installed
echo build your target now. e.g. \"make\" or \"make linux-reconfigure\" to rebuild the kernel
Источник: Buildroot is a set of Makefiles and patches that makes it easy generate a cross-compilation toolchain and root filesystem for your target Linux system using the uClibc C library.