autodeploy.sh 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. PRO_DIR=`pwd`
  2. CONFIG_IVSysMan="IVSysMan_vv7-6511.xml"
  3. check_result=`whereis patchelf | awk '{print $2}'`
  4. if [ ! $check_result ];then
  5. echo -e "\e[31m no found patchelf, Plz install patchelf first\e[0m"
  6. exit 1
  7. fi
  8. app_name=(
  9. driver_lidar_rs16
  10. #driver_lidar_vlp16
  11. driver_gps_hcp2
  12. driver_radio_p900
  13. #driver_can_nvidia_agx
  14. #driver_can_kvaser
  15. driver_can_vci
  16. driver_map_trace
  17. detection_radar_delphi_esr
  18. detection_lidar_grid
  19. #view_pointcloud
  20. view_gps
  21. view_rawcan
  22. view_radar
  23. IVSysMan
  24. ivmapmake
  25. view_ivlog
  26. tool_querymsg
  27. detection_chassis
  28. ui_ads_hmi
  29. decition_brain
  30. #decition_brain_ge3
  31. controller_ge3
  32. controller_vv7
  33. driver_map_xodrload
  34. tool_xodrobj
  35. ivlog_record
  36. adciv_record
  37. )
  38. for x in ${app_name[@]}
  39. do
  40. echo "deploy $x"
  41. cp ./bin/${x} ./
  42. ./deploy.sh $x
  43. if [ "$?" == 1 ];then
  44. exit 1
  45. fi
  46. rm ${x}
  47. done
  48. lib_name=(
  49. libmodulecomm.so
  50. libndt_cpu.so
  51. libxmlparam.so
  52. libivfault.so
  53. libivlog.so
  54. libivexit.so
  55. libplatformif.so
  56. )
  57. for x in ${lib_name[@]}
  58. do
  59. echo "link lib $x"
  60. patchelf --set-rpath '$ORIGIN' ./bin/$x
  61. if [ "$?" != 0 ];then
  62. echo -e "\e[31m autodeploy.sh: patchelf $EXE faile, Ensure patchelf tool installed\e[0m"
  63. exit 1
  64. fi
  65. done
  66. echo "creat IVSysMan.xml"
  67. cp ./other/$CONFIG_IVSysMan ./deploy/app/IVSysMan.xml
  68. cp ./other/ADS_decision.xml ./deploy/app/ADS_decision.xml
  69. sed -i "s|xxxxxx|$PRO_DIR/deploy/app|g" ./deploy/app/IVSysMan.xml
  70. cp ./bin/*.so ./deploy/app/lib/
  71. echo ""
  72. echo "***************"
  73. echo "*** done! ***"
  74. echo "***************"