diff --git a/.claude/memory/MEMORY.md b/.claude/memory/MEMORY.md index c6d1bd2..5a4187b 100644 --- a/.claude/memory/MEMORY.md +++ b/.claude/memory/MEMORY.md @@ -44,7 +44,7 @@ - [Device model](schunix-device-model.md) — one bus-agnostic list at /proc/devices; bus is provenance, class is capability, and the settled Linux-driver decision. - [usb.ids](schunix-usb-ids.md) — shipped as /usr/share/usb.ids, BSD option of a dual licence; cached, not fetched per build. - [USB and xHCI](schunix-usb-xhci.md) — enumeration and control transfers work; written from the spec, because porting BSD's stack means porting newbus first. -- [Licensing](schunix-licensing.md) — Apache-2.0, copyright Nexoniarz; BSD drivers are usable and Linux ones are not. +- [Licensing](schunix-licensing.md) — GPL-2.0-or-later since 2026-10-22 (was Apache); Linux code OK, no Apache/GPLv3 in the kernel. - [Layout migration](schunix-layout-migration.md) — the bt/ → ports/ + lib/ + cmd/ restructure and the two Makefile traps it exposed. - [Verify by driving the shell](schunix-verify-by-driving-shell.md) — booting to a prompt proves nothing; run real commands over serial with paced input. - [/dev and /proc](schunix-devfs-procfs.md) — how both are built; ps and top work now, one cosmetic gap left. diff --git a/.claude/memory/schunix-licensing.md b/.claude/memory/schunix-licensing.md index 65579d0..d44011d 100644 --- a/.claude/memory/schunix-licensing.md +++ b/.claude/memory/schunix-licensing.md @@ -1,6 +1,6 @@ --- name: schunix-licensing -description: "Schunix is Apache-2.0, copyright Nexoniarz; BSD drivers yes, Linux no, and ports/ licences bind regardless" +description: "SchOS is GPL-2.0-or-later since 2026-10-22 (was Apache-2.0); Linux code now allowed, but no Apache/GPLv3 code in the kernel" metadata: node_type: memory type: project @@ -8,43 +8,34 @@ metadata: modified: 2026-08-08T16:18:39.569Z --- -**`LICENSE` is Apache-2.0**, copyright *Nexoniarz* (not "Schunix Contributors" — -one author, and a fictional collective makes future re-licensing harder). -Chosen over MIT/BSD for the express patent grant. +**`LICENSE` is GPL-2.0-or-later** since 2026-10-22, copyright *Nexoniarz*, sole +author. It was Apache-2.0 before and was never published under it. Nexoniarz +chose GPL for copyleft ("I can't be also too liberal because people just mostly +steal that work") and so Linux code can be used. They picked "or-later" over +"only" on my recommendation. -**Settled, do not reopen:** the "Apache-2.0 but shared-source" question was -discussed at length in 2026-08 and **on 2026-08-08 Nexoniarz asked for it to be -dropped from the docs entirely** — `docs/licensing.md` is about licensing, not -about that debate. All references are gone from `docs/`, `LICENSE` and `NOTICE`; -don't reintroduce them. The substance that survives, in one line inside §1: -Apache-2.0 §2 is an irrevocable grant, so a restriction stated anywhere else -does not narrow it, and restricting distribution would be a licence change -(bespoke proprietary, or BUSL-1.1) rather than a wording change. +**The rule that replaced "Linux no":** a single linked binary has to pick one +GPL version. Linux code (GPL-2.0-only) makes it GPLv2; Apache-2.0 or GPLv3 code +makes it GPLv3. They can't share a binary, so **the kernel takes no Apache-2.0 +or GPLv3 code**. Separate userland programs may be GPLv3 or Apache. Data files +such as Roboto (Apache-2.0) are aggregation, and that holds inside the ramdisk +too. BSD 4-clause code is now a hard **no** (GPL-incompatible). -The decision that actually mattered to them is **when to publish**, not the -licence; the standing rule is still never ([[nexoniarz-sharing-preference]]). +**LDLS still ships no `.ko`.** That is policy now, not a legal requirement. The +`.gitignore` `*.ko` rule and `RAMDISK_EXCLUDE` stay. -**Binding regardless of what they pick:** -- The kernel derives from xv6 (MIT). `LICENSE.MIT` was *missing* — it was - referenced as `bk/LICENSE.MIT` and lost in the `bk/` → `kernel/` migration. - Recreated; must not be deleted. -- `ports/` is other people's code, redistributed in every image: musl (MIT), - toybox (0BSD), mksh (MirOS). `NOTICE` carries the attribution musl and mksh - require. Patches under `ports/*/patches/` inherit *their* licences. +**Settled, do not reopen:** the old "Apache-2.0 but shared-source" debate was +dropped from the docs on 2026-08-08. The question that matters to them is when +to publish, and the standing answer is still never +([[nexoniarz-sharing-preference]]). -New first-party files carry `// SPDX-License-Identifier: Apache-2.0`. +**Binding regardless:** +- The kernel derives from xv6 (MIT). `LICENSE.MIT` must not be deleted. +- `ports/` is other people's code: musl, toybox, mksh, zsh, ncurses, lwIP, + kilo and fastfetch are all permissive. `NOTICE` carries the attributions. -**Drivers: BSD yes, Linux no** (asked 2026-08-04, "for drivers we can try get -it from like Linux?"). Linux is GPL-2.0-**only**, and Apache-2.0's patent and -indemnity clauses are "further restrictions" under GPLv2 §6 — the two cannot -be combined and redistributed. Using a Linux driver means relicensing all of -Schunix to GPLv2 and dropping Apache-2.0; you cannot keep both. FreeBSD / -NetBSD / OpenBSD are BSD-2/3-clause and **are** compatible: keep the notice, -add to `NOTICE`, done. Reading Linux to understand hardware is fine; -translating a driver function-by-function produces a derivative work whatever -the identifiers say. Best source of all is the public specification — xHCI, -virtio, AHCI, NVMe, e1000 — which carries no licence on what you write from -it. Recorded in `docs/plan/roadmap.md` §1. See [[schunix-roadmap-and-projects]]. +New first-party files carry `// SPDX-License-Identifier: GPL-2.0-or-later`. +The policy is in `docs/licensing.md`. See [[schunix-roadmap-and-projects]]. ## fs.c is third-party, and was unattributed until 2026-08-09 diff --git a/.gitignore b/.gitignore index ca58d66..fc509a3 100644 --- a/.gitignore +++ b/.gitignore @@ -45,7 +45,8 @@ docs/Website/releases/ # Kernel modules, ever. docs/plan/ldls.md rule 1: LDLS ships the layer and # never the thing it loads, and that applies to this tree as well as to an # image. The loader's test input is built from ldls/test/refmod.c, which is -# ours; a .ko here would be someone else's GPL code in an Apache-2.0 repo. +# ours; a .ko here would be someone else's code, with its own provenance, in +# a tree that is otherwise all first-party or attributed in NOTICE. *.ko *.ko.xz @@ -59,7 +60,7 @@ core.* # # help/ is where a third-party kernel gets cloned when it is worth reading -- # Zircon, at the time of writing. It is BSD-licensed and this project is -# Apache-2.0, so the licences are compatible and that is *not* the reason it is +# GPL-2.0-or-later, so the licences are compatible and that is *not* the reason it is # ignored: it is ignored because a copy of another project's source inside this # one is a copy that will rot, that nobody will update, and that makes the # provenance of every file around it a question. Clone it, read it, learn the diff --git a/LICENSE b/LICENSE index 0877d39..d159169 100644 --- a/LICENSE +++ b/LICENSE @@ -1,187 +1,339 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. - 1. Definitions. + Preamble - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. - "Work" shall mean the work of authorship made available under - the License, as indicated by a copyright notice that is included in - or attached to the work (an example is provided in the Appendix below). + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. + The precise terms and conditions for copying, distribution and +modification follow. - "Contribution" shall mean, as submitted to the Licensor for inclusion - in the Work by the copyright owner or by an individual or Legal Entity - authorized to submit on behalf of the copyright owner. For the purposes - of this definition, "contribution" means any work of authorship, - including the original version of the Work and any modifications or - additions to that Work or Derivative Works of the Work. + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - "Contributor" shall mean Licensor and any Legal Entity on behalf of - whom a Contribution has been received by the Licensor and included - within the Work. + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by the combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a cross-claim - or counterclaim in a lawsuit) alleging that the Work or any - Contribution embodied within the Work constitutes patent or - contributory patent infringement, then any patent licenses granted to - You under this License for that Work shall terminate as of the date - such litigation is filed. + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. - (d) If the Work includes a "NOTICE" text file as part of its - distribution, You must include a readable copy of the - attribution notices contained within such NOTICE file, in - at least one of the following places: within a NOTICE text - file distributed as part of the Derivative Works; within - the Source form or documentation, if provided along with the - Derivative Works; or, within a display generated by the - Derivative Works, if and wherever such third-party notices - normally appear. The contents of the NOTICE file are for - informational purposes only and do not modify the License. - You may add Your own attribution notices within Derivative - Works that You distribute, alongside or in addition to the - NOTICE text from the Work, provided that such additional - attribution notices cannot be construed as modifying the License. + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) - You may add Your own license statement for Your modifications and - may provide additional grant of rights to use, copy, modify, and - distribute those modifications as a separate work, subject to the - terms and conditions of this License. +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any conditions of TITLE, - NONINFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. - You are solely responsible for determining the appropriateness of - using or reproducing the Work and assume any risks associated with - Your exercise of permissions under this License. + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or exemplary damages of any character arising as a - result of this License or out of the use or inability to use the - Work (even if such Contributor has been advised of the possibility - of such damages). + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may offer such - obligations only on Your behalf and on Your sole responsibility, - not on behalf of any other Contributor, and only if You agree to - indemnify, defend, and hold each Contributor harmless for any - liability incurred by, or claims asserted against, such Contributor - by reason of your accepting any warranty or additional liability. + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, - END OF TERMS AND CONDITIONS + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) - Copyright 2026 Nexoniarz +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. - http://www.apache.org/licenses/LICENSE-2.0 + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. - NOTE: The kernel (kernel/) is derived from xv6 (MIT License, Copyright - 2006-2019 Frans Kaashoek, Robert Morris, Russ Cox, M.I.T. CSAIL). - The MIT license notice is preserved in LICENSE.MIT and must not be - removed. Third-party software redistributed in a built image -- musl, - toybox and mksh, all under ports/ -- keeps its own license; see NOTICE. + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. - Which outside code may be copied into SchOS and which may not -- the - BSD/GPL rules, the NetBSD advertising clause, and what is deliberately - never shipped -- is written up in docs/licensing.md. Read it before - copying anyone else's code in. + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. diff --git a/Makefile b/Makefile index e2e0654..930e947 100644 --- a/Makefile +++ b/Makefile @@ -455,8 +455,8 @@ RAMDISK_BLOCKS ?= 8000 # rule before it is a size one: the ramdisk image is linked *into the kernel # binary*, so anything staged in sysroot/ when it is built becomes part of a # distributable artifact. Anything that arrives in sysroot/ under a licence that -# cannot be combined with Apache-2.0, or that simply is not ours to redistribute, -# belongs on this list rather than in someone's memory. +# cannot be combined with GPL-2.0-or-later, or that simply is not ours to +# redistribute, belongs on this list rather than in someone's memory. # # This is not hypothetical: a 33 MB test payload once landed here and overflowed # the 6 MB image, and mkfs's "increase FSSIZE" message then pointed at a constant diff --git a/NOTICE b/NOTICE index 0192f92..2fed81a 100644 --- a/NOTICE +++ b/NOTICE @@ -2,7 +2,8 @@ SchOS Copyright 2026 Nexoniarz This product includes software developed as part of the SchOS project, -licensed under the Apache License, Version 2.0. See LICENSE. +licensed under the GNU General Public License, version 2 or (at your option) +any later version. See LICENSE. ================================================================================ Third-party software @@ -118,9 +119,9 @@ ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Fetched by ports/lwip and compiled into the kernel -- it is the TCP/IP stack, not a userland library, so it is present in every built kernel image rather than in a binary under /bin. The port layer written for SchOS -(kernel/net/lwip/) is Apache-2.0 and is not part of lwIP; lwIP's own sources -are unmodified. Clause 3 is a no-endorsement term, not the four-clause -advertising requirement, so it combines with Apache-2.0 without difficulty. +(kernel/net/lwip/) is GPL-2.0-or-later and is not part of lwIP; lwIP's own +sources are unmodified. Clause 3 is a no-endorsement term, not the four-clause +advertising requirement, so it combines with the GPL without difficulty. -------------------------------------------------------------------------------- Intel 8254x device identifiers BSD 3-Clause @@ -149,9 +150,8 @@ http://www.linux-usb.org/usb.ids Distributed by its maintainer under the terms of *either* the GNU General Public License version 2 or later, *or* the 3-clause BSD Licence. SchOS takes -the BSD option; the GPL option is not exercised and could not be, since -Apache-2.0 and GPL-2.0-only cannot be combined (see docs/licensing.md section -2). +the BSD option, which was chosen while SchOS was Apache-2.0; either option is +compatible now, and the BSD one is kept because it asks less of anyone. Shipped verbatim as /usr/share/usb.ids. Cached in dist/ and refreshed with `make usb-ids`, never automatically -- the version and date are in the file's @@ -163,9 +163,10 @@ Roboto Apache-2.0 Copyright the Roboto Project Authors (https://github.com/googlefonts/roboto) Shipped as /usr/share/fonts/Roboto-Regular.ttf, from ports/Roboto. Licensed -under Apache-2.0 -- the same licence as SchOS itself, so it carries no -obligation beyond this notice. Intended for the desktop, window manager and -compositor. +under Apache-2.0. It is a separate data file loaded at run time, not code +linked into SchOS, so it sits beside the GPL as an aggregate and keeps its own +licence; the obligation is this notice. Intended for the desktop, window +manager and compositor. -------------------------------------------------------------------------------- JetBrains Mono SIL OFL 1.1 @@ -178,7 +179,7 @@ Shipped as /usr/share/fonts/JetBrainsMono-Regular.ttf, from ports/JetBrains_Mono and TTY. Under the SIL Open Font License 1.1 the font remains under OFL even inside this -Apache-2.0 system -- that does not reach any other part of SchOS -- and it may +GPL-licensed system -- that does not reach any other part of SchOS -- and it may not be sold on its own. Bundling it with an operating system is expressly permitted. JetBrains Mono declares no Reserved Font Name, so a modified version (a pre-rasterised bitmap, for instance) may keep the name. diff --git a/README.md b/README.md index 9145e8a..903f868 100644 --- a/README.md +++ b/README.md @@ -150,20 +150,17 @@ Another: **syscalls are declared in exactly one place**, ## Licensing -**Apache-2.0**, copyright Nexoniarz. See [LICENSE](LICENSE). +**GPL-2.0-or-later**, copyright Nexoniarz. See [LICENSE](LICENSE). The kernel derives from xv6, which is MIT — see [LICENSE.MIT](LICENSE.MIT). Third-party code redistributed in a built image (musl, toybox, mksh, zsh, kilo, the fonts) keeps its own licence; [NOTICE](NOTICE) carries the attributions. -All of it is permissive — there is no GPL in an image this builds, which is why -the userland is toybox and not BusyBox and the editor is kilo and not nano. See -[docs/licensing.md](docs/licensing.md). +See [docs/licensing.md](docs/licensing.md). -Drivers may be adapted from BSD sources, which are compatible. Linux drivers are -not: GPL-2.0-only and Apache-2.0 cannot be combined and redistributed. Reading -Linux to understand hardware is fine; translating a driver is not. Best of all -is the public specification — xHCI, virtio, AHCI, e1000 — which carries no -licence on what you write from it. +Drivers may be adapted from BSD sources and, since the move to the GPL, from +Linux — GPL-2.0-only code combines with GPL-2.0-or-later, and the result ships +under GPLv2. Best of all is still the public specification — xHCI, virtio, +AHCI, e1000 — which carries no licence on what you write from it. --- diff --git a/boot/README.md b/boot/README.md index e88086c..a0babf9 100644 --- a/boot/README.md +++ b/boot/README.md @@ -1,4 +1,4 @@ - + # Booting SchOS One firmware path: diff --git a/boot/common/ui.c b/boot/common/ui.c index b2576e3..8a11f73 100644 --- a/boot/common/ui.c +++ b/boot/common/ui.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 */ +/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * The loader's user interface. See ui.h for why this can be shared at all. * diff --git a/boot/common/ui.h b/boot/common/ui.h index 2f7f72b..05fc39e 100644 --- a/boot/common/ui.h +++ b/boot/common/ui.h @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 */ +/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * The loader's user interface, shared by both firmwares. * diff --git a/boot/uefi/README.md b/boot/uefi/README.md index f268c6a..c368517 100644 --- a/boot/uefi/README.md +++ b/boot/uefi/README.md @@ -1,4 +1,4 @@ - + # UEFI loader The loader. This directory once existed only so the BIOS path could be moved diff --git a/boot/uefi/efi.h b/boot/uefi/efi.h index 41a8e62..17cd2e5 100644 --- a/boot/uefi/efi.h +++ b/boot/uefi/efi.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #ifndef SCHOS_EFI_H #define SCHOS_EFI_H diff --git a/boot/uefi/main.c b/boot/uefi/main.c index 8828eb3..f49df61 100644 --- a/boot/uefi/main.c +++ b/boot/uefi/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchOS UEFI loader. // diff --git a/cmd/chvt/main.c b/cmd/chvt/main.c index 306ee1c..446d4cb 100644 --- a/cmd/chvt/main.c +++ b/cmd/chvt/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // chvt N -- show virtual terminal N. // diff --git a/cmd/httpd/main.c b/cmd/httpd/main.c index 89e9cdd..6ef505c 100644 --- a/cmd/httpd/main.c +++ b/cmd/httpd/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // httpd -- serve a directory over HTTP. // diff --git a/cmd/ldlsd/main.c b/cmd/ldlsd/main.c index dad0cbf..41f19ce 100644 --- a/cmd/ldlsd/main.c +++ b/cmd/ldlsd/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // ldlsd -- LDLS, on SchOS. // diff --git a/cmd/loadkeys/main.c b/cmd/loadkeys/main.c index 082e2dc..94ee8d9 100644 --- a/cmd/loadkeys/main.c +++ b/cmd/loadkeys/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // loadkeys -- choose the keyboard layout. // diff --git a/cmd/memfdtest/main.c b/cmd/memfdtest/main.c index c00a9d8..9a21ee4 100644 --- a/cmd/memfdtest/main.c +++ b/cmd/memfdtest/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // memfdtest -- two processes map the same memfd, one writes, the other sees it. // diff --git a/cmd/netecho/main.c b/cmd/netecho/main.c index fc8ad13..6ebb5ac 100644 --- a/cmd/netecho/main.c +++ b/cmd/netecho/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // netecho -- a network, in a process. // diff --git a/cmd/pcitest/main.c b/cmd/pcitest/main.c index 657beb1..fcf6686 100644 --- a/cmd/pcitest/main.c +++ b/cmd/pcitest/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // pcitest -- prove that a driver could live out here. // diff --git a/cmd/ping/main.c b/cmd/ping/main.c index f1dbae8..785d07c 100644 --- a/cmd/ping/main.c +++ b/cmd/ping/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // ping -- ICMP echo, over a SchOS ping socket. // diff --git a/cmd/resolvconf/main.c b/cmd/resolvconf/main.c index ee7325e..98e5431 100644 --- a/cmd/resolvconf/main.c +++ b/cmd/resolvconf/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // resolvconf -- put the nameserver where the resolver will look. // diff --git a/cmd/schdbg/main.c b/cmd/schdbg/main.c index 4cd205f..f936cb7 100644 --- a/cmd/schdbg/main.c +++ b/cmd/schdbg/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // schdbg -- ask the kernel a question. // diff --git a/cmd/schdbgd/main.c b/cmd/schdbgd/main.c index 47aeca3..1b9bb4a 100644 --- a/cmd/schdbgd/main.c +++ b/cmd/schdbgd/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // schdbgd -- the debugger, over the network. // diff --git a/cmd/schinit/main.c b/cmd/schinit/main.c index e39284d..c64f6df 100644 --- a/cmd/schinit/main.c +++ b/cmd/schinit/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // schinit -- PID 1. // diff --git a/cmd/schinitd/main.c b/cmd/schinitd/main.c index 42ef852..0b8d917 100644 --- a/cmd/schinitd/main.c +++ b/cmd/schinitd/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // schinitd -- the supervisor. PID 2, and restartable. // diff --git a/cmd/schmode/main.c b/cmd/schmode/main.c index ddbeb5c..cb28e6c 100644 --- a/cmd/schmode/main.c +++ b/cmd/schmode/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // schmode -- change the display mode. // diff --git a/cmd/sigtest/main.c b/cmd/sigtest/main.c index 03d6aa8..929155f 100644 --- a/cmd/sigtest/main.c +++ b/cmd/sigtest/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // sigtest -- the SIGCHLD/sigsuspend contract every shell is built on. // diff --git a/cmd/vgpud/main.c b/cmd/vgpud/main.c index ab5054e..7c0de9b 100644 --- a/cmd/vgpud/main.c +++ b/cmd/vgpud/main.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // vgpud -- the virtio-gpu driver, outside the kernel. // diff --git a/docs/Website/README.md b/docs/Website/README.md index af474db..e7e8d6f 100644 --- a/docs/Website/README.md +++ b/docs/Website/README.md @@ -1,4 +1,4 @@ - + # The website Three pages, two scripts, one stylesheet of its own, and the design system diff --git a/docs/Website/app.css b/docs/Website/app.css index 4868c14..4d0473b 100644 --- a/docs/Website/app.css +++ b/docs/Website/app.css @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 */ +/* SPDX-License-Identifier: GPL-2.0-or-later */ /* ========================================================================== The SchOS site — layout only -------------------------------------------------------------------------- diff --git a/docs/Website/app.js b/docs/Website/app.js index a41aa0c..de675d6 100644 --- a/docs/Website/app.js +++ b/docs/Website/app.js @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 +/* SPDX-License-Identifier: GPL-2.0-or-later * * Three behaviours, no framework: * 1. the hero console types a real boot log diff --git a/docs/Website/docs.html b/docs/Website/docs.html index d5f9e79..e978fd2 100644 --- a/docs/Website/docs.html +++ b/docs/Website/docs.html @@ -77,7 +77,7 @@

diff --git a/docs/Website/docs.js b/docs/Website/docs.js index bc6da83..7996024 100644 --- a/docs/Website/docs.js +++ b/docs/Website/docs.js @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 +/* SPDX-License-Identifier: GPL-2.0-or-later * * The documentation reader. * diff --git a/docs/Website/download.html b/docs/Website/download.html index 7d517d4..24ed328 100644 --- a/docs/Website/download.html +++ b/docs/Website/download.html @@ -283,7 +283,7 @@

diff --git a/docs/Website/index.html b/docs/Website/index.html index 674d226..dea19e1 100644 --- a/docs/Website/index.html +++ b/docs/Website/index.html @@ -92,7 +92,7 @@ What it has -

Apache-2.0 · runs from RAM · writes nothing to your disks

+

GPL-2.0-or-later · runs from RAM · writes nothing to your disks

@@ -642,7 +642,7 @@

diff --git a/docs/architecture/audio.md b/docs/architecture/audio.md index 222cd1e..5f49d12 100644 --- a/docs/architecture/audio.md +++ b/docs/architecture/audio.md @@ -1,4 +1,4 @@ - + # Audio A program that wants to make a sound opens `/dev/dsp`, writes PCM to it, and diff --git a/docs/architecture/devices.md b/docs/architecture/devices.md index a691ed6..ec89831 100644 --- a/docs/architecture/devices.md +++ b/docs/architecture/devices.md @@ -247,10 +247,11 @@ manager or equivalent, and SchOS will load it. The licensing reasoning matters and is worth stating exactly, because it is easy to get wrong in both directions: -- **Distribution is what triggers the GPL.** Shipping a GPL-2.0-only driver in - an Apache-2.0 image is what cannot be done — see [../licensing.md](../licensing.md) - §2. A user obtaining a driver themselves and loading it on their own machine - is their act, not ours, and is not a distribution by us. +- **Distribution is what triggers the GPL.** SchOS is GPL-2.0-or-later, so + shipping a GPL-2.0-only driver in an image is now *possible* — see + [../licensing.md](../licensing.md) §6 — but LDLS still does not, by policy. A + user obtaining a driver themselves and loading it on their own machine is + their act, not ours, and is not a distribution by us. - **Implementing a loader is not copying.** Writing support for a module format and a driver ABI from published documentation produces our own work. It is a clean-room implementation, and it stays one only if it is written from @@ -259,8 +260,8 @@ easy to get wrong in both directions: identifiers say. So the rule for this subsystem is the same as everywhere else in the tree: the -loader is ours and Apache-2.0, what it loads is the user's business, and nothing -GPL ever enters an image we build. `RAMDISK_EXCLUDE` and `NOTPORTS` are the +loader is ours and GPL-2.0-or-later, what it loads is the user's business, and +no third-party module enters an image we build. `RAMDISK_EXCLUDE` and `NOTPORTS` are the existing mechanisms for keeping that true mechanically rather than by intention. --- diff --git a/docs/architecture/ldls.md b/docs/architecture/ldls.md index cad69ee..6be30a0 100644 --- a/docs/architecture/ldls.md +++ b/docs/architecture/ldls.md @@ -54,9 +54,10 @@ ships the layer and never the thing it loads. `.gitignore` refuses `*.ko`, is deliberately not part of `all`, and `make ldls-unstage` takes it out again. [../licensing.md](../licensing.md) §6 is the whole argument. The short form is -that GPL obligations attach to *distribution*, we distribute Apache-2.0 code -containing no GPL, and the combination happens in a user process on the user's -machine — so no combined work is distributed by anyone. +that the combination happens in a user process on the user's machine, so no +combined work is distributed by anyone. Since SchOS moved to GPL-2.0-or-later +that is no longer the only way it *could* be done — it is the way it is done, +because a module we never ship is a module we never have to answer for. ### 2. It runs in a process, never in the kernel diff --git a/docs/architecture/terminals.md b/docs/architecture/terminals.md index 9edfb09..eb045bc 100644 --- a/docs/architecture/terminals.md +++ b/docs/architecture/terminals.md @@ -1,4 +1,4 @@ - + # Virtual terminals Six of them, `/dev/tty1` through `/dev/tty6`. diff --git a/docs/branding/README.md b/docs/branding/README.md index 7fcdb0e..16b60eb 100644 --- a/docs/branding/README.md +++ b/docs/branding/README.md @@ -55,7 +55,7 @@ the kernel's name (**SchIFT**) as a shape. coverage mask carries none, so the loader draws it in metal and the kernel in the theme accent, from the same bytes. - **With or without a wordmark.** Set "SchOS" beside it in **Roboto Bold**, - which is already in the tree (`ports/Roboto`), already Apache-2.0, and already + which is already in the tree (`ports/Roboto`), Apache-2.0, and already in `NOTICE`. - Non-human and non-animal, permanently. If a character is ever drawn it gets its own mark; a logo that starts growing a face has taken that job. diff --git a/docs/guides/building.md b/docs/guides/building.md index f785026..a4b3a5f 100644 --- a/docs/guides/building.md +++ b/docs/guides/building.md @@ -1,4 +1,4 @@ - + # Building SchOS Supported hosts: **Linux, macOS, FreeBSD/OpenBSD/NetBSD, and Windows** (under diff --git a/docs/guides/layout.md b/docs/guides/layout.md index 764986b..805a31f 100644 --- a/docs/guides/layout.md +++ b/docs/guides/layout.md @@ -130,8 +130,8 @@ file protocol, so a 6 MB ramroot kernel is visibly slower to start than the **What may go in it is a licensing question, not only a size one.** The image is linked into the kernel binary, so anything in `sysroot/` when it is built becomes part of a distributable artifact. A file staged there under a licence that -cannot be combined with Apache-2.0 does not merely ride along — it makes the -kernel itself undistributable. `RAMDISK_EXCLUDE` in the Makefile is the list of +is not ours to redistribute does not merely ride along — it makes the kernel +itself undistributable. `RAMDISK_EXCLUDE` in the Makefile is the list of paths kept out, and enforcing it in the build rather than relying on someone remembering to unstage something first is deliberate. It has been needed once already: a 33 MB test payload landed in `sysroot/` and both overflowed the image diff --git a/docs/history/moving-to-linux.md b/docs/history/moving-to-linux.md index 3d18ce2..6261890 100644 --- a/docs/history/moving-to-linux.md +++ b/docs/history/moving-to-linux.md @@ -1,4 +1,4 @@ - + # Moving the project to a Linux machine **This move happened.** The tree lives on Fedora now, and the checkout is at diff --git a/docs/licensing.md b/docs/licensing.md index 9b2bc69..22ad20d 100644 --- a/docs/licensing.md +++ b/docs/licensing.md @@ -7,24 +7,31 @@ pointed here long before this file existed. --- -## 1. SchOS is Apache-2.0 +## 1. SchOS is GPL-2.0-or-later -Copyright Nexoniarz. See `LICENSE`. +Copyright Nexoniarz. See `LICENSE`. Until 2026-10 SchOS was Apache-2.0; it was +never published under that licence, and as the sole author Nexoniarz relicensed +it outright. -Apache-2.0 was chosen over MIT/BSD for one reason that actually matters at OS -scale: it contains an **express patent grant** and a patent-retaliation clause. -MIT and BSD are silent on patents, which means a contributor can hand you code -and later assert a patent over it. For a kernel that is intended to accept -outside contributions, that silence is the expensive kind. +**Why the GPL.** Two reasons, one about others and one about us: -What that grant means in practice: Apache-2.0 §2 gives everyone a perpetual, -worldwide, irrevocable licence to reproduce, modify, sublicense and distribute -SchOS. Any additional restriction stated elsewhere — in a README, a website, -or a policy — does not narrow it. The licence text is what holds up. +- **Copyleft.** Anyone may use, study, modify and redistribute SchOS — but + whoever ships it, or something built from it, must ship the source of that + too, under the same terms. Under Apache-2.0 a fork could be closed and sold + with no changes given back. The GPL does not forbid commercial use; it forbids + taking the work private. +- **Linux.** Linux is GPL-2.0-only, and Apache-2.0 could not be combined with + it. Under the GPL, Linux drivers and code can be adopted (§2). -If restricted distribution is ever genuinely wanted, that is a licence change -(a bespoke proprietary licence, or something like BUSL-1.1 with a conversion -date), not a wording change, and it means giving up the Apache grant. +**Why "or later".** It keeps one door open that "only" would close: GPLv3 and +Apache-2.0 code can still be combined with SchOS code, with that combination +shipping under GPLv3. See §2 for why the kernel should not walk through it. + +**What was given up.** Apache-2.0 had an express patent grant; GPLv2 has only +an implied one. That mattered most for outside contributions, and there are +none yet. + +New first-party files carry `SPDX-License-Identifier: GPL-2.0-or-later`. --- @@ -36,37 +43,32 @@ date), not a wording change, and it means giving up the Apache grant. | MIT, ISC | **Yes** | Keep the notice | | BSD 2-clause | **Yes** | Keep the notice | | BSD 3-clause | **Yes** | Keep the notice; no endorsement claims | -| BSD **4-clause** (advertising) | **Avoid** — see §3 | Notice *and* an acknowledgement in advertising materials | -| Apache-2.0 | **Yes** | Keep NOTICE contents | -| MPL-2.0 | Case by case | File-level copyleft; keep those files separate | -| **GPL-2.0-only** | **No** | — | -| **GPL-3.0 / LGPL-3.0** | **No** for linked code | — | +| BSD **4-clause** (advertising) | **No** — see §3 | GPL-incompatible | +| GPL-2.0-only, GPL-2.0-or-later, LGPL-2.1 | **Yes** | Source for the combined work; keep the notices | +| MPL-2.0 | Case by case | Compatible through its secondary-licence clause, unless marked otherwise | +| Apache-2.0, GPL-3.0, LGPL-3.0 | **Not in the kernel**; separate programs and files fine | See below | **Every "yes" above requires an entry in `NOTICE`.** That file is the project's -attribution record and the thing that makes the permissive licences actually -satisfied rather than merely tolerated. +attribution record and the thing that makes the licences actually satisfied +rather than merely tolerated. -### Why GPL-2.0-only is a hard no +### One binary, one GPL version -Apache-2.0 imposes conditions GPLv2 treats as "further restrictions" under its -§6 — principally the patent-retaliation term. The FSF and the ASF agree on -this: **Apache-2.0 code and GPL-2.0-only code cannot be combined into one -distributable work.** It is not a matter of taste or of how carefully the files -are kept apart in the tree; it is that the combined binary cannot satisfy both -licences at once. +"Or later" means SchOS code can go out under GPLv2 *or* GPLv3. A single linked +binary still has to pick one: -GPL-3.0 fixed this in the other direction (Apache-2.0 is compatible *into* -GPLv3), but that does not help: the result would have to ship under GPLv3, and -SchOS does not. +- Add **Linux code** (GPL-2.0-only) and that binary is GPLv2. +- Add **Apache-2.0 or GPLv3 code** and that binary is GPLv3, because + Apache-2.0's patent terms are "further restrictions" under GPLv2 §6. -**Practical consequence:** BSD drivers can be adopted. Linux drivers cannot, -ever, no matter how convenient. This is why the USB stack was written from the -specification rather than ported. +Those two cannot meet in one binary. Linux is the main reason for the GPL, so +**the kernel stays GPLv2-compatible**: no Apache-2.0 or GPLv3 code is linked +into it. Userland programs are separate works, so one may be GPLv3 or +Apache-2.0 on its own without affecting anything else. -**"Cannot be adopted" is not the same as "cannot be run."** A driver the *user* -obtains and loads on their own machine is their act, not a distribution by us — -see §4 and [architecture/ldls.md](architecture/ldls.md), which is the layer built on exactly -that distinction and which ships no Linux code of any kind. +Data files such as fonts are not linked code. Roboto (Apache-2.0) sits beside +the system as an aggregate, and that holds inside the ramdisk too: the image is +a filesystem carried by the kernel binary, not code linked with it. --- @@ -80,7 +82,7 @@ uniformly licensed**, and the difference matters per file: |---|---| | 2-clause BSD — modern NetBSD Foundation files | **Fine** | | 3-clause, "Regents of the University of California" | **Fine.** Berkeley formally rescinded the advertising clause in 1999 | -| 4-clause with the advertising clause, **non-UC** copyright holder | **Avoid.** Berkeley's rescission covers Berkeley's copyright, not other people's | +| 4-clause with the advertising clause, **non-UC** copyright holder | **No.** Berkeley's rescission covers Berkeley's copyright, not other people's, and the clause is GPL-incompatible | The last row is real, not hypothetical. Measured on this checkout: @@ -91,10 +93,9 @@ lib/libc 101 of 1575 sys/net 5 of 180 ← the TCP/IP stack is nearly clean ``` -4-clause is still permissive and still redistributable; the burden is an -advertising obligation that accumulates quietly and is tedious to honour -properly. Prefer a 2-clause or UC-Regents file. If a 4-clause file is genuinely -the right answer, it goes into `NOTICE` with the full clause quoted. +4-clause is still permissive on its own, but the advertising clause is a +further restriction the GPL does not allow, so **a 4-clause file cannot be +combined with SchOS at all**. Use a 2-clause or UC-Regents file, or write it. Check before copying, not after: @@ -128,7 +129,7 @@ the top of the file; the UC block is a separate licence further down. Berkeley never spoke for WIDE, so the rescission does not reach it. The two most valuable files in the stack are the two encumbered ones. -That is not fatal — 4-clause is still permissive — but it is exactly the case +Under the GPL that rules them out, and it is exactly the case where a **second BSD tree earns its disk space**: FreeBSD's TCP has been through a relicensing effort NetBSD's has not, so the same file there may well be 2-clause. Check it the same way before assuming either: @@ -180,13 +181,13 @@ Chosen 2026-08-09, both licences checked at source rather than assumed: | Roboto | desktop, window manager, compositor | **Apache-2.0** | | JetBrains Mono | terminal, TTY | **SIL OFL 1.1** | -Roboto is the same licence as SchOS, so it is the easy case: a NOTICE entry -and nothing else. +Roboto is Apache-2.0, which is fine for a font: it is a data file beside the +system, not code linked into it (§2). A NOTICE entry and nothing else. OFL is permissive and bundling is precisely what it is for, with two conditions worth knowing before anyone subsets or converts a font: -- **The font stays under OFL** even inside an Apache-2.0 system. It does not +- **The font stays under OFL** even inside a GPL-licensed system. It does not infect anything else; it just cannot be relicensed. - **It may not be sold on its own.** Shipping it as part of an OS is fine. - **Reserved Font Names.** JetBrains Mono declares *none* -- its copyright line @@ -212,42 +213,17 @@ with SchOS. Keeping the distinction sharp is what stops it eroding: rebuild never needs the network; not part of any image, and not all of it is redistributable. -### The userland this rules out, and what was done instead +### The userland, and why it is permissive anyway -The rule costs something real and it is worth naming the bill rather than only -the principle. +While SchOS was Apache-2.0, **BusyBox** (GPL-2.0-only) and **nano** (GPL-3.0) +were ruled out, and the userland was built from toybox (0BSD), mksh and kilo +(BSD-2-Clause) instead. Both would be possible now — nano as a separate program +— but nothing needs replacing: toybox gives 268 applets, kilo is installed as +`/bin/edit`, and `cmd/httpd` is first-party. -**BusyBox** is the obvious userland for a system this size — about four hundred -applets, including a shell, an editor, `less` and an `httpd`. It is -**GPL-2.0-only**, so §2 applies, and here the consequence is sharper than -"cannot be linked": `make ramroot` links the root filesystem image *into the -kernel binary*, so a BusyBox in `sysroot/` would put GPLv2 code inside an -Apache-2.0 executable. Excluding it from the ramdisk avoids that and leaves the -ramroot build with no userland at all, which is not a trade worth making. - -**nano** is the same answer for the same reason, one version later: GPL-3.0, -which is incompatible with Apache-2.0 in the other direction. - -What was done instead, when the complaint "the userland is too thin" came up: - -| wanted | answer | -|---|---| -| `awk`, `bc`, `diff`, `more`, `expr`, `tr`, … | already in toybox, in `toys/pending/`, switched off by `defconfig`. Turning 26 of them on took the shipped set from 236 applets to 268, at no licensing cost — it is the same 0BSD tarball. | -| an editor that is not `vi` | [kilo](https://github.com/antirez/kilo), BSD-2-Clause, one file, no dependencies. Installed as `/bin/edit` as well as `/bin/kilo`. | -| `wget` that works | not a userland problem at all. See below. | -| something to host with | `cmd/httpd`, written here, Apache-2.0. | - -The `wget` one is worth recording because it was diagnosed wrongly at first, -and switching userland would not have fixed it: **SchOS had no DNS reachable -from a process**, so every program taking a hostname failed and each looked -like its own bug. BusyBox's `wget` would have failed identically. musl already -contains a complete resolver; the only missing fact was which nameserver, which -the kernel had all along from DHCP and never published. See -[architecture/networking.md](architecture/networking.md). - -The general shape: **a permissive answer existed for every one of these**, and -three of the four were already in the tree. That will not always be true, and -when it is not the answer is still no. +The `wget` failure that started that discussion was not a userland problem: +SchOS had no DNS reachable from a process, which BusyBox would have hit +identically. See [architecture/networking.md](architecture/networking.md). The mechanisms that keep this from eroding, since good intentions have already failed once here: @@ -286,22 +262,26 @@ copied file is a file to be understood, attributed and maintained forever. ## 6. LDLS, and the distribution boundary -[architecture/ldls.md](architecture/ldls.md) runs Linux drivers. That sounds like it should -contradict §2, and it does not, because the two questions below are different -ones and only the first is about us. +[architecture/ldls.md](architecture/ldls.md) runs Linux drivers. This section +was written when SchOS was Apache-2.0 and the boundary below was a legal +necessity. Under GPL-2.0-or-later it is a **project policy** instead: shipping +a GPL-2.0-only `.ko` with SchOS would now be lawful, provided the source goes +with it. It is still not done, because a module we never ship is a module we +never have to vouch for, track upstream, or provide source for. -### LDLS is Apache-2.0 +### LDLS is ours -Every file under `ldls/` is ours. The loader was written from the ELF-64 gABI -and the x86-64 psABI; the shim is written under the rule in -[architecture/ldls.md](architecture/ldls.md). **No Linux code is in it and none ever will -be**, which is the same standard the xHCI and USB stacks already meet (§5). +Every file under `ldls/` is ours, GPL-2.0-or-later. The loader was written from +the ELF-64 gABI and the x86-64 psABI; the shim is written under the rule in +[architecture/ldls.md](architecture/ldls.md). Copying Linux code into it would +no longer be a licence problem, but the shim's value is that it is small and +understood, so the existing rule stands. -### The combination is not ours to make +### The combination is the user's | | licence | who distributes it | |---|---|---| -| `ldls/` — loader, shim, host | **Apache-2.0** | us | +| `ldls/` — loader, shim, host | **GPL-2.0-or-later** | us | | a `.ko` | GPL-2.0-only, usually | the user's distribution | | the two running together in a process | — | **nobody** | @@ -311,20 +291,10 @@ GPLv2 §0 is explicit about where its obligations attach: > by this License; they are outside its scope. **The act of running the Program > is not restricted.** -So: we ship Apache-2.0 code containing no GPL. The user obtains a GPL module -from wherever they get their software. The user runs them together on their own -machine. No combined work is distributed by anyone, and no GPL obligation is -triggered — not on us, and not on them. - -This is the position FreeBSD has shipped from for about a decade: a -BSD-licensed `linuxkpi` in base, GPL `drm-kmod` installed by the user from -ports. - -**The consequence for the user, stated plainly:** they cannot redistribute the -combination either. An image with a `.ko` baked into it is a single work that -would have to satisfy Apache-2.0 and GPL-2.0-only at once, which §2 explains is -impossible. That is why `RAMDISK_EXCLUDE` exists, and why `.gitignore` refuses -`*.ko` outright — the boundary is kept mechanically rather than by intention. +So: we ship LDLS and no modules. The user obtains a module from wherever they +get their software and runs it on their own machine. `RAMDISK_EXCLUDE` and the +`*.ko` rule in `.gitignore` keep that boundary mechanical rather than +intentional. ### `EXPORT_SYMBOL_GPL` does not apply @@ -335,7 +305,7 @@ that. **LDLS has no Linux symbols to gate.** `EXPORT_SYMBOL_GPL` is Linux marking *Linux's own* symbols, and the check it drives protects those. Every symbol -LDLS provides is ours — reimplemented from facts, under Apache-2.0. There is no +LDLS provides is ours — reimplemented from facts, under GPL-2.0-or-later. There is no gate being bypassed, because there is no Linux symbol being exposed. So LDLS implements no licence check. It **reads** the module's declared licence diff --git a/docs/plan/wayland.md b/docs/plan/wayland.md index da3717b..fb10d62 100644 --- a/docs/plan/wayland.md +++ b/docs/plan/wayland.md @@ -135,10 +135,9 @@ in `NOTICE` **before** the file is committed, not after. | libxkbcommon | MIT | | xkeyboard-config | MIT | -All Apache-2.0 compatible, all needing only a `NOTICE` entry. **Nothing here -carries the GPL problem that governs drivers**, which is a pleasant change and -worth noticing: the Wayland ecosystem is permissively licensed almost throughout, -and that is a genuine argument for it beyond any technical one. +All GPL-2.0-or-later compatible, all needing only a `NOTICE` entry. The +Wayland ecosystem is permissively licensed almost throughout, so nothing here +raises a licensing question at all. --- diff --git a/include/fsstat.h b/include/fsstat.h index aa252f2..812ca1b 100644 --- a/include/fsstat.h +++ b/include/fsstat.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Counters for the filesystem and block paths, read through /proc/fsstat. // diff --git a/include/pciuser.h b/include/pciuser.h index ee5f625..49f5da8 100644 --- a/include/pciuser.h +++ b/include/pciuser.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // /dev/pci -- device access from userspace. // diff --git a/include/posix.h b/include/posix.h index 8bd3458..2f71acb 100644 --- a/include/posix.h +++ b/include/posix.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // SchOS — POSIX-compatibility types used by kernel syscall handlers. #pragma once #include "types.h" diff --git a/include/schboot.h b/include/schboot.h index 096b7ac..ccac702 100644 --- a/include/schboot.h +++ b/include/schboot.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #ifndef SCHBOOT_H #define SCHBOOT_H diff --git a/include/schinit.h b/include/schinit.h index 7d0d5db..2879850 100644 --- a/include/schinit.h +++ b/include/schinit.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The protocol between PID 1 and the supervisor. // diff --git a/include/vt.h b/include/vt.h index 26c3f73..8817bc3 100644 --- a/include/vt.h +++ b/include/vt.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Virtual terminals. // diff --git a/kernel/arch/x86_64/watch.c b/kernel/arch/x86_64/watch.c index 99b204a..19bb6d3 100644 --- a/kernel/arch/x86_64/watch.c +++ b/kernel/arch/x86_64/watch.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Hardware watchpoints. docs/architecture/debugging.md milestone D4. // diff --git a/kernel/core/klog.c b/kernel/core/klog.c index f7e5ec6..d655f4a 100644 --- a/kernel/core/klog.c +++ b/kernel/core/klog.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The kernel log that outlives the kernel. See include/klog.h. // diff --git a/kernel/core/ksym.c b/kernel/core/ksym.c index b6dcc90..25c36c9 100644 --- a/kernel/core/ksym.c +++ b/kernel/core/ksym.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Naming an address. // diff --git a/kernel/core/panic.c b/kernel/core/panic.c index f6380c6..b8efe60 100644 --- a/kernel/core/panic.c +++ b/kernel/core/panic.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // PSOGM — the SchOS crash screen. // diff --git a/kernel/core/sbuf.c b/kernel/core/sbuf.c index c071a56..6163f67 100644 --- a/kernel/core/sbuf.c +++ b/kernel/core/sbuf.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The bounded string builder. See include/sbuf.h for what it is and why it // moved out of kernel/dev/procfs.c. diff --git a/kernel/dev/dbg.c b/kernel/dev/dbg.c index 8274b51..ad8947f 100644 --- a/kernel/dev/dbg.c +++ b/kernel/dev/dbg.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // /dev/dbg -- asking the kernel a question. See include/dbg.h. // diff --git a/kernel/dev/netuser.c b/kernel/dev/netuser.c index fc51114..fde83af 100644 --- a/kernel/dev/netuser.c +++ b/kernel/dev/netuser.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // /dev/netdev -- a network interface whose backend is a process. // See include/netuser.h. diff --git a/kernel/dev/pciuser.c b/kernel/dev/pciuser.c index 95eea90..dc567e7 100644 --- a/kernel/dev/pciuser.c +++ b/kernel/dev/pciuser.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // /dev/pci -- PCI devices, reachable from userspace. // diff --git a/kernel/dev/vt.c b/kernel/dev/vt.c index c38e0a9..96f10e9 100644 --- a/kernel/dev/vt.c +++ b/kernel/dev/vt.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Virtual terminals. See include/vt.h for why this exists at all; the short // version is that switching needs a backing store, and the console drew diff --git a/kernel/drivers/bus/xhci/xhci.c b/kernel/drivers/bus/xhci/xhci.c index afad6e3..24dfa58 100644 --- a/kernel/drivers/bus/xhci/xhci.c +++ b/kernel/drivers/bus/xhci/xhci.c @@ -10,9 +10,9 @@ // the controller is not complicated; BSD is much more valuable as the // reference you check yourself against than as the code you paste. // -// (Licensing points the same way. The BSD stacks are BSD-2/3-clause, which is -// compatible with Apache-2.0 -- Linux's drivers are GPL-2.0-only, which is -// not. See docs/guides/adding-a-driver.md.) +// (Licensing no longer decides it: the BSD stacks are BSD-2/3-clause and +// Linux's drivers are GPL-2.0-only, and both combine with GPL-2.0-or-later. +// The argument above is the whole reason. See docs/licensing.md.) // // Enumeration polls the event ring instead of using interrupts. That is not // laziness: pci_bind_all() runs from kmain() with interrupts disabled and no diff --git a/kernel/fs/devfs.c b/kernel/fs/devfs.c index 9520548..5300758 100644 --- a/kernel/fs/devfs.c +++ b/kernel/fs/devfs.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // devtmpfs: /dev, generated rather than stored. // diff --git a/kernel/fs/schfs/attr.c b/kernel/fs/schfs/attr.c index 9f3af98..bc5fc99 100644 --- a/kernel/fs/schfs/attr.c +++ b/kernel/fs/schfs/attr.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Attributes, and the index over them. // diff --git a/kernel/fs/schfs/btree.c b/kernel/fs/schfs/btree.c index be944e0..ab8007e 100644 --- a/kernel/fs/schfs/btree.c +++ b/kernel/fs/schfs/btree.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS copy-on-write B-tree — see btree.h for the contract. // diff --git a/kernel/fs/schfs/kmount.c b/kernel/fs/schfs/kmount.c index 91f36e5..ec34c38 100644 --- a/kernel/fs/schfs/kmount.c +++ b/kernel/fs/schfs/kmount.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS in the kernel: block device, mount, and the transaction bracket. // diff --git a/kernel/fs/schfs/obj.c b/kernel/fs/schfs/obj.c index 016cf65..465f871 100644 --- a/kernel/fs/schfs/obj.c +++ b/kernel/fs/schfs/obj.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS object layer, read side: inodes, directories and file data. // diff --git a/kernel/fs/schfs/objw.c b/kernel/fs/schfs/objw.c index 9bed93c..0e6d2a2 100644 --- a/kernel/fs/schfs/objw.c +++ b/kernel/fs/schfs/objw.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS object layer, write side: create, link, unlink, rename, write, // truncate. diff --git a/kernel/fs/schfs/schfs_int.h b/kernel/fs/schfs/schfs_int.h index 61d690b..6223bd8 100644 --- a/kernel/fs/schfs/schfs_int.h +++ b/kernel/fs/schfs/schfs_int.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS internals: the volume (uberblock ring, block allocation) and the object // layer (inodes, directories, file data) that sit on top of the B-tree. diff --git a/kernel/fs/schfs/space.c b/kernel/fs/schfs/space.c index d45a615..4851ded 100644 --- a/kernel/fs/schfs/space.c +++ b/kernel/fs/schfs/space.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS space manager: which blocks are in use. // diff --git a/kernel/fs/schfs/vfs.c b/kernel/fs/schfs/vfs.c index 18b68e3..074f2f3 100644 --- a/kernel/fs/schfs/vfs.c +++ b/kernel/fs/schfs/vfs.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS behind the VFS: the fs_ops table that makes SchFS files reachable // through open(2), read(2), write(2) and the rest. diff --git a/kernel/fs/schfs/vol.c b/kernel/fs/schfs/vol.c index 8e6f395..5afb35d 100644 --- a/kernel/fs/schfs/vol.c +++ b/kernel/fs/schfs/vol.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // SchFS volume layer: the uberblock ring. // diff --git a/kernel/net/inet.c b/kernel/net/inet.c index 14170bd..153a7a5 100644 --- a/kernel/net/inet.c +++ b/kernel/net/inet.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // AF_INET sockets, on top of lwIP's raw API. // diff --git a/kernel/net/lwip/arch/cc.h b/kernel/net/lwip/arch/cc.h index 23edfd2..f5556b2 100644 --- a/kernel/net/lwip/arch/cc.h +++ b/kernel/net/lwip/arch/cc.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // lwIP's compiler/platform header for SchOS. // diff --git a/kernel/net/lwip/lwipopts.h b/kernel/net/lwip/lwipopts.h index 0a5cf8f..3e98f7f 100644 --- a/kernel/net/lwip/lwipopts.h +++ b/kernel/net/lwip/lwipopts.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // lwIP configuration for SchOS. // diff --git a/kernel/net/lwip/netif_eth.c b/kernel/net/lwip/netif_eth.c index 6ca880b..e69bfbe 100644 --- a/kernel/net/lwip/netif_eth.c +++ b/kernel/net/lwip/netif_eth.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // lwIP network interfaces over the netdev class. // diff --git a/kernel/net/lwip/shim/ctype.h b/kernel/net/lwip/shim/ctype.h index 22f4e81..c5a4d68 100644 --- a/kernel/net/lwip/shim/ctype.h +++ b/kernel/net/lwip/shim/ctype.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/errno.h b/kernel/net/lwip/shim/errno.h index d5dab31..0336e2e 100644 --- a/kernel/net/lwip/shim/errno.h +++ b/kernel/net/lwip/shim/errno.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/inttypes.h b/kernel/net/lwip/shim/inttypes.h index 8bac6d7..b25b60b 100644 --- a/kernel/net/lwip/shim/inttypes.h +++ b/kernel/net/lwip/shim/inttypes.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/limits.h b/kernel/net/lwip/shim/limits.h index cf216cb..a0127a9 100644 --- a/kernel/net/lwip/shim/limits.h +++ b/kernel/net/lwip/shim/limits.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/stddef.h b/kernel/net/lwip/shim/stddef.h index 2ef845f..f84610d 100644 --- a/kernel/net/lwip/shim/stddef.h +++ b/kernel/net/lwip/shim/stddef.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/stdint.h b/kernel/net/lwip/shim/stdint.h index 448ead0..caa83aa 100644 --- a/kernel/net/lwip/shim/stdint.h +++ b/kernel/net/lwip/shim/stdint.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/stdio.h b/kernel/net/lwip/shim/stdio.h index 1ded07a..e8b1dee 100644 --- a/kernel/net/lwip/shim/stdio.h +++ b/kernel/net/lwip/shim/stdio.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/shim/stdlib.h b/kernel/net/lwip/shim/stdlib.h index a1487aa..8d7fbdf 100644 --- a/kernel/net/lwip/shim/stdlib.h +++ b/kernel/net/lwip/shim/stdlib.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // for lwIP, shadowing the host's. See shim/string.h for why these // files exist at all. diff --git a/kernel/net/lwip/shim/string.h b/kernel/net/lwip/shim/string.h index 7d48318..3014ff3 100644 --- a/kernel/net/lwip/shim/string.h +++ b/kernel/net/lwip/shim/string.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // for lwIP, shadowing the host's. // diff --git a/kernel/net/lwip/shim/unistd.h b/kernel/net/lwip/shim/unistd.h index ce7dac9..1da3a31 100644 --- a/kernel/net/lwip/shim/unistd.h +++ b/kernel/net/lwip/shim/unistd.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // for lwIP, shadowing the host's. // // Empty on purpose. Everything lwIP would take from this header is supplied by diff --git a/kernel/net/lwip/sys_arch.c b/kernel/net/lwip/sys_arch.c index 4b795a0..e30f32d 100644 --- a/kernel/net/lwip/sys_arch.c +++ b/kernel/net/lwip/sys_arch.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The lwIP port layer: everything lwIP needs from the system it runs on. // diff --git a/kernel/net/net.c b/kernel/net/net.c index cd6cf66..8df5079 100644 --- a/kernel/net/net.c +++ b/kernel/net/net.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The network thread, and the one place the TCP/IP stack is started. // diff --git a/kernel/net/netlink.c b/kernel/net/netlink.c index 50e77f8..bf6df10 100644 --- a/kernel/net/netlink.c +++ b/kernel/net/netlink.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // rtnetlink, enough of it that getifaddrs(3) works. // diff --git a/kernel/sys/linux_abi.c b/kernel/sys/linux_abi.c index 4d67567..768c5a8 100644 --- a/kernel/sys/linux_abi.c +++ b/kernel/sys/linux_abi.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // Linux x86_64 syscall number -> SchOS syscall number translation. // Enabled per process by sys_enable_linux_abi (see kernel/sys/sys_compat.c). // diff --git a/ldls/btf.c b/ldls/btf.c index be60393..925a55f 100644 --- a/ldls/btf.c +++ b/ldls/btf.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Reading BTF. See ldls/btf.h. // diff --git a/ldls/btf.h b/ldls/btf.h index 3ffb7ea..2ecea54 100644 --- a/ldls/btf.h +++ b/ldls/btf.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Reading BTF: struct layouts and function prototypes, from the kernel that // the driver was built for. diff --git a/ldls/host/inspect.c b/ldls/host/inspect.c index d172d9e..bb0c8b5 100644 --- a/ldls/host/inspect.c +++ b/ldls/host/inspect.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // ldls-inspect -- what is in a relocatable object, and what it wants. // diff --git a/ldls/host/run.c b/ldls/host/run.c index 9e62764..6da1e26 100644 --- a/ldls/host/run.c +++ b/ldls/host/run.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // ldls-run -- load a module and call its init, on the build machine. // diff --git a/ldls/host/types.c b/ldls/host/types.c index 299a98f..a892228 100644 --- a/ldls/host/types.c +++ b/ldls/host/types.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // ldls-types -- ask a kernel's BTF where its fields are. // diff --git a/ldls/ko.c b/ldls/ko.c index fbda287..46783bb 100644 --- a/ldls/ko.c +++ b/ldls/ko.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Loading a relocatable object. See ldls/ko.h. // diff --git a/ldls/ko.h b/ldls/ko.h index 452fbc6..c1fb867 100644 --- a/ldls/ko.h +++ b/ldls/ko.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once // Loading a relocatable object. docs/architecture/ldls.md, "The loader". diff --git a/ldls/kpi/io.c b/ldls/kpi/io.c index a5230ad..f78414a 100644 --- a/ldls/kpi/io.c +++ b/ldls/kpi/io.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Register access. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/kpi/kpi.c b/ldls/kpi/kpi.c index c929f03..2744288 100644 --- a/ldls/kpi/kpi.c +++ b/ldls/kpi/kpi.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The KPI, and the table the loader resolves against. See ldls/kpi/kpi.h. // diff --git a/ldls/kpi/kpi.h b/ldls/kpi/kpi.h index 460da0f..7e3cdb0 100644 --- a/ldls/kpi/kpi.h +++ b/ldls/kpi/kpi.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The KPI: the Linux symbols a hosted driver actually calls, implemented. // diff --git a/ldls/kpi/net.c b/ldls/kpi/net.c index c72d038..047fa9c 100644 --- a/ldls/kpi/net.c +++ b/ldls/kpi/net.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The network half of the KPI. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/kpi/pci.c b/ldls/kpi/pci.c index 27833b9..f3d2b91 100644 --- a/ldls/kpi/pci.c +++ b/ldls/kpi/pci.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The PCI half of the KPI. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/kpi/skb.c b/ldls/kpi/skb.c index 500f0b0..275b9af 100644 --- a/ldls/kpi/skb.c +++ b/ldls/kpi/skb.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Socket buffers. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/kpi/string.c b/ldls/kpi/string.c index 0e1e468..db39f84 100644 --- a/ldls/kpi/string.c +++ b/ldls/kpi/string.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The string and memory primitives. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/kpi/thunk.c b/ldls/kpi/thunk.c index 8d8ec91..b03e73b 100644 --- a/ldls/kpi/thunk.c +++ b/ldls/kpi/thunk.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Retpoline thunks. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/kpi/work.c b/ldls/kpi/work.c index 60124a0..353dda3 100644 --- a/ldls/kpi/work.c +++ b/ldls/kpi/work.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // A driver's periodic work. See ldls/kpi/kpi.h for the provenance rule. // diff --git a/ldls/stub.c b/ldls/stub.c index e7c2c55..8d22310 100644 --- a/ldls/stub.c +++ b/ldls/stub.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Stubs. See ldls/stub.h. // diff --git a/ldls/stub.h b/ldls/stub.h index 90f8df0..0b662a4 100644 --- a/ldls/stub.h +++ b/ldls/stub.h @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // Stubs: giving every undefined symbol an address that says who it was. // diff --git a/ldls/test/refmod.c b/ldls/test/refmod.c index 9a2c423..d61e113 100644 --- a/ldls/test/refmod.c +++ b/ldls/test/refmod.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // The loader's test object. **Ours, on purpose.** // @@ -70,7 +70,7 @@ ldls_test_twice(void) // own section. A real one is produced by MODULE_LICENSE() and friends; this is // the same bytes by hand, because the macros that emit them are not ours. #define MODINFO __attribute__((section(".modinfo"), used, aligned(1))) -MODINFO static const char mi_license[] = "license=Apache-2.0"; +MODINFO static const char mi_license[] = "license=GPL"; MODINFO static const char mi_description[] = "description=LDLS loader test object"; MODINFO static const char mi_name[] = "name=refmod"; diff --git a/lib/glue.c b/lib/glue.c index fe5cf34..19992e0 100644 --- a/lib/glue.c +++ b/lib/glue.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // SchOS — first-party userland runtime: _start entry and exit. #include "types.h" diff --git a/lib/start.S b/lib/start.S index f9dd4c8..08d8cb4 100644 --- a/lib/start.S +++ b/lib/start.S @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 +/* SPDX-License-Identifier: GPL-2.0-or-later * SchOS — process entry point. * * This has to be assembly, and the reason is worth recording. diff --git a/ports/Makefile b/ports/Makefile index 575331f..34315f9 100644 --- a/ports/Makefile +++ b/ports/Makefile @@ -1,6 +1,6 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # SchOS ports — third-party software, one directory per port. -# All ports are permissive-licensed (MIT, BSD, 0BSD, Apache 2.0). +# Every port's licence must combine with GPL-2.0-or-later; see docs/licensing.md. # # ports/musl/ libc — installs headers/libs to build/ports/musl/prefix # ports/mksh/ MirBSD Korn Shell — installed as sysroot/bin/sh @@ -17,7 +17,7 @@ # Ports that live in this directory but are deliberately not built by `make`. # Empty for now; the filter stays because the reason it existed will recur -- -# a port whose licence cannot be combined with Apache-2.0 can be kept here for +# a port whose licence cannot be combined with GPL-2.0-or-later can be kept here for # local testing but must never be built into a SchOS image. NOTPORTS := PORTS := $(filter-out $(NOTPORTS), \ diff --git a/ports/fastfetch/Makefile b/ports/fastfetch/Makefile index 121bb20..3df7b99 100644 --- a/ports/fastfetch/Makefile +++ b/ports/fastfetch/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # fastfetch -- system information, MIT: https://github.com/fastfetch-cli/fastfetch # # Here because it is a good acceptance test, not because SchOS needs a fetch diff --git a/ports/kilo/Makefile b/ports/kilo/Makefile index 50cadba..dbb0e59 100644 --- a/ports/kilo/Makefile +++ b/ports/kilo/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # kilo — BSD-2-Clause: https://github.com/antirez/kilo # # SchOS's text editor, installed as sysroot/bin/kilo with `edit` beside it. @@ -11,9 +11,9 @@ # # The whole editor is one 1,300-line C file with no dependencies beyond libc -- # termios and TIOCGWINSZ, both of which SchOS already has because zsh needs -# them. That is the entire reason it was chosen over nano: nano is GPLv3 and -# wants ncurses at runtime, and GPLv3 cannot be combined with Apache-2.0 any -# more than GPLv2 can. See ../../docs/licensing.md. +# them. That, and licensing at the time, is why it was chosen over nano: nano +# is GPLv3 and wants ncurses at runtime, and SchOS was then Apache-2.0. Under +# GPL-2.0-or-later nano is possible, but kilo already does the job. # # What it does not do: no undo, no multiple buffers, no configuration, no # mouse, no UTF-8 beyond passing bytes through. It edits one file. diff --git a/ports/lwip/Makefile b/ports/lwip/Makefile index 250e320..4936e45 100644 --- a/ports/lwip/Makefile +++ b/ports/lwip/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # lwIP — the TCP/IP stack. BSD-3-clause (no advertising clause); see COPYING in # the tarball and docs/licensing.md. # diff --git a/ports/mk/port.mk b/ports/mk/port.mk index d1ece15..a2b29d4 100644 --- a/ports/mk/port.mk +++ b/ports/mk/port.mk @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # Shared definitions for all SchOS ports. # Include this at the top of each port's Makefile: include ../mk/port.mk # diff --git a/ports/mksh/Makefile b/ports/mksh/Makefile index c758ea3..a99a886 100644 --- a/ports/mksh/Makefile +++ b/ports/mksh/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # mksh (MirBSD Korn Shell) — permissive: https://www.mirbsd.org/mksh.htm # Installed as /bin/sh — SchOS standardizes on "sh" as the one shell name; # no ksh/dash/other aliases are installed or looked up by init. diff --git a/ports/musl/Makefile b/ports/musl/Makefile index 3a16645..8bb485e 100644 --- a/ports/musl/Makefile +++ b/ports/musl/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # musl libc — MIT-licensed: https://musl.libc.org/ # # Installs into $(PREFIX) (= build/ports/musl/prefix), which port.mk exports diff --git a/ports/ncurses/Makefile b/ports/ncurses/Makefile index 9caf01f..6ecb26e 100644 --- a/ports/ncurses/Makefile +++ b/ports/ncurses/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # ncurses -- terminal capability database and screen library, MIT: # https://invisible-island.net/ncurses/ # diff --git a/ports/ncurses/tinfotest.c b/ports/ncurses/tinfotest.c index f0c9812..2281c4a 100644 --- a/ports/ncurses/tinfotest.c +++ b/ports/ncurses/tinfotest.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 +/* SPDX-License-Identifier: GPL-2.0-or-later * * ncurses acceptance test for SchOS. * diff --git a/ports/toybox/Makefile b/ports/toybox/Makefile index 34ec7e2..3cdda96 100644 --- a/ports/toybox/Makefile +++ b/ports/toybox/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # toybox — 0BSD-licensed: https://landley.net/toybox/ # Provides SchOS's core utilities (ls, cat, cp, mv, rm, mkdir, ...) as a # single multicall binary, installed under sysroot/bin/ once per applet name. diff --git a/ports/zsh/Makefile b/ports/zsh/Makefile index 56687b9..b893b8b 100644 --- a/ports/zsh/Makefile +++ b/ports/zsh/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # zsh -- the Z shell, MIT-like: https://www.zsh.org/ # # Installed as /bin/zsh, *beside* mksh, which keeps /bin/sh. diff --git a/projects/schcom/Makefile b/projects/schcom/Makefile index 9b89a82..90cbd2e 100644 --- a/projects/schcom/Makefile +++ b/projects/schcom/Makefile @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # # Schcom builds like any other program that runs *on* SchOS: against the # sysroot's libc, never against kernel headers. The top-level Makefile passes diff --git a/projects/schcom/README.md b/projects/schcom/README.md index cf9de53..86fc93c 100644 --- a/projects/schcom/README.md +++ b/projects/schcom/README.md @@ -90,7 +90,7 @@ make schcom-test # boots it and checks the pixels The protocol is deliberately Wayland-shaped — surfaces rather than windows, buffers attached and made visible only on commit, and the compositor telling clients when to draw. Wayland is **MIT-licensed**, so it can be linked against -without any conflict with Apache-2.0 (see `docs/licensing.md`), and +without any conflict with GPL-2.0-or-later (see `docs/licensing.md`), and supporting it later is intended. The one place v0 knowingly diverges: a buffer handle is a System V shared memory diff --git a/projects/schcom/proto.h b/projects/schcom/proto.h index f8925ee..f7ebf15 100644 --- a/projects/schcom/proto.h +++ b/projects/schcom/proto.h @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 */ +/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * The Schcom wire protocol. * diff --git a/projects/schcom/schcom-demo.c b/projects/schcom/schcom-demo.c index bde9dbb..dc4bdeb 100644 --- a/projects/schcom/schcom-demo.c +++ b/projects/schcom/schcom-demo.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 */ +/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * A Schcom client, and the test for the compositor. * diff --git a/projects/schcom/schcom.c b/projects/schcom/schcom.c index c7fec79..7a45438 100644 --- a/projects/schcom/schcom.c +++ b/projects/schcom/schcom.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: Apache-2.0 */ +/* SPDX-License-Identifier: GPL-2.0-or-later */ /* * Schcom -- the SchOS compositor. * diff --git a/projects/schfs-linux/LICENSE b/projects/schfs-linux/LICENSE index 2b68d3d..d159169 100644 --- a/projects/schfs-linux/LICENSE +++ b/projects/schfs-linux/LICENSE @@ -1,178 +1,339 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. - 1. Definitions. + Preamble - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. - "Work" shall mean the work of authorship made available under - the License, as indicated by a copyright notice that is included in - or attached to the work (an example is provided in the Appendix below). + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. + The precise terms and conditions for copying, distribution and +modification follow. - "Contribution" shall mean, as submitted to the Licensor for inclusion - in the Work by the copyright owner or by an individual or Legal Entity - authorized to submit on behalf of the copyright owner. For the purposes - of this definition, "contribution" means any work of authorship, - including the original version of the Work and any modifications or - additions to that Work or Derivative Works of the Work. + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - "Contributor" shall mean Licensor and any Legal Entity on behalf of - whom a Contribution has been received by the Licensor and included - within the Work. + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by the combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a cross-claim - or counterclaim in a lawsuit) alleging that the Work or any - Contribution embodied within the Work constitutes patent or - contributory patent infringement, then any patent licenses granted to - You under this License for that Work shall terminate as of the date - such litigation is filed. + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. - (d) If the Work includes a "NOTICE" text file as part of its - distribution, You must include a readable copy of the - attribution notices contained within such NOTICE file, in - at least one of the following places: within a NOTICE text - file distributed as part of the Derivative Works; within - the Source form or documentation, if provided along with the - Derivative Works; or, within a display generated by the - Derivative Works, if and wherever such third-party notices - normally appear. The contents of the NOTICE file are for - informational purposes only and do not modify the License. - You may add Your own attribution notices within Derivative - Works that You distribute, alongside or in addition to the - NOTICE text from the Work, provided that such additional - attribution notices cannot be construed as modifying the License. + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) - You may add Your own license statement for Your modifications and - may provide additional grant of rights to use, copy, modify, and - distribute those modifications as a separate work, subject to the - terms and conditions of this License. +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any conditions of TITLE, - NONINFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. - You are solely responsible for determining the appropriateness of - using or reproducing the Work and assume any risks associated with - Your exercise of permissions under this License. + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or exemplary damages of any character arising as a - result of this License or out of the use or inability to use the - Work (even if such Contributor has been advised of the possibility - of such damages). + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may offer such - obligations only on Your behalf and on Your sole responsibility, - not on behalf of any other Contributor, and only if You agree to - indemnify, defend, and hold each Contributor harmless for any - liability incurred by, or claims asserted against, such Contributor - by reason of your accepting any warranty or additional liability. + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, - END OF TERMS AND CONDITIONS + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) - Copyright 2026 Nexoniarz +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. - http://www.apache.org/licenses/LICENSE-2.0 + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. - Copyright 2026 Nexoniarz + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. diff --git a/projects/schfs-linux/README.md b/projects/schfs-linux/README.md index 4a55e34..f10be52 100644 --- a/projects/schfs-linux/README.md +++ b/projects/schfs-linux/README.md @@ -61,12 +61,8 @@ how you end up maintaining two of them. ## Licence -Apache-2.0. See [LICENSE](LICENSE). +GPL-2.0-or-later, like the rest of SchOS. See [LICENSE](LICENSE). -Apache-2.0 rather than MIT or BSD for one reason that matters at this level: it -contains an express patent grant and a patent-retaliation clause. MIT and BSD -are silent on patents, which means a contributor can hand you code and later -assert a patent over it. - -Note that a Linux **kernel module** is a different licensing question from FUSE, -and one reason the FUSE implementation comes first. +That also settles the kernel-module question in advance: a Linux module under a +GPL-compatible licence can use `EXPORT_SYMBOL_GPL` interfaces and does not taint +the kernel. The FUSE implementation still comes first, for the reason above. diff --git a/tools/ksyms.pl b/tools/ksyms.pl index bb56b55..a24b131 100644 --- a/tools/ksyms.pl +++ b/tools/ksyms.pl @@ -1,5 +1,5 @@ #!/usr/bin/perl -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # # Turn `nm -n kernel` into a symbol table the kernel can carry with it. # diff --git a/tools/mkschfs.c b/tools/mkschfs.c index 6a16543..a869817 100644 --- a/tools/mkschfs.c +++ b/tools/mkschfs.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // mkschfs — build a SchFS image from a host directory tree. // diff --git a/tools/posix/schcom_test.sh b/tools/posix/schcom_test.sh index 7b994b1..13986f8 100644 --- a/tools/posix/schcom_test.sh +++ b/tools/posix/schcom_test.sh @@ -1,5 +1,5 @@ #!/bin/sh -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # # Run Schcom and a client inside SchOS, then check the actual pixels from the # host with QEMU's screendump. The host has no connection to the compositor, so diff --git a/tools/posix/schfs_roundtrip.sh b/tools/posix/schfs_roundtrip.sh index 4f9b706..16639a0 100644 --- a/tools/posix/schfs_roundtrip.sh +++ b/tools/posix/schfs_roundtrip.sh @@ -1,5 +1,5 @@ #!/bin/sh -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # # SchFS round-trip test: build an image from a directory tree, read it back # with a completely separate program, and diff the result against the original. diff --git a/tools/python/ldls_check.py b/tools/python/ldls_check.py index 39c3997..568affd 100644 --- a/tools/python/ldls_check.py +++ b/tools/python/ldls_check.py @@ -1,5 +1,5 @@ #!/usr/bin/env python3 -# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: GPL-2.0-or-later # # Check the LDLS loader against an object we compiled ourselves. # @@ -47,7 +47,7 @@ def main(): # straight out of .modinfo. That is the first question anyone should be # able to ask about an object before loading it. need("module refmod" in out, "the module names itself from .modinfo") - need("license Apache-2.0" in out, + need("license GPL" in out, "the declared licence is read without loading anything") # Every kind of section the loader has to place. diff --git a/tools/schfs_fsck.c b/tools/schfs_fsck.c index b6e3258..d9a4e30 100644 --- a/tools/schfs_fsck.c +++ b/tools/schfs_fsck.c @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: GPL-2.0-or-later // // schfs_fsck — inspect, verify and extract a SchFS image. //