git: merge r29036
authorJo-Philipp Wich <jow@openwrt.org>
Sun, 13 Nov 2011 18:35:03 +0000 (18:35 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Sun, 13 Nov 2011 18:35:03 +0000 (18:35 +0000)
SVN-Revision: 29037

net/git/Makefile
utils/usb-modeswitch-data/Makefile
utils/usb-modeswitch/Makefile
utils/usb-modeswitch/files/modeswitch.hotplug

index f77c985b4b6f2aafe064b714f874e000df46c3fb..8ea41061a295bf3815a4566b2b2c8d93ab4e0f09 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=git
 PKG_VERSION:=1.7.5.2
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=@KERNEL/software/scm/git
@@ -64,6 +64,7 @@ endef
 define Package/git/install
        $(INSTALL_DIR) $(1)
        $(CP) $(PKG_INSTALL_DIR)/* $(1)/
+       ln -s /usr/bin/git $(1)/usr/libexec/git-core/git
 endef
 
 $(eval $(call BuildPackage,git))
index ed579c06c20385d89a5a53b6f19cd82fee0f3f1c..d21a2ca9c1b2fbe6df49ba13eba28b8ba2152cdf 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2010 OpenWrt.org
+# Copyright (C) 2010-2011 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=usb-modeswitch-data
-PKG_VERSION:=20110705
+PKG_VERSION:=20111023
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=http://www.draisberghof.de/usb_modeswitch/
-PKG_MD5SUM:=5046e7be8d10d2fe699f9af21a0c3769
+PKG_MD5SUM:=6e7cb67d0428bda241600b038ba11aeb
 
 include $(INCLUDE_DIR)/package.mk
 
index 411f0a5eab2852e6432061e25d8d10abc117f641..c033c7291404ecf1c7ef5e048d3155b2179de4dd 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2008-2010 OpenWrt.org
+# Copyright (C) 2008-2011 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=usb-modeswitch
-PKG_VERSION:=1.1.8
-PKG_RELEASE:=1
+PKG_VERSION:=1.2.0
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=http://www.draisberghof.de/usb_modeswitch
-PKG_MD5SUM:=1aaaa45e0465843e4973d7778bfbafbb
+PKG_MD5SUM:=1932ab96d6e3c5e0a6bdfac863338627
 
 include $(INCLUDE_DIR)/package.mk
 
index 1aecb1fb3150da9b28cbed8d3057b208a5836e50..8042451373b57bd13a714923fd17243127460ecd 100644 (file)
@@ -120,7 +120,20 @@ if [ "$ACTION" = add ]; then
                # If a candidate is remaining, start usb-modeswitch
                [ -n "$configs" ] && {
                        log "$DEVICENAME: Selecting ${configs%% *} for mode switching"
-                       $modeswitch -c "${configs%% *}"
+                       # ugly workaround, but working for all hw we got for testing
+                       switching_done=0
+                       switching_tries=0
+                       local usb_dir="/sys/$DEVPATH"       
+                       [ -f "$usb_dir/idVendor" ] || usb_dir="${usb_dir%/*}"
+                       while [ $switching_done -lt 1 -a $switching_tries -le 6 ]; do
+                               $modeswitch -I -D -n -s 30 -c "${configs%% *}"
+                               if [ $(sanitize "$usb_dir/idProduct") = $uPid ]; then
+                                       log "switching seemingly failed"
+                               else
+                                       switching_done=1
+                               fi
+                               switching_tries=$(( $switching_tries + 1 ))
+                       done
                }
        }
 fi