|
|
|
@ -1,5 +1,7 @@ |
|
|
|
|
#!/bin/sh |
|
|
|
|
# |
|
|
|
|
# linux-wlan-ng/Configure |
|
|
|
|
# |
|
|
|
|
# Adapted from the pcmcia-cs/Configure file, license statement below: |
|
|
|
|
# |
|
|
|
|
# Configure 1.110 1999/06/24 17:37:36 |
|
|
|
@ -18,7 +20,6 @@ |
|
|
|
|
# <dhinds@hyper.stanford.edu>. Portions created by David A. Hinds |
|
|
|
|
# are Copyright (C) 1998 David A. Hinds. All Rights Reserved. |
|
|
|
|
#------------------------------------------------------------------------- |
|
|
|
|
# linux-wlan-ng/Configure |
|
|
|
|
# |
|
|
|
|
# TODO: Since we're dependent on configured pcmcia source, we should change |
|
|
|
|
# this such that it will ask for the pcmcia source dir and then read |
|
|
|
@ -34,9 +35,8 @@ fail () |
|
|
|
|
exit 1 |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -r config.out ]; then |
|
|
|
|
. ./config.out 2> /dev/null |
|
|
|
|
. ./config.out 2>/dev/null |
|
|
|
|
else |
|
|
|
|
if [ ! -r config.in ]; then |
|
|
|
|
$ECHO "config.in does not exist!" |
|
|
|
@ -45,8 +45,15 @@ else |
|
|
|
|
. ./config.in |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
PROMPT=y |
|
|
|
|
if [ $# -gt 0 ] ; then |
|
|
|
|
if [ "$1" = "-d" ] ; then |
|
|
|
|
PROMPT=n |
|
|
|
|
if [ $# -gt 1 -a -r $2 ]; then |
|
|
|
|
. ./$2 |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
arg () { |
|
|
|
|
VALUE="`$ECHO X"$2" | sed -e 's/^X--[a-zA-Z_]*=//'`" |
|
|
|
@ -54,7 +61,9 @@ arg () { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
usage () { |
|
|
|
|
$ECHO "usage: $0 " |
|
|
|
|
echo "usage: Configure [-d <filename>]" |
|
|
|
|
echo "" |
|
|
|
|
echo " -d <filename> read configuration data from file" |
|
|
|
|
exit 1 |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -62,7 +71,7 @@ usage () { |
|
|
|
|
|
|
|
|
|
CONFIG=config.new |
|
|
|
|
CONFIG_MK=config.mk |
|
|
|
|
rm -f .prereq.ok $CONFIG $CONFIG_MK $MODVER |
|
|
|
|
rm -f $CONFIG $CONFIG_MK $MODVER |
|
|
|
|
|
|
|
|
|
cat << 'EOF' > $CONFIG |
|
|
|
|
# |
|
|
|
@ -238,10 +247,11 @@ write_str TARGET_INST_EXEDIR |
|
|
|
|
|
|
|
|
|
$ECHO "" |
|
|
|
|
|
|
|
|
|
SYSV_INIT=n |
|
|
|
|
if [ "$PREFIX" = "" ] ; then |
|
|
|
|
if [ -d /etc/rc.d/init.d -o -d /etc/init.d -o -d /sbin/init.d ] ; then |
|
|
|
|
$ECHO "It looks like you have a System V init file setup." |
|
|
|
|
SYSV_INIT=y |
|
|
|
|
SYSV_INIT=n |
|
|
|
|
if [ -d /etc/rc.d/init.d ] ; then |
|
|
|
|
$ECHO "RC_DIR=/etc/rc.d" >> $CONFIG |
|
|
|
|
$ECHO "RC_DIR=/etc/rc.d" >> $CONFIG_MK |
|
|
|
@ -259,7 +269,7 @@ if [ "$PREFIX" = "" ] ; then |
|
|
|
|
"/etc/rc.d/rc.wlan (for ISA/PCMCIA cards)" |
|
|
|
|
$ECHO " so that wlan cards will be started at boot time." |
|
|
|
|
fi |
|
|
|
|
SYSV_INIT= |
|
|
|
|
SYSV_INIT=n |
|
|
|
|
fi |
|
|
|
|
write_bool SYSV_INIT |
|
|
|
|
else |
|
|
|
@ -276,7 +286,9 @@ $ECHO "" |
|
|
|
|
#======================================================================= |
|
|
|
|
# Make sure our target architecture is the same as our build architecture. |
|
|
|
|
|
|
|
|
|
WLAN_INSTALL_TYPE=sta |
|
|
|
|
if [ ! WLAN_INSTALL_TYPE ] ; then |
|
|
|
|
WLAN_INSTALL_TYPE=sta |
|
|
|
|
fi |
|
|
|
|
ask_str "Install drivers as station (sta) or access point (ap)?" WLAN_INSTALL_TYPE |
|
|
|
|
|
|
|
|
|
#======================================================================= |
|
|
|
@ -326,10 +338,6 @@ ask_bool "Build for Kernel PCMCIA?" WLAN_KERN_PCMCIA |
|
|
|
|
|
|
|
|
|
mv $CONFIG config.out |
|
|
|
|
|
|
|
|
|
touch .prereq.ok |
|
|
|
|
|
|
|
|
|
$ECHO "" |
|
|
|
|
$ECHO "Configuration successful." |
|
|
|
|
$ECHO "" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|