#!/bin/sh if [ -f /lib/modules/$(uname -r)/build/Makefile ];then default="/lib/modules/$(uname -r)/build" else default="/usr/src/linux" fi default=${LINUXDIR:=$default} if [ "${interactive}" = "y" ];then echo -n "Enter location of Linux source tree [$default]: " read LINUXDIR fi : ${LINUXDIR:=$default} if [ ! -f "$LINUXDIR/.config" ];then echo echo Kernel source tree at $LINUXDIR is not configured echo Fix before continuing echo exit 1 fi if [ ! -f "$LINUXDIR/.hdepend" ];then echo echo You need to run \'make dep\' on the kernel source before echo continuing. echo exit 1 fi echo using LINUXDIR=$LINUXDIR export LINUXDIR . $LINUXDIR/.config # # check for a bad situation # if [ "$CONFIG_MODULES" = "n" ] then cat <>.buildvars else echo "FLAT_MODULES := yes" >>.buildvars fi