src_deblob.sh 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. #!/bin/ksh
  2. #########################
  3. # Name: src_deblob.sh
  4. # Main: jadedctrl
  5. # Lisc: ISC
  6. # Desc: Delobbing OBSD base
  7. # sources for use in
  8. # LBSD.
  9. #########################
  10. # Usage: src_deblob.sh
  11. . ./libdeblob.sh
  12. PATCH_DIR=/tmp/src_deblob/
  13. if [ -e $PATCH_DIR ]
  14. then
  15. self_destruct_sequence $PATCH_DIR
  16. else
  17. mkdir $PATCH_DIR
  18. fi
  19. if test -z $1
  20. then
  21. SRC_DIR=/usr/src/
  22. mkdir $SRC_DIR
  23. else
  24. SRC_DIR=$1
  25. fi
  26. echo $SRC_DIR
  27. arch_list="amd64 i386"
  28. for arch in $arch_list # not all archs have ramdisk_cd... fix!
  29. do
  30. linedel "\${DESTDIR}/etc/firmware/kue.*" distrib/${arch}/ramdisk_cd/list.local
  31. linedel "\${DESTDIR}/etc/firmware/bnx-b06" distrib/${arch}/ramdisk_cd/list.local
  32. linedel "\${DESTDIR}/etc/firmware/bnx-b09" distrib/${arch}/ramdisk_cd/list.local
  33. linedel "\${DESTDIR}/etc/firmware/bnx-rv2p" distrib/${arch}/ramdisk_cd/list.local
  34. linedel "\${DESTDIR}/etc/firmware/bnx-xi-rv2p" distrib/${arch}/ramdisk_cd/list.local
  35. linedel "\${DESTDIR}/etc/firmware/bnx-xi90-rv2p" distrib/${arch}/ramdisk_cd/list.local
  36. linedel "\${DESTDIR}/etc/firmware/ral-rt2561" distrib/${arch}/ramdisk_cd/list.local
  37. linedel "\${DESTDIR}/etc/firmware/ral-rt2561s" distrib/${arch}/ramdisk_cd/list.local
  38. linedel "\${DESTDIR}/etc/firmware/ral-rt2661" distrib/${arch}/ramdisk_cd/list.local
  39. linedel "\${DESTDIR}/etc/firmware/ral-rt2860" distrib/${arch}/ramdisk_cd/list.local
  40. linedel "\${DESTDIR}/etc/firmware/ral-rt2573" distrib/${arch}/ramdisk_cd/list.local
  41. linedel "\${DESTDIR}/etc/firmware/ral-rt2870" distrib/${arch}/ramdisk_cd/list.local
  42. linedel "\${DESTDIR}/etc/firmware/ral-rt3071" distrib/${arch}/ramdisk_cd/list.local
  43. linedel "\${DESTDIR}/etc/firmware/rum-rt2573" distrib/${arch}/ramdisk_cd/list.local
  44. linedel "\${DESTDIR}/etc/firmware/run-rt2870" distrib/${arch}/ramdisk_cd/list.local
  45. linedel "\${DESTDIR}/etc/firmware/run-rt3071" distrib/${arch}/ramdisk_cd/list.local
  46. linedel "\${DESTDIR}/etc/firmware/tigon1" distrib/${arch}/ramdisk_cd/list.local
  47. linedel "\${DESTDIR}/etc/firmware/tigon2" distrib/${arch}/ramdisk_cd/list.local
  48. linedel "\${DESTDIR}/etc/firmware/zd1211" distrib/${arch}/ramdisk_cd/list.local
  49. linedel "\${DESTDIR}/etc/firmware/zd1211b" distrib/${arch}/ramdisk_cd/list.local
  50. done
  51. linedel "pkg_add pkg_sign" usr.sbin/pkg_add/Makefile
  52. rep "pkg_add fw_update" "pkg_add pkg_sign" usr.sbin/pkg_add/Makefile
  53. strdel "fw_update.1" usr.sbin/pkg_add/Makefile
  54. strdel "fw_update" usr.sbin/pkg_add/Makefile
  55. linedel "FwUpdate.pm" usr.sbin/pkg_add/Makefile
  56. for arch in $arch_list
  57. do
  58. linedel "./usr/libdata/perl5/OpenBSD/FwUpdate.pm" "distrib/sets/lists/base/md.${arch}"
  59. linedel "./usr/sbin/fw_update" "distrib/sets/lists/base/md.${arch}"
  60. linedel "./etc/firmware/4c9904" "distrib/sets/lists/base/md.${arch}"
  61. linedel "./etc/firmware/3c990-license" "distrib/sets/lists/base/md.${arch}"
  62. linedel "./etc/firmware/atu-at76c503-i3863-ext" "distrib/sets/lists/base/md.${arch}"
  63. linedel "./etc/firmware/atu-at77c503-i3863-int" "distrib/sets/lists/base/md.${arch}"
  64. linedel "./etc/firmware/atu-at76c503-rfmd-acc-ext" "distrib/sets/lists/base/md.${arch}"
  65. linedel "./etc/firmware/atu-at76c503-rfmd-acc-int" "distrib/sets/lists/base/md.${arch}"
  66. linedel "./etc/firmware/atu-at76c505-rfmd-ext" "distrib/sets/lists/base/md.${arch}"
  67. linedel "./etc/firmware/atu-at76c505-rfmd-int" "distrib/sets/lists/base/md.${arch}"
  68. linedel "./etc/firmware/atu-intersil-ext" "distrib/sets/lists/base/md.${arch}"
  69. linedel "./etc/firmware/atu-intersil-int" "distrib/sets/lists/base/md.${arch}"
  70. linedel "./etc/firmware/atu-license" "distrib/sets/lists/base/md.${arch}"
  71. linedel "./etc/firmware/atu-rfmd-ext" "distrib/sets/lists/base/md.${arch}"
  72. linedel "./etc/firmware/atu-rfmd-int" "distrib/sets/lists/base/md.${arch}"
  73. linedel "./etc/firmware/atu-rfmd2958-ext" "distrib/sets/lists/base/md.${arch}"
  74. linedel "./etc/firmware/atu-rfmd2958-int" "distrib/sets/lists/base/md.${arch}"
  75. linedel "./etc/firmware/atu-rfmd2958smc-ext" "distrib/sets/lists/base/md.${arch}"
  76. linedel "./etc/firmware/atu-rfmd2958smc-int" "distrib/sets/lists/base/md.${arch}"
  77. linedel "./etc/firmware/bnx-b06" "distrib/sets/lists/base/md.${arch}"
  78. linedel "./etc/firmware/bnx-b09" "distrib/sets/lists/base/md.${arch}"
  79. linedel "./etc/firmware/bnx-license" "distrib/sets/lists/base/md.${arch}"
  80. linedel "./etc/firmware/bnx-rv2p" "distrib/sets/lists/base/md.${arch}"
  81. linedel "./etc/firmware/bnx-xi-rv2p" "distrib/sets/lists/base/md.${arch}"
  82. linedel "./etc/firmware/bnx-xi90-rv2p" "distrib/sets/lists/base/md.${arch}"
  83. linedel "./etc/firmware/cs4280" "distrib/sets/lists/base/md.${arch}"
  84. linedel "./etc/firmware/cs4280-license" "distrib/sets/lists/base/md.${arch}"
  85. linedel "./etc/firmware/fxp-d101a" "distrib/sets/lists/base/md.${arch}"
  86. linedel "./etc/firmware/fxp-d101b0" "distrib/sets/lists/base/md.${arch}"
  87. linedel "./etc/firmware/fxp-d101ma" "distrib/sets/lists/base/md.${arch}"
  88. linedel "./etc/firmware/fxp-d101s" "distrib/sets/lists/base/md.${arch}"
  89. linedel "./etc/firmware/fxp-d102" "distrib/sets/lists/base/md.${arch}"
  90. linedel "./etc/firmware/fxp-d102c" "distrib/sets/lists/base/md.${arch}"
  91. linedel "./etc/firmware/fxp-d102e" "distrib/sets/lists/base/md.${arch}"
  92. linedel "./etc/firmware/fxp-license" "distrib/sets/lists/base/md.${arch}"
  93. linedel "./etc/firmware/kue" "distrib/sets/lists/base/md.${arch}"
  94. linedel "./etc/firmware/kue-license" "distrib/sets/lists/base/md.${arch}"
  95. linedel "./etc/firmware/myx-eth_z8e" "distrib/sets/lists/base/md.${arch}"
  96. linedel "./etc/firmware/myx-ethp_z8e" "distrib/sets/lists/base/md.${arch}"
  97. linedel "./etc/firmware/myx-license" "distrib/sets/lists/base/md.${arch}"
  98. linedel "./etc/firmware/ral-license" "distrib/sets/lists/base/md.${arch}"
  99. linedel "./etc/firmware/ral-rt2561" "distrib/sets/lists/base/md.${arch}"
  100. linedel "./etc/firmware/ral-rt2561s" "distrib/sets/lists/base/md.${arch}"
  101. linedel "./etc/firmware/ral-rt2661" "distrib/sets/lists/base/md.${arch}"
  102. linedel "./etc/firmware/ral-rt2860" "distrib/sets/lists/base/md.${arch}"
  103. linedel "./etc/firmware/rum-license" "distrib/sets/lists/base/md.${arch}"
  104. linedel "./etc/firmware/rum-rt2573" "distrib/sets/lists/base/md.${arch}"
  105. linedel "./etc/firmware/run-license" "distrib/sets/lists/base/md.${arch}"
  106. linedel "./etc/firmware/run-rt2870" "distrib/sets/lists/base/md.${arch}"
  107. linedel "./etc/firmware/run-rt3071" "distrib/sets/lists/base/md.${arch}"
  108. linedel "./etc/firmware/symbol-eprim" "distrib/sets/lists/base/md.${arch}"
  109. linedel "./etc/firmware/symbol-esec" "distrib/sets/lists/base/md.${arch}"
  110. linedel "./etc/firmware/symbol-license" "distrib/sets/lists/base/md.${arch}"
  111. linedel "./etc/firmware/tht" "distrib/sets/lists/base/md.${arch}"
  112. linedel "./etc/firmware/tht-license" "distrib/sets/lists/base/md.${arch}"
  113. linedel "./etc/firmware/tigon-license" "distrib/sets/lists/base/md.${arch}"
  114. linedel "./etc/firmware/tigon1" "distrib/sets/lists/base/md.${arch}"
  115. linedel "./etc/firmware/tigon2" "distrib/sets/lists/base/md.${arch}"
  116. linedel "./etc/firmware/tusb3410" "distrib/sets/lists/base/md.${arch}"
  117. linedel "./etc/firmware/tusb3410-license" "distrib/sets/lists/base/md.${arch}"
  118. linedel "./etc/firmware/udl_huffman" "distrib/sets/lists/base/md.${arch}"
  119. linedel "./etc/firmware/yds" "distrib/sets/lists/base/md.${arch}"
  120. linedel "./etc/firmware/yds-license" "distrib/sets/lists/base/md.${arch}"
  121. linedel "./etc/firmware/zd1211" "distrib/sets/lists/base/md.${arch}"
  122. linedel "./etc/firmware/zd1211-license" "distrib/sets/lists/base/md.${arch}"
  123. linedel "./etc/firmware/zd1211b" "distrib/sets/lists/base/md.${arch}"
  124. done
  125. linedel "./usr/libdata/perl5/OpenBSD/FwUpdate.pm" distrib/sets/lists/base/mi
  126. linedel "./usr/sbin/fw_update" distrib/sets/lists/base/mi
  127. apply