Skip to content

addpkg(main/schilytools): 2024-03-21#27535

Closed
xingguangcuican6666 wants to merge 1 commit intotermux:masterfrom
xingguangcuican6666:schilytools
Closed

addpkg(main/schilytools): 2024-03-21#27535
xingguangcuican6666 wants to merge 1 commit intotermux:masterfrom
xingguangcuican6666:schilytools

Conversation

@xingguangcuican6666
Copy link
Copy Markdown
Contributor

@xingguangcuican6666 xingguangcuican6666 commented Dec 6, 2025

Example: burn a .iso to a real CD-RW using real bare metal Android-x86

Tip

Work around old version of KernelSU in BlissOS version 16.9.7 if necessary

to get root in fully-up-to-date Termux in BlissOS version 16.9.7, first grant Termux root permission in KernelSU app, then unset LD_PRELOAD, then launch a new bash session, then directly invoke /system/bin/su (with absolute path), then set LD_PRELOAD again

unset LD_PRELOAD
bash
/system/bin/su
export LD_PRELOAD=/data/data/com.termux/files/usr/lib/libtermux-exec-ld-preload.so
# open tray and insert CD-RW
cdrecord -eject
# erase CD-RW
cdrecord -blank=fast
# burn .iso to CD-RW
cdrecord alpine-standard-3.22.2-x86_64.iso

Closes #27346

@robertkirkman
Copy link
Copy Markdown
Member

@TomJo2000 (this is WIP and an attempt, not a final package yet. It is a fork of the current tur-on-device package)

This comment was marked as spam.

@TomJo2000
Copy link
Copy Markdown
Member

Hi thanks for the PR and project history explanation.
I don't have any objections to packaging this current iteration of schillytools.
My prior objection in #26979 (comment) was specifically about packaging a dead branch of this project.
The current Codeberg iteration of the project fulfills all applicable packaging criteria.

@xingguangcuican6666
Copy link
Copy Markdown
Contributor Author

I am currently encountering some issues. I found that some tools are dynamically generated during compilation, but this part uses a cross-compiler. They should be compiled using the host's compiler because they are only used at compile time.

@TomJo2000
Copy link
Copy Markdown
Member

Pull request overview

This PR adds the schilytools package (version 2024-03-21), a comprehensive collection of utilities from Jörg Schilling, historically known as "cdrtools" or "cdrecord". The package includes multiple subpackages for various tools including CD/DVD recording utilities, shells, archiving tools, and development utilities.

  • Addition of main schilytools package with extensive cross-compilation configuration
  • Multiple subpackages organized by functionality (cdrtools, star, bosh shell, sccs, etc.)
  • Extensive patching to adapt upstream code for Termux compatibility, including renaming conflicts and fixing Android-specific issues

Reviewed changes

Copilot reviewed 68 out of 68 changed files in this pull request and generated 8 comments.

File Description
build.sh Main build script with configuration and installation logic
*.subpackage.sh Subpackage definitions for organizing tools into logical groups
*.patch Patches for Android compatibility, renaming conflicts, and bug fixes
termux-ved-fixes.patch Fixes for the ved text editor including path and buffer size adjustments
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Please consider disabling Copilot PR reviews in your account settings.

At least for this repository.
image
https://github.com/settings/copilot/coding_agent

It adds a huge amount of noise to reviewing PRs and there is no method for us to disable it at a repo or org level.

@robertkirkman
Copy link
Copy Markdown
Member

I am currently encountering some issues. I found that some tools are dynamically generated during compilation, but this part uses a cross-compiler. They should be compiled using the host's compiler because they are only used at compile time.

Yes, this part is very difficult. In case you did not find it yet, there is official documentation of cross-compiling for Android here:

https://codeberg.org/schilytools/schilytools/src/commit/e835e64f0d84a614b3c8d619ac646060ea6922a5/README.compile#L638-L754

Unfortunately, even when I tried to follow the steps given in the documentation, I was still not able to get it to work and I didn't know what to do, but it might still be helpful for you if you haven't seen it yet.

@xingguangcuican6666 xingguangcuican6666 force-pushed the schilytools branch 2 times, most recently from 1ad5662 to f71b90c Compare December 15, 2025 00:23
@xingguangcuican6666
Copy link
Copy Markdown
Contributor Author

xingguangcuican6666 commented Dec 15, 2025

@robertkirkman I'm here to give an update on my progress. Currently, I can correctly compile smake on the host machine, but I've encountered some issues with rule files generation. I will resolve them as soon as possible, even though I've been trying for a week. If you're willing, could you help me?

Here is the logs.

Checking for working bootstrap make...
Smake release 1.7 2023/11/22 (x86_64-pc-linux-gnu)
Copyright (C) 1985, 87, 88, 91, 1995-2021 J�rg Schilling
          (C) 2022-2023                   the schilytools team
...sh conf/cc-config.sh clang cc incs/Dcc.aarch64-linux
Trying to find clang
Found clang
Making clang the default compiler in 'incs/Dcc.aarch64-linux'
	==> MAKING DIRECTORY "incs/aarch64-linux-clang/Inull"
	==> MAKING DIRECTORY "libs/aarch64-linux-clang"
	==> CONFIGURING RULES "incs/aarch64-linux-clang/rules.cnf"
creating cache ./config.cache
checking host system type... x86_64-pc-linux-gnu
checking if sh is bash... no
checking if /bin/sh is bash... no
checking whether sh -ce is broken... no
checking whether /bin/sh -ce is broken... no
checking whether /bin/bosh is a working shell... no
checking whether /opt/schily/bin/bosh is a working shell... no
checking for cc... aarch64-linux-android-clang
checking for gcc... (cached) aarch64-linux-android-clang
checking whether the C compiler (aarch64-linux-android-clang   -O  -fstack-protector-strong -Oz  -L../../libs/aarch64-linux-clang -L/data/data/com.termux/files/usr/lib -Wl,-R/data/data/com.termux/files/usr/lib -Wl,-R/data/data/com.termux/files/usr/lib) works... yes
checking whether the C compiler (aarch64-linux-android-clang   -O  -fstack-protector-strong -Oz  -L../../libs/aarch64-linux-clang -L/data/data/com.termux/files/usr/lib -Wl,-R/data/data/com.termux/files/usr/lib -Wl,-R/data/data/com.termux/files/usr/lib) is a cross-compiler... yes
checking whether we are using GNU C... yes
CONFIG_RMTHOST=host or CONFIG_RMTHOST=user@host required for remote execution
checking whether aarch64-linux-android-clang accepts -g... yes
smake: *** Code 1 (Operation not permitted) from command line for target 'incs/aarch64-linux-clang/rules.cnf'.
smake: The following command caused the error:
echo "	==> CONFIGURING RULES \"incs/aarch64-linux-clang/rules.cnf\"";  /bin/rm -f incs/aarch64-linux-clang/rules.cnf incs/aarch64-linux-clang/xconfig.h;  (cd incs/aarch64-linux-clang;  CONFIG_NOFAIL=TRUE CC="aarch64-linux-android-clang" CFLAGS="  -O  -fstack-protector-strong -Oz "  CXXFLAGS=" -Wall -Wno-unknown-pragmas  -Wshadow -Wmissing-prototypes -Wstrict-prototypes -Wno-deprecated-register -O  -fstack-protector-strong -Oz" CPPFLAGS="  -D_GNU_SOURCE  "  LDFLAGS="-L../../libs/aarch64-linux-clang -L/data/data/com.termux/files/usr/lib -Wl,-R/data/data/com.termux/files/usr/lib -Wl,-R/data/data/com.termux/files/usr/lib"  CONFIG_SHELL=/bin/sh  /bin/sh ../../autoconf/configure  );  ([ -d  ./inc ] && cd ./inc && /home/builder/.termux-build/schilytools/src/./psmake/smake || :)
smake: No such file or directory. Can not open 'incs/aarch64-linux-clang/rules.cnf'.
Error: Process completed with exit code 2.

@xingguangcuican6666 xingguangcuican6666 force-pushed the schilytools branch 5 times, most recently from d89b947 to b56530c Compare December 15, 2025 08:26
@robertkirkman
Copy link
Copy Markdown
Member

robertkirkman commented Dec 15, 2025

CONFIG_RMTHOST=host or CONFIG_RMTHOST=user@host required for remote execution

@xingguangcuican6666 yes, I can tell you something that will progress slightly farther beyond this error.

It is this:

export CONFIG_RMTHOST=host

Then, after that, the next error will be this:

sh: 2: OBJ/aarch64-linux-clang/avoffset: Exec format error

unfortunately, once you reach the error sh: 2: OBJ/aarch64-linux-clang/avoffset: Exec format error, you will have gone pretty much as far as I ever reached.

I tried many things to bypass the error sh: 2: OBJ/aarch64-linux-clang/avoffset: Exec format error, but everything I tried failed with more errors except for tur-on-device, which was the only way I was able to figure out how to bypass that error.

Good luck with it! I hope you can figure out some way.

@xingguangcuican6666
Copy link
Copy Markdown
Contributor Author

Okay, thank you very much for your help, I will continue to fix it.

@xingguangcuican6666 xingguangcuican6666 force-pushed the schilytools branch 15 times, most recently from 21316bb to 5680a69 Compare December 15, 2025 12:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Package]: mkisofs

4 participants