diff options
Diffstat (limited to 'contrib')
10 files changed, 26 insertions, 372 deletions
diff --git a/contrib/package/community-profiles/files/etc/config/profile_potsdam b/contrib/package/community-profiles/files/etc/config/profile_potsdam index c15624a9fd..9bdb603239 100644 --- a/contrib/package/community-profiles/files/etc/config/profile_potsdam +++ b/contrib/package/community-profiles/files/etc/config/profile_potsdam @@ -1,19 +1,35 @@ config 'community' 'profile' option 'name' 'Freifunk Potsdam' option 'homepage' 'http://potsdam.freifunk.net' - option 'ssid' 'www.freifunk-potsdam.de' + option 'ssid' 'Freifunk-Potsdam-XXX-YYY' option 'mesh_network' '10.22.0.0/16' option 'splash_network' '192.168.22.0/24' option 'splash_prefix' '24' option 'latitude' '52.39349' option 'longitude' '13.06489' + option 'ipv6' '0' + +config 'defaults' 'interface' + option 'netmask' '255.255.0.0' + option 'dns' '85.214.20.141 213.73.91.35 194.150.168.168' + option 'delegate' '0' config 'defaults' 'wifi_device' option 'channel' '5' +config 'defaults' 'wifi_device_5' + option 'channel' '44' + config 'defaults' 'bssidscheme' option '5' '02:CA:FF:EE:BA:BE' + option '44' '02:CA:FF:EE:BA:BE' -config 'defaults' 'interface' - option 'dns' '85.214.20.141 213.73.91.35 194.150.168.168' +config 'defaults' 'ssidscheme' + option '5' 'Mesh23' + option '44' 'Mesh23' + +config 'defaults' 'dhcp' + option 'leasetime' '15m' +config 'defaults' 'olsrd' + option 'LinkQualityAlgorithm' 'etx_ffeth' diff --git a/contrib/package/freifunk-common/Makefile b/contrib/package/freifunk-common/Makefile index d9bbd994a1..2b9336fb06 100644 --- a/contrib/package/freifunk-common/Makefile +++ b/contrib/package/freifunk-common/Makefile @@ -4,7 +4,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=freifunk-common -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) diff --git a/contrib/package/freifunk-common/files/etc/config/freifunk b/contrib/package/freifunk-common/files/etc/config/freifunk index 9a46f056ad..b1a2e41e2a 100644 --- a/contrib/package/freifunk-common/files/etc/config/freifunk +++ b/contrib/package/freifunk-common/files/etc/config/freifunk @@ -104,12 +104,6 @@ config 'defaults' 'wifi_iface' option 'bssid' '12:CA:FF:EE:BA:BE' option 'mcast_rate' '6000' -config 'defaults' 'madwifi_wifi_iface' - option 'bgscan' '0' - option 'sw_merge' '1' - option 'probereq' '1' - option 'mcast_rate' '5500' - config 'defaults' 'interface' option 'netmask' '255.255.0.0' option 'dns' '8.8.8.8 212.204.49.83 141.1.1.1' diff --git a/contrib/package/meshwizard/Makefile b/contrib/package/meshwizard/Makefile index 9ac5a06286..62983465c1 100644 --- a/contrib/package/meshwizard/Makefile +++ b/contrib/package/meshwizard/Makefile @@ -4,7 +4,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=meshwizard -PKG_RELEASE:=0.3.2 +PKG_RELEASE:=0.3.3 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) diff --git a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/rename-wifi.sh b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/rename-wifi.sh index e9139ed510..f2d10cc9e2 100755 --- a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/rename-wifi.sh +++ b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/rename-wifi.sh @@ -1,6 +1,6 @@ #!/bin/sh # This script renames IB_wifi_ interface names into real interface names used on this system. -# E.g. wireless.IB_wifi0 would become wireless.wifi0 on madwifi and wireless.radio0 on mac80211 +# E.g. wireless.IB_wifi0 would become wireless.radio0 on mac80211 . $dir/functions.sh diff --git a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_olsrd.sh b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_olsrd.sh index 01a93874ab..9ebcb46b13 100755 --- a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_olsrd.sh +++ b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_olsrd.sh @@ -73,7 +73,7 @@ setup_nameservice() { uci batch <<- EOF set $cfg.olsrd_nameservice=LoadPlugin - set $cfg.olsrd_nameservice.library="olsrd_nameservice.so.0.3" + set $cfg.olsrd_nameservice.library="olsrd_nameservice.so.0.4" set $cfg.olsrd_nameservice.latlon_file="$llfile" set $cfg.olsrd_nameservice.hosts_file="$hosts" set $cfg.olsrd_nameservice.sighup_pid_file="/var/run/dnsmasq.pid" @@ -118,7 +118,7 @@ setup_jsoninfo() { proto="$1" uci batch <<- EOF set $cfg.olsrd_jsoninfo=LoadPlugin - set $cfg.olsrd_jsoninfo.library="olsrd_jsoninfo.so.0.0" + set $cfg.olsrd_jsoninfo.library="olsrd_jsoninfo.so.1.1" EOF if [ "$proto" = "6" ]; then uci set $cfg.olsrd_jsoninfo.ipv6only='1' @@ -130,7 +130,7 @@ setup_txtinfo() { proto="$1" uci batch <<- EOF set $cfg.olsrd_txtinfo=LoadPlugin - set $cfg.olsrd_txtinfo.library="olsrd_txtinfo.so.0.1" + set $cfg.olsrd_txtinfo.library="olsrd_txtinfo.so.1.1" EOF if [ "$proto" = "6" ]; then uci set $cfg.olsrd_txtinfo.ipv6only='1' diff --git a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_wifi.sh b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_wifi.sh index 41feb86651..707b7b72cd 100755 --- a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_wifi.sh +++ b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/setup_wifi.sh @@ -59,11 +59,6 @@ uci set wireless.$net\_iface=wifi-iface # create new wifi-iface for $net from defaults set_defaults "wifi_iface_" wireless.$net\_iface -# overwrite some settings for type atheros (madwifi) -if [ "$type" = "atheros" ]; then - set_defaults "madwifi_wifi_iface_" wireless.${net} -fi - # overwrite defaults bssid="$($dir/helpers/gen_bssid.sh $channel $community)" diff --git a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/supports_vap.sh b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/supports_vap.sh index 0585ab5fe1..7fdff3c566 100755 --- a/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/supports_vap.sh +++ b/contrib/package/meshwizard/files/usr/bin/meshwizard/helpers/supports_vap.sh @@ -8,9 +8,7 @@ if [ -z "$dev" -o -z "$type" ]; then exit 1 fi -if [ "$type" = "atheros" ]; then - exit 0 -elif [ "$type" = "mac80211" ]; then +if [ "$type" = "mac80211" ]; then # not hostapd[-mini], no VAP if [ ! -x /usr/sbin/hostapd ]; then echo "WARNING: hostapd[-mini] is required to be able to use VAP with mac80211." diff --git a/contrib/package/remote-update/Makefile b/contrib/package/remote-update/Makefile deleted file mode 100644 index 4f8b3a596b..0000000000 --- a/contrib/package/remote-update/Makefile +++ /dev/null @@ -1,43 +0,0 @@ -# -# Copyright (C) 2009 Jo-Philipp Wich <jow@openwrt.org> -# -# This is free software, licensed under the Apache 2.0 license. -# - -include $(TOPDIR)/rules.mk - -PKG_NAME:=remote-update -PKG_RELEASE:=4 - -PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) - -include $(INCLUDE_DIR)/package.mk - -define Package/remote-update - SECTION:=luci - CATEGORY:=LuCI - SUBMENU:=9. Freifunk - TITLE:=Freifunk remote update utility. - DEPENDS:=@TARGET_atheros||@TARGET_ar71xx||@TARGET_brcm_2_4 -endef - -define Package/remote-update/description - The freifunk remote-update utility uses sysupgrade to reflash the currently - running firmware while keeping most of the existing configuratio. -endef - -define Build/Prepare - mkdir -p $(PKG_BUILD_DIR) -endef - -define Build/Configure -endef - -define Build/Compile -endef - -define Package/remote-update/install - $(CP) ./files/* $(1)/ -endef - -$(eval $(call BuildPackage,remote-update)) diff --git a/contrib/package/remote-update/files/usr/sbin/remote-update b/contrib/package/remote-update/files/usr/sbin/remote-update deleted file mode 100755 index 6e45e482be..0000000000 --- a/contrib/package/remote-update/files/usr/sbin/remote-update +++ /dev/null @@ -1,306 +0,0 @@ -#!/bin/sh - -local tempfile=/tmp/remote-upgrade.img -local D2='\([0-9]\{2\}\)' -local D4='\([0-9]\{4\}\)' -local NL=' -' - -find_architecture() -{ - local ifs="$IFS"; IFS="-" - set -- $(opkg list_installed kernel) - IFS="$ifs" - - echo "$3" -} - -find_image() -{ - case "$1" in - atheros) - echo "openwrt-atheros-combined.squashfs.img" - ;; - ar71xx) - echo "openwrt-ar71xx-combined.squashfs.img" - ;; - brcm) - echo "openwrt-brcm-2.4-squashfs.trx" - ;; - esac -} - -check_image() -{ - local file; for file in /lib/upgrade/*.sh; do . $file; done - if platform_check_image "$1" >/dev/null 2>/dev/null; then - return 0 - fi - return 1 -} - -find_remote_checksum() -{ - wget -qO- ${1%/*}/md5sums 2>/dev/null | \ - sed -ne '/'$2'/ { s/ .*//p }' -} - -find_local_checksum() -{ - set -- $(md5sum "$tempfile") - echo $1 -} - -find_remote_info() -{ - wget -qO- "${1%/*}/VERSION.txt" 2>/dev/null -} - -find_remote_version() -{ - find_remote_info "$1" | \ - sed -ne "s!.*$D4/$D2/$D2 $D2:$D2.*!\\1\\2\\3\\4\\5!p;t" -} - -find_local_version() -{ - if [ -f /rom/etc/banner ]; then - sed -ne "s!.*$D4/$D2/$D2 $D2:$D2.*!\\1\\2\\3\\4\\5!p;t" \ - /rom/etc/banner - else - date +"%Y%m%d%H%M" -r /bin/sh - fi -} - -stop_service() -{ - [ -x /etc/init.d/$1 ] && { - echo -n "Stopping service $1 ... " - /etc/init.d/$1 stop >/dev/null 2>/dev/null - echo "done" - } -} - -do_wait() -{ - if [ ${1:-0} -gt 0 ]; then - echo -n "${2:-Waiting} " - for i in $(seq 1 $1); do - printf "%-2dseconds" $(($1-$i)) - sleep 1 - echo -en "\b\b\b\b\b\b\b\b\b" - done - echo "${NL}" - fi -} - -version_compare() -{ - local v1="$1" - local v2="$2" - - while [ -n "$v1" -o -n "$v2" ]; do - if [ -z "${v2:0:4}" -o "${v1:0:4}" -gt "${v2:0:4}" ]; then - return 1 - elif [ -z "${v1:0:4}" -o "${v1:0:4}" -lt "${v2:0:4}" ]; then - return 2 - fi - - v1="${v1:4}" - v2="${v2:4}" - done - - return 0 -} - -usage() -{ - cat <<EOT - -Usage: - remote-update -h - remote-update [-u <update url>] -c - remote-update [-v] [-y] [-u <update url>] -w - remote-update [-d] [-n] [-v] [-y] [-s <sleep seconds>] [-u <update url>] - -Actions: - -h Display this help message and exit. - -c Check for firmware update and exit. - -w Fetch image and exit, do not perform flash write. - -Options: - -d Do not detach from terminal. - -n Do not backup configuration. - -v Skip verification of downloaded image. - -y Assume defaults for all questions. - - -s <seconds> - Sleep given amount of seconds before starting flash write. - If ommitted and '-y' is not used, 5 seconds are assumed. - - -u <url> - Fetch firmware image from given url. A file "md5sums" is expected - in the same remote directory. If there is no such file, use -v to - suppress verification. - -EOT - - exit 1 -} - - -while getopts "s:u:cdnvwyh" flag; do - case $flag in - s) sleeptime="$OPTARG";; - u) updateurl="$OPTARG";; - c) checkupdate=1;; - d) nodetach=1;; - n) nobackup=1;; - v) noverify=1;; - w) noflash=1;; - y) noquestions=1;; - *) usage;; - esac -done - - -local image_url="$updateurl" -local image_name="${image_url##*/}" - -[ -z "$image_url" ] && { - local arch=$(find_architecture) - local image=$(find_image "$arch") - local repo=$(uci get freifunk.upgrade.repository 2>/dev/null) - repo=${repo:-$(uci get system.upgrade.repository 2>/dev/null)} - - [ -z "$arch" ] && { - echo "Can not determine the current architecture." - exit 1 - } - - [ -z "$repo" ] && { - echo "No repository configured in 'system.upgrade.repository'." - echo "Use the '-u' flag to specify an image location." - exit 1 - } - - [ -z "$image" ] && { - echo "No suitable image for the '$arch' architecture." - echo "Your platform is not supported." - exit 1 - } - - echo "Architecture: $arch" - echo "Repository: $repo" - - image_name="$image" - image_url="${repo%/}/$arch/$image" -} - - -if [ "$checkupdate" = 1 ]; then - local v1=$(find_local_version) - local v2=$(find_remote_version "$image_url") - - [ -n "$v1" -a -n "$v2" ] && { - version_compare "$v1" "$v2" - [ $? == 2 ] && { - echo "Update available!${NL}Local: $v1${NL}Remote: $v2${NL}--" - find_remote_info "$image_url" - exit 0 - } || { - echo "Local version $v1 is up to date" - exit 2 - } - } || { - echo "No remote time stamp found." - exit 1 - } -else - if [ "$noquestions" != 1 ]; then - echo -n "${NL}About to download $image_name. Continue? [y] " - read answer - case "$answer" in - [nN]) exit 1;; - esac - fi - - echo -n "Downloading $image_name ... " - rm -f $tempfile - wget -qO $tempfile "$image_url" 2>/dev/null - [ $? == 0 ] && echo done || { - echo failed - rm -f $tempfile - exit 1 - } - - if [ "$noverify" != 1 ]; then - echo -n "Verifying $image_name ... " - - local md5_remote=$(find_remote_checksum "$image_url" "$image_name") - local md5_local=$(find_local_checksum) - - check_image "$tempfile" - local image_ok=$? - - if [ $image_ok = 0 -a -n "$md5_remote" -a -n "$md5_local" -a "$md5_remote" = "$md5_local" ]; then - echo "done" - else - if [ $image_ok != 0 ]; then - echo "unsupported image type" - else - echo "checksum mismatch! (local:${md5_local:-(none)} remote:${md5_remote:-(none)})" - fi - - local answer=n - if [ "$noquestions" != 1 ]; then - echo -n "${NL}Verification failed. Continue anyway? [n] " - read answer - fi - - case "$answer" in - [yYjJ]*) : ;; - *) - echo "Aborting." - rm -f $tempfile - exit 1 - ;; - esac - fi - fi - - if [ "$noflash" != 1 ]; then - if [ -f "$tempfile" ]; then - if [ "$noquestions" == 1 ]; then - do_wait ${sleeptime:-5} "${NL}About to start flashing, hit <Ctrl-C> to abort!${NL}${NL}Starting in" - else - if [ -z "$nobackup" ]; then - echo -n "${NL}Keep configuration files? [y] " - read answer - case "$answer" in - [nN]) nobackup=1;; - esac - fi - - echo -n "${NL}About to start flashing!${NL}Hit <Enter> to continue or <Ctrl-C> to abort.${NL}" - read answer - fi - - for s in lucid collectd; do stop_service $s; done - - if [ "$nodetach" != 1 ]; then - echo -n "Starting sysupgrade in background ... " - /bin/busybox start-stop-daemon -S -b -x /sbin/sysupgrade -- ${nobackup:+-n} "$tempfile" - echo "done" - else - echo "Executing sysupgrade ... " - exec /sbin/sysupgrade ${nobackup:+-n} "$tempfile" - fi - else - echo "No upgrade image found!" - exit 1 - fi - else - echo "Image saved in '$tempfile'" - fi -fi |