Shad Ansari | 6cd46a6 | 2018-05-13 23:20:51 +0000 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
Zack Williams | 477ba09 | 2018-10-17 10:50:06 -0700 | [diff] [blame] | 3 | # Copyright 2018-present Open Networking Foundation |
| 4 | # |
| 5 | # This program is free software: you can redistribute it and/or modify |
| 6 | # it under the terms of the GNU General Public License as published by |
| 7 | # the Free Software Foundation, either version 3 of the License, or |
| 8 | # (at your option) any later version. |
| 9 | # |
| 10 | # This program is distributed in the hope that it will be useful, |
| 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | # GNU General Public License for more details. |
| 14 | # |
| 15 | # You should have received a copy of the GNU General Public License |
| 16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 17 | |
Shad Ansari | cb004c5 | 2018-05-30 18:07:23 +0000 | [diff] [blame] | 18 | rm -rf /opt/bcm68620 |
| 19 | rm -rf /broadcom |
Thiyagarajan Subramani | 1f1280b | 2019-08-13 18:41:19 +0800 | [diff] [blame] | 20 | tar zxf /tmp/release_asgvolt64_V3.1.1.201908010203.tar.gz -C / 2>&1 > /dev/null |
Shad Ansari | cb004c5 | 2018-05-30 18:07:23 +0000 | [diff] [blame] | 21 | grep -q '\/opt\/bcm68620\/svk_init.sh' /etc/rc.local || sed -i -e '$i \/opt\/bcm68620\/svk_init.sh' /etc/rc.local |
| 22 | rm -f /run/bcm68620 |
Jason Huang | fd78f66 | 2019-06-05 20:25:01 +0800 | [diff] [blame] | 23 | cp /tmp/init.d/dev_mgmt_daemon /etc/init.d |
Shad Ansari | d0eaf75 | 2018-08-16 00:26:12 +0000 | [diff] [blame] | 24 | cp /tmp/init.d/openolt /etc/init.d |
Nicolas Palpacuer | 967438f | 2018-09-07 14:41:54 -0400 | [diff] [blame] | 25 | cp /tmp/logrotate.d/openolt /etc/logrotate.d |
Jason Huang | fd78f66 | 2019-06-05 20:25:01 +0800 | [diff] [blame] | 26 | chmod +x /etc/init.d/dev_mgmt_daemon |
Shad Ansari | d0eaf75 | 2018-08-16 00:26:12 +0000 | [diff] [blame] | 27 | chmod +x /etc/init.d/openolt |
Jason Huang | fd78f66 | 2019-06-05 20:25:01 +0800 | [diff] [blame] | 28 | update-rc.d dev_mgmt_daemon defaults |
Shad Ansari | d0eaf75 | 2018-08-16 00:26:12 +0000 | [diff] [blame] | 29 | update-rc.d openolt defaults |
Shad Ansari | 9fb007d | 2018-05-14 18:31:38 +0000 | [diff] [blame] | 30 | mv /tmp/openolt /broadcom |
Shad Ansari | 9fb007d | 2018-05-14 18:31:38 +0000 | [diff] [blame] | 31 | mv /tmp/libgrpc++.so.1 /usr/local/lib |
| 32 | mv /tmp/libgrpc.so.6 /usr/local/lib |
Jason Huang | fd78f66 | 2019-06-05 20:25:01 +0800 | [diff] [blame] | 33 | mv /tmp/libstdc++.so.6 /usr/local/lib |
| 34 | mv /tmp/libbal_host_api.so /usr/local/lib |
Shad Ansari | cb004c5 | 2018-05-30 18:07:23 +0000 | [diff] [blame] | 35 | /opt/bcm68620/svk_init.sh |
Thiyagarajan Subramani | 1f1280b | 2019-08-13 18:41:19 +0800 | [diff] [blame] | 36 | [ "A`cat ~/.bashrc| grep LD_LIBRARY_PATH`" = "A" ] && echo "export LD_LIBRARY_PATH=/broadcom:\$LD_LIBRARY_PATH" >> ~/.bashrc; . ~/.bashrc |
| 37 | ldconfig /broadcom |