develop/ktcc: Post-SVN tidy #425

Merged
Burer merged 4 commits from ace-dent/kolibrios-gitea:PR-TidySVN-develop-3 into main 2026-04-19 16:41:54 +00:00
Member
  • Move source code from trunk into root directory.
  • Update build files and ASM include paths. Add SPDX license header where appropriate.
  • These changes also update the CI build files in .gitea/workflows/.
  • Note: Line endings standardised from CRLF > LF, so best to view diffs with whitespace changes hidden.

(Work towards #75, point 3)

- Move source code from `trunk` into root directory. - Update build files and ASM include paths. Add SPDX license header where appropriate. - These changes also update the CI build files in `.gitea/workflows/`. - Note: Line endings standardised from `CRLF` > `LF`, so best to view diffs with whitespace changes hidden. (Work towards [#75](https://git.kolibrios.org/KolibriOS/kolibrios/issues/75), point 3)
ace-dent added the
Kind
Build
Category/Applications
Priority
Low
labels 2026-04-16 16:28:43 +00:00
Author
Member

This PR is split (/cherry picked) from the monolithic PR #251 - for easier merging! 🤞
This part is just focused on develop/ktcc, as it affects many files.

This PR is split (/cherry picked) from the monolithic PR #251 - for easier merging! 🤞 This part is just focused on `develop/ktcc`, as it affects **many** files.
ace-dent requested review from Burer 2026-04-16 16:41:45 +00:00
ace-dent requested review from Doczom 2026-04-16 16:41:45 +00:00
ace-dent requested review from dunkaist 2026-04-16 16:41:46 +00:00
ace-dent requested review from Sweetbread 2026-04-16 16:41:46 +00:00
ace-dent added the
PR
Review required
label 2026-04-16 16:41:56 +00:00
dunkaist approved these changes 2026-04-17 00:19:01 +00:00
Owner

Files Changed: 700

O_O

> Files Changed: 700 O_O
Burer requested changes 2026-04-18 08:14:35 +00:00
Dismissed
Burer left a comment
Owner

Please address these before merge:

  • In programs/develop/ktcc/source/lib/buildtcclib1.bat, replace the hardcoded absolute path (D:\...) and the outdated ...\ktcc\libc\kos32-tcc.exe location with a portable relative path to the new compiler location (...\ktcc\bin\kos32-tcc.exe).
  • Remove trailing whitespace in programs/develop/ktcc/source/lib/buildtcclib1.bat.
  • In contrib/C_Layer/EXAMPLE/boxlib/boxlib.c, update the TCC samples comment path to the actual current location (it now points to a non-existing path).

Also, yes, 700 changed files is something new :()

Please address these before merge: - [ ] In `programs/develop/ktcc/source/lib/buildtcclib1.bat`, replace the hardcoded absolute path (`D:\...`) and the outdated `...\ktcc\libc\kos32-tcc.exe` location with a portable relative path to the new compiler location (`...\ktcc\bin\kos32-tcc.exe`). - [ ] Remove trailing whitespace in `programs/develop/ktcc/source/lib/buildtcclib1.bat`. - [x] In `contrib/C_Layer/EXAMPLE/boxlib/boxlib.c`, update the TCC samples comment path to the actual current location (it now points to a non-existing path). Also, yes, 700 changed files is something new :()
Author
Member

Thanks @Burer

Points 1 and 2 re. programs/develop/ktcc/source/lib/buildtcclib1.bat ~ I'm reluctant to touch this file. The path has long been broken (10 years!!); I'm also not sure where the binary target should be (probably programs/develop/ktcc/bin/kos32-tcc.exe?). There is no significant trailing whitespace!? It also doesn't look like a valid Windows batch script... I don't really want to start fixing things outside of the scope of this PR, especially when I don't understand them.

Point 3. Fixed.

Thanks @Burer Points 1 and 2 re. `programs/develop/ktcc/source/lib/buildtcclib1.bat` ~ I'm reluctant to touch this file. The path has long been broken ([10 years](https://git.kolibrios.org/KolibriOS/kolibrios/commits/commit/096cca20cb9fb1d37cc27f5b0dbef287b9e80a1b/programs/develop/ktcc/trunk/source/lib/buildtcclib1.bat)!!); I'm also not sure where the binary target should be (probably `programs/develop/ktcc/bin/kos32-tcc.exe`?). There is no significant trailing whitespace!? It also doesn't look like a valid Windows batch script... I don't really want to start fixing things outside of the scope of this PR, especially when I don't understand them. Point 3. Fixed.
ace-dent requested review from Burer 2026-04-18 15:17:07 +00:00
Doczom requested changes 2026-04-18 17:13:14 +00:00
Dismissed
Doczom left a comment
Owner

According to the changes, the programs/develop/ktcc/source/Tupfile.lua file has been moved unchanged. But the file contains the relative path "../../../.."

According to the changes, the programs/develop/ktcc/source/Tupfile.lua file has been moved unchanged. But the file contains the relative path "../../../.."
Owner

the same problem with programs/develop/ktcc/libc.obj/source/crt/crt0.asm and the rest of the files on fasm

the same problem with programs/develop/ktcc/libc.obj/source/crt/crt0.asm and the rest of the files on fasm
Author
Member

Thanks @Doczom - will investigate.

Thanks @Doczom - will investigate.
ace-dent force-pushed PR-TidySVN-develop-3 from 04b128df22 to 78348d502a 2026-04-18 17:58:47 +00:00 Compare
Author
Member

@Doczom - changing the tupfile broke the build... so I think the path was correct!? 🤷🏼‍♂️
I have fixed all the .asm files I could find in ktcc with includes (commit). Please check carefully!! 🙏

@Doczom - changing the `tupfile` broke the [build](https://git.kolibrios.org/KolibriOS/kolibrios/actions/runs/1077/jobs/1)... so I think the path was correct!? 🤷🏼‍♂️ I have fixed all the `.asm` files I could find in ktcc with includes ([commit](https://git.kolibrios.org/KolibriOS/kolibrios/commit/78348d502af3e8fd4d9d2da9d7eb06eecc312299)). Please check carefully!! 🙏
ace-dent requested review from Doczom 2026-04-18 18:02:34 +00:00
Doczom requested changes 2026-04-19 07:05:46 +00:00
Dismissed
Doczom left a comment
Owner

not fixed
SDK_DIR:= $(abspath ../../../../../contrib/sdk)
in programs/develop/ktcc/source/Makefile.kos32

not fixed `SDK_DIR:= $(abspath ../../../../../contrib/sdk)` in programs/develop/ktcc/source/Makefile.kos32
ace-dent force-pushed PR-TidySVN-develop-3 from 78348d502a to 13af727fca 2026-04-19 11:29:15 +00:00 Compare
ace-dent force-pushed PR-TidySVN-develop-3 from 13af727fca to c8002f9b9c 2026-04-19 11:41:22 +00:00 Compare
Author
Member

Thanks @Doczom. Fixed.
I also scanned the ktcc directory with git grep -F '../../..' and found one more; I'm confident everything is now correct. 🤞

Thanks @Doczom. Fixed. I also scanned the `ktcc` directory with `git grep -F '../../..'` and found one more; I'm confident everything is now correct. 🤞
ace-dent requested review from Doczom 2026-04-19 11:44:52 +00:00
Doczom approved these changes 2026-04-19 12:08:45 +00:00
Dismissed
Doczom requested review from dunkaist 2026-04-19 12:09:00 +00:00
Doczom added 3 commits 2026-04-19 12:11:54 +00:00
- Move source code from `trunk` into program root directory.
- Update build files and include paths.
- These changes also update the CI build files in `.gitea/workflows/`.
- Note: Line endings standardised from `CRLF` > `LF`, so best to view diffs with whitespace changes hidden.
- Fix path to example code.
develop/ktcc: Post-SVN tidy
Build system / Check kernel codestyle (pull_request) Successful in 1m18s
Build system / Build (pull_request) Successful in 10m54s
dd920b036d
- Fix relative paths for asm includes and build files.
Doczom force-pushed PR-TidySVN-develop-3 from c8002f9b9c to dd920b036d 2026-04-19 12:11:54 +00:00 Compare
Author
Member

@Doczom & developer team - Please squash the commits when merging, using the PR's first comment as the commit message (default).

@Doczom & developer team - Please *squash* the commits when merging, using the PR's first comment as the commit message (default).
Doczom approved these changes 2026-04-19 12:23:58 +00:00
Burer requested changes 2026-04-19 13:47:29 +00:00
Dismissed
Burer left a comment
Owner

programs/other/tte/Makefile has a broken include path in the TCC target after the ktcc migration.

  • Changed to: -I ../../develop/ktcc/libc/include (in 425.diff)
  • But this PR migrates headers under ktcc/libc.obj/include, not ktcc/libc/include.

So make TCC for tte will fail to find libc headers.
Expected path: -I ../../develop/ktcc/libc.obj/include.

`programs/other/tte/Makefile` has a broken include path in the `TCC` target after the ktcc migration. - Changed to: `-I ../../develop/ktcc/libc/include` (in `425.diff`) - But this PR migrates headers under `ktcc/libc.obj/include`, not `ktcc/libc/include`. So `make TCC` for `tte` will fail to find libc headers. Expected path: `-I ../../develop/ktcc/libc.obj/include`.
Owner

programs/other/tte/Makefile has a broken include path in the TCC target after the ktcc migration.

  • Changed to: -I ../../develop/ktcc/libc/include (in 425.diff)
  • But this PR migrates headers under ktcc/libc.obj/include, not ktcc/libc/include.

So make TCC for tte will fail to find libc headers.
Expected path: -I ../../develop/ktcc/libc.obj/include.

In my opinion, this does not apply to this PR

> `programs/other/tte/Makefile` has a broken include path in the `TCC` target after the ktcc migration. > > - Changed to: `-I ../../develop/ktcc/libc/include` (in `425.diff`) > - But this PR migrates headers under `ktcc/libc.obj/include`, not `ktcc/libc/include`. > > So `make TCC` for `tte` will fail to find libc headers. > Expected path: `-I ../../develop/ktcc/libc.obj/include`. In my opinion, this does not apply to this PR
Author
Member

@Burer - I think the path in programs/other/tte/Makefile was broken ~4yrs ago when turbocat deleted some files but did not update the 6yr old makefile. It does seem that programs/develop/ktcc/libc.obj/include has most of those original files, so is a reasonable match.

@Burer - I think the path in `programs/other/tte/Makefile` was broken ~4yrs ago when [turbocat](https://git.kolibrios.org/KolibriOS/kolibrios/commit/92e48c928c5185df055e7c2d6b8ed1d276714533) deleted some files but did not update the 6yr old [makefile](https://git.kolibrios.org/KolibriOS/kolibrios/commits/branch/main/programs/other/tte/Makefile). It does seem that `programs/develop/ktcc/libc.obj/include` has *most* of those original files, so is a reasonable match.
Burer added 1 commit 2026-04-19 16:25:01 +00:00
develop/ktcc: fix old broken path for tte makefile
Build system / Check kernel codestyle (pull_request) Successful in 1m14s
Build system / Build (pull_request) Successful in 10m43s
1194fc9502
Burer approved these changes 2026-04-19 16:39:04 +00:00
ace-dent removed the
PR
Review required
label 2026-04-19 16:39:29 +00:00
ace-dent removed review request for Sweetbread 2026-04-19 16:39:46 +00:00
Burer merged commit a4f3f3545a into main 2026-04-19 16:41:54 +00:00
Burer deleted branch PR-TidySVN-develop-3 2026-04-19 16:41:56 +00:00
ace-dent removed review request for dunkaist 2026-04-19 17:03:11 +00:00
Sign in to join this conversation.
4 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: KolibriOS/kolibrios#425