README.txt 4.1 KB

  1. ===============================================================================
  2. LIBERTYBSD-SCRIPTS For deblobbing OpenBSD
  3. ===============================================================================
  4. Scripts used to deblob and rebrand OpenBSD source-code, made for the
  5. LibertyBSD project. You can get OBSD sources from your local mirror
  6. at, as the 'src', 'xenocara', or 'sys'
  7. tarballs. CVS can be used, as well.
  8. ----------------------------------------
  10. ----------------------------------------
  11. There're five scripts here, so here's what they do:
  12. Deblobs main OBSD source of NF FW, references, etc
  13. Gets rid of pages with non-free (NF) references
  14. Deletes NF firmware and references thereof from kernel
  15. Basic system rebranding, etc
  16. System/boot rebranding
  17. Rebrand man-pages, and add some of our new ones
  19. Rebrands X sources-- not much to this one
  21. Deblob ports tree of all NF listings
  23. Rebrand ports in ports-tree, etc
  24. ----------------------------------------
  25. USAGE
  26. ----------------------------------------
  27. Usage of these scripts is pretty simple-- to make freshly deblobbed OBSD
  28. sources, just run them each with the argument being the directory of the
  29. corresponding source-code, like so:
  30. sh /usr/src
  31. sh /usr/src
  32. sh /usr/src/sys
  33. sh /usr/xenocara
  34. sh /usr/ports
  35. If you want liberated OpenBSD sources, but without the LibertyBSD rebranding,
  36. just skip the * scripts and everything should go fine.
  37. ----------------------------------------
  38. NOTES
  39. ----------------------------------------
  40. All of the scripts make use of "./", and all file-editing/etc
  41. operations are abstracted to its functions.
  42. This is because instead of actually applying changes directly to OBSD
  43. sources, the deblob scripts create a set of patches for them, and *then*
  44. apply them.
  45. You might want to perform multiple operations on a given file, (I.E.,
  46. substitute text, then remove a line, etc.). After every operation, a new
  47. (modified) version of the file is created in the /tmp/ directory, along with
  48. a patch. So if you want to do multiple operations, you'll need to decide
  49. whether or not to use the original source-code, or a modified version from
  50. /tmp/...
  51. This has been abstracted away with the "ifile" and "ofile" functions.
  52. "ifile" outputs to stdout the contents of the file-- be it the patch-file, the
  53. original, whatever is appropriate. "ofile" writes to the patch-file what is
  54. piped to it, and handles the bullocks.
  55. Hence why "ifile | operation | ofile" is so common in
  56. Each script uses a very clearly-named /tmp/ directory...
  57. /tmp/script-name/
  58. While it is a *tad* bit weird do all of this indirect work on the sources, it
  59. has a few advantages I'd like to stick with:
  60. * Abstraction.
  61. Operations are all very general and unspecific; you don't need
  62. to manually muck with `sed` for every individual patch.
  63. * Easy debugging.
  64. If there's a problem, you can stop the script before it patches
  65. original sources, and look at the /tmp/ data. Compare the
  66. .orig with the .patch with the modified, etc. Very useful.
  67. * Patch generation.
  68. With patches being integral to the entire process, it makes all
  69. changes made to OBSD source code very transparent. Anyone could
  70. take a look at a tarball of the patches and understand *exactly*
  71. what changed.
  72. There're probably some other obscure use-cases for these
  73. patches, anyway. And if it's easy to support a weird
  74. hypothetical use-case, why not?
  75. ... in order of importance.
  76. ----------------------------------------
  78. ----------------------------------------
  79. Send patches/issues to:
  80. </f/libertybsd> (
  81. <#libertybsd> (Freenode)
  82. <>
  83. <LibertyBSD/libertybsd-scripts> (NotABug)
  84. License is ISC (COPYING.txt)
  85. Author is Jaidyn Ann <>
  86. Some ports contributions by jmfgdef (Jimmybot),
  87. Some improvements by Einhard Leichtfuß.
  88. Source is at