developer | 839fc60 | 2023-01-11 19:16:07 +0800 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | echo "clone.........." |
| 3 | git clone --branch master https://gerrit.mediatek.inc/openwrt/lede mac80211_package |
| 4 | git clone --branch master https://gerrit.mediatek.inc/openwrt/feeds/mtk_openwrt_feeds |
| 5 | git clone --branch master https://gerrit.mediatek.inc/gateway/autobuild_v5 |
developer | eab1cd7 | 2023-04-13 20:12:08 +0800 | [diff] [blame] | 6 | git clone --branch master https://gerrit.mediatek.inc/gateway/big_sw |
developer | e15e983 | 2023-06-01 17:34:07 +0800 | [diff] [blame] | 7 | git clone --branch master https://gerrit.mediatek.inc/gateway/rdk-b/meta-filogic-logan |
| 8 | git clone --branch master https://gerrit.mediatek.inc/gateway/rdk-b/meta-filogic |
developer | 839fc60 | 2023-01-11 19:16:07 +0800 | [diff] [blame] | 9 | |
developer | eab1cd7 | 2023-04-13 20:12:08 +0800 | [diff] [blame] | 10 | echo "sync hostapd patch from openWrt" |
developer | e15e983 | 2023-06-01 17:34:07 +0800 | [diff] [blame] | 11 | cp meta-cmf-filogic/mtk_scripts/rdkb_inc_helper autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd |
| 12 | cd autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd |
| 13 | ./rdkb_inc_helper patches |
| 14 | mv patches.inc patches |
developer | eab1cd7 | 2023-04-13 20:12:08 +0800 | [diff] [blame] | 15 | |
developer | e15e983 | 2023-06-01 17:34:07 +0800 | [diff] [blame] | 16 | cd - |
| 17 | rm -rf meta-filogic-logan/recipes-wifi/hostapd/files/patches |
| 18 | rm -rf meta-filogic-logan/recipes-wifi/wpa-supplicant/files/patches |
| 19 | cp -rf autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/patches meta-filogic-logan/recipes-wifi/hostapd/files/ |
| 20 | cp -rf autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/patches meta-filogic-logan/recipes-wifi/wpa-supplicant/files/ |
| 21 | rm -rf meta-filogic-logan/recipes-wifi/hostapd/files/src |
| 22 | rm -rf meta-filogic-logan/recipes-wifi/wpa-supplicant/files/src |
| 23 | cp -rf autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/src meta-filogic-logan/recipes-wifi/hostapd/files/ |
| 24 | cp -rf autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/src meta-filogic-logan/recipes-wifi/wpa-supplicant/files/ |
| 25 | echo "cp defconfig and remove ubus" |
| 26 | cp autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/files/hostapd-full.config meta-filogic-logan/recipes-wifi/hostapd/files/ |
| 27 | cp autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/files/wpa_supplicant-full.config meta-filogic-logan/recipes-wifi/wpa-supplicant/files/ |
developer | eab1cd7 | 2023-04-13 20:12:08 +0800 | [diff] [blame] | 28 | |
developer | e15e983 | 2023-06-01 17:34:07 +0800 | [diff] [blame] | 29 | echo "Update hostapd bb file version.........." |
| 30 | ver=`grep "PKG_SOURCE_VERSION" autobuild_v5/mt7988-mt7990-BE19000/package/network/services/hostapd/Makefile | cut -c 21-` |
| 31 | sed -i 's/SRCREV ?=.*/SRCREV ?= "'$ver'"/g' meta-filogic-logan/recipes-wifi/hostapd/hostapd_2.10.bb |
| 32 | sed -i 's/SRCREV ?=.*/SRCREV ?= "'$ver'"/g' meta-filogic-logan/recipes-wifi/wpa-supplicant/wpa-supplicant_2.10.bb |
developer | eab1cd7 | 2023-04-13 20:12:08 +0800 | [diff] [blame] | 33 | |
| 34 | echo "sync wifi profile from openWrt" |
| 35 | #remove old profile |
| 36 | rm -rf meta-filogic-logan/recipes-wifi/mt-wifi7/files/wireless/mediatek |
| 37 | |
| 38 | #copy new profile from openwrt |
| 39 | mkdir -p meta-filogic-logan/recipes-wifi/mt-wifi7/files/wireless/mediatek |
| 40 | cp -f big_sw/mtk/drivers/wifi-profile/files/mt7990/* meta-filogic-logan/recipes-wifi/mt-wifi7/files/wireless/mediatek |
| 41 | |
| 42 | |
developer | 825ab6a | 2023-01-18 13:58:01 +0800 | [diff] [blame] | 43 | echo "sync wifi config from openWrt" |
| 44 | #remove old config |
developer | 4914e57 | 2023-01-30 10:22:29 +0800 | [diff] [blame] | 45 | rm -rf meta-filogic-logan/recipes-wifi/mt-wifi7/files/config |
| 46 | |
developer | 825ab6a | 2023-01-18 13:58:01 +0800 | [diff] [blame] | 47 | #copy new config from openwrt |
developer | 4914e57 | 2023-01-30 10:22:29 +0800 | [diff] [blame] | 48 | mkdir -p meta-filogic-logan/recipes-wifi/mt-wifi7/files/config |
| 49 | #copy origin openwrt config |
| 50 | cp -f autobuild_v5/mt7988-mt7990-BE19000/.config meta-filogic-logan/recipes-wifi/mt-wifi7/files/config/openwrt_mt7990-be19000_config |
| 51 | cp -f autobuild_v5/mt7988-mt7992-BE7200/.config meta-filogic-logan/recipes-wifi/mt-wifi7/files/config/openwrt_mt7992-be7200_config |
| 52 | cp meta-cmf-filogic/mtk_scripts/rdkb_logan_config_helper meta-filogic-logan/recipes-wifi/mt-wifi7/files/config |
| 53 | cp meta-filogic-logan/recipes-wifi/mt-wifi7/files/make-l1profile.py meta-filogic-logan/recipes-wifi/mt-wifi7/files/config |
| 54 | #gen wifi config and l1 profile by different openwrt config |
| 55 | cd meta-filogic-logan/recipes-wifi/mt-wifi7/files/config |
| 56 | ./rdkb_logan_config_helper openwrt_mt7990-be19000_config mt7990-be19000 |
| 57 | ./rdkb_logan_config_helper openwrt_mt7992-be7200_config mt7992-be7200 |
| 58 | python make-l1profile.py openwrt_mt7990-be19000_config mt7990-be19000.dat |
| 59 | python make-l1profile.py openwrt_mt7992-be7200_config mt7992-be7200.dat |
| 60 | #remove script |
developer | 825ab6a | 2023-01-18 13:58:01 +0800 | [diff] [blame] | 61 | rm -f rdkb_logan_config_helper |
developer | 4914e57 | 2023-01-30 10:22:29 +0800 | [diff] [blame] | 62 | rm -f make-l1profile.py |
developer | 825ab6a | 2023-01-18 13:58:01 +0800 | [diff] [blame] | 63 | |
| 64 | cd - |
| 65 | |
developer | 839fc60 | 2023-01-11 19:16:07 +0800 | [diff] [blame] | 66 | echo "GEN iw patches.........." |
| 67 | cp meta-cmf-filogic/mtk_scripts/rdkb_inc_helper mac80211_package/package/network/utils/iw |
| 68 | cd mac80211_package/package/network/utils/iw |
| 69 | #remove patches not work for wifi hal |
| 70 | rm -rf patches/200-reduce_size.patch |
| 71 | |
| 72 | ./rdkb_inc_helper patches |
| 73 | mv patches.inc patches |
| 74 | |
| 75 | cd - |
| 76 | rm -rf meta-filogic-logan/recipes-wifi/iw/patches |
| 77 | cp -rf mac80211_package/package/network/utils/iw/patches meta-filogic-logan/recipes-wifi/iw |
| 78 | ver=`grep "PKG_VERSION:=" mac80211_package/package/network/utils/iw/Makefile | cut -c 14-` |
| 79 | newbb=iw_${ver}.bb |
| 80 | cd meta-filogic-logan/recipes-wifi/iw/ |
| 81 | oldbb=`ls *.bb` |
| 82 | echo "Update iw bb file name.........." |
| 83 | mv ${oldbb} ${newbb} |
| 84 | cd - |
| 85 | |
| 86 | echo "Update iw bb hash .........." |
| 87 | hash1=`grep "PKG_HASH" mac80211_package/package/network/utils/iw/Makefile | cut -c 11-` |
| 88 | sed -i 's/SRC_URI\[sha256sum\].*/SRC_URI[sha256sum] = "'${hash1}'"/g' meta-filogic-logan/recipes-wifi/iw/${newbb} |
| 89 | |
developer | 839fc60 | 2023-01-11 19:16:07 +0800 | [diff] [blame] | 90 | |
developer | 839fc60 | 2023-01-11 19:16:07 +0800 | [diff] [blame] | 91 | |
| 92 | echo "Update libubox version.........." |
| 93 | ver=`grep "PKG_SOURCE_VERSION" mac80211_package/package/libs/libubox/Makefile | cut -c 21-` |
| 94 | sed -i 's/SRCREV =.*/SRCREV = "'$ver'"/g' meta-filogic-logan/recipes-wifi/libubox/libubox_git.bbappend |
| 95 | |
| 96 | echo "Update ubus version.........." |
| 97 | ver=`grep "PKG_SOURCE_VERSION" mac80211_package/package/system/ubus/Makefile | cut -c 21-` |
| 98 | sed -i 's/SRCREV =.*/SRCREV = "'$ver'"/g' meta-filogic-logan/recipes-wifi/ubus/ubus_git.bb |
| 99 | |
| 100 | echo "Update libnl-tiny version.........." |
| 101 | ver=`grep "PKG_SOURCE_VERSION" mac80211_package/package/libs/libnl-tiny/Makefile | cut -c 21-` |
| 102 | sed -i 's/SRCREV =.*/SRCREV = "'$ver'"/g' meta-filogic-logan/recipes-wifi/libnl-tiny/libnl-tiny_git.bb |
| 103 | |
| 104 | echo "Update iwinfo version.........." |
| 105 | ver=`grep "PKG_SOURCE_VERSION" mac80211_package/package/network/utils/iwinfo/Makefile | cut -c 21-` |
| 106 | sed -i 's/SRCREV =.*/SRCREV = "'$ver'"/g' meta-filogic-logan/recipes-wifi/iwinfo/iwinfo_git.bb |
| 107 | |
developer | 66a4fa9 | 2023-01-17 12:42:26 +0800 | [diff] [blame] | 108 | echo "sync ccsp hal wifi-test-tool from meta-filogic" |
| 109 | rm -rf meta-filogic-logan/recipes-wifi/ccsp |
| 110 | cp -rf meta-filogic/recipes-wifi/ccsp meta-filogic-logan/recipes-wifi/ccsp |
| 111 | rm -rf meta-filogic-logan/recipes-wifi/hal/files meta-filogic-logan/recipes-wifi/hal/halinterface.bbappend |
| 112 | cp -rf meta-filogic/recipes-wifi/hal/files meta-filogic-logan/recipes-wifi/hal/files |
| 113 | cp -f meta-filogic/recipes-wifi/hal/halinterface.bbappend meta-filogic-logan/recipes-wifi/hal/halinterface.bbappend |
| 114 | rm -rf meta-filogic-logan/recipes-wifi/wifi-test-tool |
| 115 | cp -rf meta-filogic/recipes-wifi/wifi-test-tool meta-filogic-logan/recipes-wifi/wifi-test-tool |
developer | 839fc60 | 2023-01-11 19:16:07 +0800 | [diff] [blame] | 116 | echo "Sync from OpenWRT done , ready to commit meta-filogic-logan!!!" |