Tiny Core Linux
Tiny Core Base => CorePlus => Topic started by: notferrari on September 20, 2023, 12:27:06 PM
-
I've installed (via "tc-install") coreplus on a pretty old machine (x86 single-core, around 500MHz processor, about 512MB RAM), and managed to boot correctly and use it from ethernet cable.
I have a TP-Link wifi adapter (RTL8188EUS on "lsusb") that i'd like to use with it, but it looks like tc isn't identifying it correctly.
"sudo wifi.sh" does not identify it as a wifi interface, and "dmesg" only shows lines for connecting the device.
I've also tried to install some packages (namely "firmware-rtlwifi", "firmware-wlan" and "wireless-6.1.2-tinycore"), but also no success.
Is there anything I could do to make it work?
-
That looks like one of the staging drivers, which we do not ship. You would need to compile either the staging driver, or their third-party driver.
-
Are there any instructions on how should I do this?
Also, I've found this: https://github.com/lwfinger/rtl8188eu (https://github.com/lwfinger/rtl8188eu).
Is it just enough to follow repo's instructions? Should I need to do extra steps because of TinyCore architecture?
-
Are there any instructions on how should I do this?
...
Is it just enough to follow repo's instructions? Should I need to do extra steps because of TinyCore architecture?
The x86_64 repo has 88x2bu.tcz and 8188eu.tcz extensions. You are on x86 so those extensions are not going to help you, but you can consult the notes on how those extensions were built. Process to build 8188eu on x86 is probably identical or nearly so.
http://repo.tinycorelinux.net/14.x/x86_64/tcz/src/88x2bu/compilation
http://repo.tinycorelinux.net/14.x/x86_64/tcz/src/rtl8188eu/build-8188eu.sh
-
Hi
TP-Link wifi adapter (RTL8188EUS
Lets confirm we have a match for your adapter to my TC64 vendor and product ids
1) download and load usb-utils then post the output for your adapter for command
lsusb
NOT OP mine is Bus 001 Device 005: ID 2357:010c TP-Link TL-WN722N v2/v3 [Realtek RTL8188EUS]
TC64 vendor and product ids are little hard to read but they are
modinfo 8188eu | grep usb:
alias: usb:v0BDApFFEFd*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v0B05p18F0d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2C4Ep0102d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v0BDAp8179d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2357p0111d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2357p010Cd*dc*dsc*dp*ic*isc*ip*in* # this is my slow class N device
alias: usb:v056Ep4008d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2001p331Bd*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2001p3311d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2001p3310d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v2001p330Fd*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v0DF6p0076d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v7392pB811d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v07B8p8179d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v0BDAp0179d*dc*dsc*dp*ic*isc*ip*in*
alias: usb:v0BDAp8179d*dc*dsc*dp*ic*isc*ip*in*;;
I have been busy doing stuff on RPi and had no plans to build this for TC32. I have no problem if you can build it if you have a match.
If you prefer I build it, it may take me some time but if built I can send a pm for you to get the TCE early as there can be a few weeks delay in submission being carefully checked for TC compliance etc.
class N speeds are slow.....have you considered buying an ac speed dongle?
Mine is single antenna in theory max 150 megabits per second
Some members here may be able to give you their suggestions
-
there is at least one error in my script
change this line chmod -R 755 $P/usr/local/tce.installed to
chmod -R 775 $P/usr/local/tce.installed
submitqc --libs should have fixed that with luck
-
The x86_64 repo has 88x2bu.tcz and 8188eu.tcz extensions. You are on x86 so those extensions are not going to help you, but you can consult the notes on how those extensions were built. Process to build 8188eu on x86 is probably identical or nearly so.
http://repo.tinycorelinux.net/14.x/x86_64/tcz/src/88x2bu/compilation
http://repo.tinycorelinux.net/14.x/x86_64/tcz/src/rtl8188eu/build-8188eu.sh
I've tried to use this script with some changes (inside attachment), and it looks like it almost worked. It tries to find "/lib/modules/6.1.2-tinycore/build", which doesn't exist. It also fails to apply patch (I tried to apply anyways and no difference on this part). The full output is also inside attachment.
Looking trough tips inside the script and the 88x2bu link, it looks like a step is missing, and I really don't understand what do I need to do with that part:
tce-load -wi compiletc perl5 bash ncursesw-dev bc glibc_apps elfutils-dev gettext
http://repo.tinycorelinux.net/14.x/x86_64/release/src/kernel/linux-6.1.2-patched.txz
http://repo.tinycorelinux.net/14.x/x86_64/release/src/kernel/config-6.1.2-tinycore64
$ cd linux-6.1.2
$ make mrproper
$ cp ../config-6.1.2-tinycore64 .config
$ make oldconfig
$ make prepare
$ make modules_prepare
# ln -s $HOME/Downloads/linux-6.1.2 /lib/modules/6.1.2-tinycore64/build
The "tce-load" part is straightforward. But the links and the "cd linux-6.1.2" part is weird to me. Which path should this folder be?
Lets confirm we have a match for your adapter to my TC64 vendor and product ids
1) download and load usb-utils then post the output for your adapter for command
lsusb
Also added to attachment.
class N speeds are slow.....have you considered buying an ac speed dongle?
Mine is single antenna in theory max 150 megabits per second
Some members here may be able to give you their suggestions
Just like the PC, it's a leftover that I'd like to use on some simple projects.
there is at least one error in my script
change this line chmod -R 755 $P/usr/local/tce.installed to
chmod -R 775 $P/usr/local/tce.installed
submitqc --libs should have fixed that with luck
Tried the change, no difference.
-
Hi notferrari
... tce-load -wi compiletc perl5 bash ncursesw-dev bc glibc_apps elfutils-dev gettext
http://repo.tinycorelinux.net/14.x/x86_64/release/src/kernel/linux-6.1.2-patched.txz
http://repo.tinycorelinux.net/14.x/x86_64/release/src/kernel/config-6.1.2-tinycore64
$ cd linux-6.1.2
$ make mrproper
$ cp ../config-6.1.2-tinycore64 .config
$ make oldconfig
$ make prepare
$ make modules_prepare
# ln -s $HOME/Downloads/linux-6.1.2 /lib/modules/6.1.2-tinycore64/build
...
I see a few things that might be causing problems. One of them
is that the step to untar the source package is implied instead
of being stated.
See if this version gets you any further:
tce-load -wi compiletc perl5 bash ncursesw-dev bc glibc_apps elfutils-dev gettext
# Fetch source and configuration files.
wget http://repo.tinycorelinux.net/14.x/x86/release/src/kernel/linux-6.1.2-patched.txz
wget http://repo.tinycorelinux.net/14.x/x86/release/src/kernel/config-6.1.2-tinycore
$ tar xf linux-6.1.2-patched.txz
$ cd linux-6.1.2
$ make mrproper
$ cp ../config-6.1.2-tinycore .config
$ make oldconfig
$ make prepare
$ make modules_prepare
# ln -s $HOME/Downloads/linux-6.1.2 /lib/modules/6.1.2-tinycore/build
-
tar xf linux-6.1.2-patched.txz
It gives me the error:
tar: can't create symlink 'linux-6.1.2/scripts/dummy-tools/objcopy' to 'ld': Operation not permitted
even if I run as root.
Apart from that, all "make" commands gives "nothing to do" result.
-
your lsusb confirms that you could use my TC64 converted to TC32 except I do not detail the kernel prep.
see attachment for modified 8188eu for TC32 Good Luck
changes are...flags.....git source is already patched.....dep file had a duplication when you load wifi.tcz
2) The kernel prep is not working for me....I have some memory/RAM issues
3) In addition to what you have already downloaded and unpacked
suggest you include this for download and unpack
wget http://tinycorelinux.net/14.x/x86/release/src/kernel/Module.symvers-6.1.2-tinycore.gz
gunzip Module.symvers-6.1.2-tinycore.gz
Please keep copies of all downloads or better still keep copies somewhere of your unpacks
more suggestions. I do all my downloads to /tmp
Use root powers to create a dir /usr/src
sudo mkdir -p /usr/src
Use root powers to copy your unpacked kernel source into that new dir
But I use sudo mc to do the copy but you "need"
/usr/src/linux-6.1.2
Then
ln -s /usr/src/linux-6.1.2 /lib/modules/6.1.2-tinycore/build
SRC=/usr/src/linux-6.1.2
cd $SRC
make mrproper # seconds
mv /tmp/config-6.1.2-tinycore .config
make oldconfig # seconds
make prepare # about 10 seconds
make modules_prepare # seconds
make modules
make modules borks for me
I am aware I am confusing you with your use of Downloads vs my use of /usr/src etc
-
The symlink error sounds like you're operating on fat32. A linux fs is necessary.
-
correction to above for me....
my steps should have included the symversions so my end bits become
make modules_prepare # seconds
mv /tmp/Module.symvers-6.1.2-tinycore $SRC
make modules
-
I am going to have a re-look on TC64 how I built it in terms of kernel prep.
On TC32 I can not get past make modules or make modules install bit
on TC32 skipping that and only going to make_modules prep then for 8188eu
make all
SNIP
MODPOST /tmp/rtl8188eu/Module.symvers
WARNING: Module.symvers is missing.
Modules may not have dependencies or modversions.
You may get many unresolved symbol warnings.
SNIP
WARNING: modpost: suppressed 191 unresolved symbol warnings because there were too many)
# lets just see about direct injection
make install
install -p -m 644 8188eu.ko /lib/modules/6.1.2-tinycore/kernel/drivers/net/wireless/
/sbin/depmod -a 6.1.2-tinycore
# Looks good eh? but
modprobe 8188eu
modprobe: can't load module 8188eu (kernel/drivers/net/wireless/8188eu.ko): unknown symbol in module, or unknown parameter
I think I may have no choice but research cross compile using a 64 bit kernel
Your thoughts?
-
I have always needed System.map as well, and you need to copy them before you run. modules_prepare.
This is from once of my scripts for out of tree drivers.
cd $LINUX_SRC_DIR
echo "[ INFO ] Cleaning linux source tree"
make -s mrproper
echo "[ INFO ] Copying configs and symbols"
xz -d -kc /tmp/config.xz > .config
xz -d -kc /tmp/System.map.xz > System.map
xz -d -kc /tmp/Module.symvers.xz > Module.symvers
sudo rm /lib/modules/${KERNELVER}/build
[ ! -d /lib/modules/${KERNELVER} ] && sudo mkdir -p /lib/modules/${KERNELVER}
sudo ln -sv $LINUX_SRC_DIR /lib/modules/${KERNELVER}/build
echo "[ INFO ] Preparing Kernel"
make -s -j4 KERNELRELEASE=$KERNELVER oldconfig
make -s -j4 KERNELRELEASE=$KERNELVER scripts
make -s -j4 KERNELRELEASE=$KERNELVER modules_prepare
-
Just some thoughts from me.
Could it be useful to use qemu-system-i386 -enable-kvm to run tc32 into tc64 and compile instead of cross-compile, because it's very easy to get the host within the target, if not using like chroot.
-
Hi patrikg
I will try your suggestion after Paul_123.
I have used virtualbox in the past but happy to try qemu.
Maybe not tomorrow but will update by Monday with luck
The other thing I just spotted is the realtek command is looking for Module.symvers (I think in its unpack dir)
Surely it can 't be as simple as copying our TC and renaming it?
If not then I will rename the Module.symvers in my linux src and see if that works.
thanks
-
The symlink error sounds like you're operating on fat32. A linux fs is necessary.
Right, I tried again, this time copying the contents to ~ folder.
Now it gives me the error "tar: short read" when trying to unpack "linux-6.1.2-patched.txz".
-
Hi notferrari
I believe short read means part of the file wasn't downloaded.
The file should have a size of 129437112 bytes.
Compare that to the size returned by:
ls -l linux-6.1.2-patched.txz
If the size does not match, delete linux-6.1.2-patched.txz and
run this command again:
wget http://repo.tinycorelinux.net/14.x/x86/release/src/kernel/linux-6.1.2-patched.txz
-
Hi notferrari
I believe short read means part of the file wasn't downloaded.
The file should have a size of 129437112 bytes.
Compare that to the size returned by:
ls -l linux-6.1.2-patched.txz
If the size does not match, delete linux-6.1.2-patched.txz and
run this command again:
wget http://repo.tinycorelinux.net/14.x/x86/release/src/kernel/linux-6.1.2-patched.txz
The size matches. I've also downloaded it several times, always the same error.
MD5 is ffc4d679faad85405a1032e084aad16d
-
Did you run out of space?
-
Did you run out of space?
I think this might be the issue, didn't think of that... :-\
home folder stays in RAM, right?
If that's the case, it's probably that.
I'll format a pendrive with ext4 and try again.
-
Hi
my 2 cents worth. Fixing partition file type to ext4 is good but does nor resolve an issue where you are loading into RAM drive very large files etc
so please make a very large swap partition
As you have not mentioned the size of pendrive.....I will let others decide whats best there
but.....if space on pendrive is still an issue....consider using firefox or whatever to change your downloads from
$HOME/Downloads to another usb stick
In firefox -> settings (General) -> Downloads -> click on browse and choose a new usb stick etc
2) and I suggest even with above.....consider booting with a boot code home=sdb1 or whereever your home dir is.
There are advantages and disadvantages of this....but it should free up some RAM
You should make a backup of your home independently on another stick first for any previous downloads you need to keep
or files you need to keep
That is because when you reboot with that bootcode you lose some home stuff and also you need to remove home from backup
such that my /opt/.filetool.sh has only entries
opt
etc/fstab
Then over reboot....you add back your missing files from your other usb stick
-
Hi
At the risk of appearing to blog, when I am actually trying to resolve my 32 bit module build failure.....I have just looked at my TC64 kernel prep and re-did my TC64 kernel module. There are some things that might be useful for members and OP, depending on his level of knowledge, to know
1) I do not have a System.map anywhere, nor can I see one in an unpack of the 32 bit ISO
2) The realtek module compilation, if successful creates an empty file called Module.symvers such that
ls -al Module.symvers
-rw-r--r-- 1 root root 0 Sep 23 06:24 Module.symvers
and if I do a make clean....this file is deleted. I admit I should have read my Makefile before posting about trying renames and other gargage,
sorry about that.
Anyhow on TC64 the module build reports
make all
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/6.1.2-tinycore64/build M=/tmp/rtl8188eu modules
SNIP
MODPOST /tmp/rtl8188eu/Module.symvers
# TEST direct injection
make install
install -p -m 644 8188eu.ko /lib/modules/6.1.2-tinycore64/kernel/drivers/net/wireless/
/sbin/depmod -a 6.1.2-tinycore64
# NOTE no errors for bad symbols so it looks good to me
I might try to use a changed ARCH & cross compile on TC64 but with an unpack of 32 bit K source and modules in ram drive,
before I try qemu
and proof of net on TC64
inxi -Nxxx
Network:
Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
vendor: Micro-Star MSI driver: r8169 v: kernel pcie: speed: 2.5 GT/s
lanes: 1 port: f000 bus-ID: 22:00.0 chip-ID: 10ec:8168 class-ID: 0200
Device-2: Realtek 802.11n NIC driver: rtl8188eu type: USB rev: 2.0
speed: 480 Mb/s lanes: 1 bus-ID: 1-3:5 chip-ID: 2357:010c class-ID: 0000
serial: 00E04C0001
tc@box:~$ ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:62 errors:0 dropped:0 overruns:0 frame:0
TX packets:62 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:5212 (5.0 KiB) TX bytes:5212 (5.0 KiB)
wlan0 Link encap:Ethernet HWaddr 50:3E:AA:42:94:1D
inet addr:192.168.1.11 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:492 errors:0 dropped:4266 overruns:0 frame:0
TX packets:241 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:258891 (252.8 KiB) TX bytes:29268 (28.5 KiB)
If I was not on a tower, I would be tempted to suggest to OP to blacklist his ethernet module, mine shows up as r8169
-
hI
My first attempt X compile has failed. Plus not sure I am doing it right but I modified or looked at these lines in the Makefile
# SUBARCH := $(shell uname -m | sed -e s/i.86/i386/) -> x86
# ARCH ?= $(SUBARCH).....leave alone
# line 1355 CROSS_COMPILE ?= NOW left alone y fails
# KVER ?= $(shell uname -r) -> 6.1.2-tinycore
# KSRC := /lib/modules/$(KVER)/build....leave alone
# MODDESTDIR := /lib/modules/$(KVER)/kernel/drivers/net/wireless/.....leave alone
I linked the 64 bit kernel source which IMHO is the same as a 32 bit source to /lib/modules/6.1.2-tinycore/build
but cheated by copying my 64 bit modules....tricked because Module.symvers as discussed was a zero byte file in module source.
such that
file 8188eu.ko
8188eu.ko: ELF 64-bit LSB relocatable
Which is not was I expecting. I had error trying to put a y against X compile, I did not keep the error but claimed something like
it was looking for ygcc
I am vaguely aware that there might be a cross compiler setup that I have failed to setup. Need rest now. Unlikely to succeed in the next few days unless I can setup qemu.
thanks for reading
-
Hi patrikg
Due to dumb luck I appear to have got some stuff now downloaded with a persistent tcedir in qemu.
altho its nobodies fault....I actually prefer not to use openssh to transfer files, altho its a bit easier with lxterminal
my current boot up for those interested is, after initial setup but avoiding bridge network for now
tce-load -i qemu bridge-utils # I know I can leave out bridge
sudo modprobe kvm-amd # as my host is AMD
qemu-system-i386 -enable-kvm -hda vdisk.img -m 4G
My guest, I can not find spice on TC32, which I was hoping to use with copy and paste between machines.
If I can not build it.....I might have to setup openssh....I am very reluctant to bridge. I attempted it once and lost the net ;D
Since you were kind enough to recommend qemu.....before I dig too many holes,
let me know your thoughts please?
Thanks....and sorry if I am hijacking OP thread....but I think the goal for me to build 32 bit module is looking closer
-
If you have trouble with openssh to transfer files, you can test to use some another trix to transfer files between the host and the guest.
I think it's not to difficult to use the program that i have used many times, to transfer files between computers from Linux to Windows and Linux to Linux.
And even Windows to Windows, i used it a lot, just one exe file, witch the zip file contain, already compiled, and the best part of it it's like server client.
You choose what direction you prefer. And not using the windows smb stuff, thank god.
It uses only tcp/ip.
It easy to compile in Linux environment just type in make. It's called lanfile, and was built by some guy how like to cheat in games :), and of course lot's of another utility's.
Here's the link to his site:
http://aluigi.altervista.org/mytoolz.htm#both
And one of them is lanfile.
[EDIT]: Removed link due to forum policy violation. lanfile can be
downloaded from the above link. Rich
-
And if you just use dhcp the first ip that qemu will lease is 10.0.2.15 to the guest.
The host ip is 10.0.2.2, so if you setup lanfile in server mode in host, first with.
Host side:(server)
lanfile 0
Guest side:(client)
lanfile 10.0.2.2 /home/tc/files/*
And for more things you can do is that you can do it interactiv mode if you forget the command line args.
Just launch the lanfile -i
And if that is not enough, you can just type in lanfile to get more info about the command line arguments, and even if that not enough you can use -e for more practical examples of how to use this tool.
-
@aus9 About your "I think I may have no choice but research cross compile using a 64 bit kernel. Your thoughts?"
IMHO best practice is to AVOID cross-compile, as a principle, with gcc. Aboriginal linux (dead) and now toybox project, try to by-pass/isolate the gcc compiler stupidity/stubbornness for cross-compilation.
You may ponder and estimate the value of your time [in $USD, whatever currency] versus buying a more performant machine [to run linux/host on 64 bits!].
Like: How many work-hours you would donate to an capitalist exploiter/employer [to gain the money for PC] versus the hours you gain in compile time [and you will compile many times on this new machine].
PS: money is infinite and replaceable, your time not so much. YMMV.
-
@nick65go
Hihihihi.. have you seen Rob Landley's talk about not to cross compile :).
https://www.youtube.com/watch?v=Sk9TatW9ino (https://www.youtube.com/watch?v=Sk9TatW9ino)
Here one more to laughing about.
https://www.youtube.com/watch?v=MkJkyMuBm3g (https://www.youtube.com/watch?v=MkJkyMuBm3g)
-
@patrikg: Yes, I systematically read Rob Landley's blog [chasing for his rant about "guillotine the billionaires", his struggle with GNU standards, animosity with upper kernel management, a lot of fun]; and I check for toybox (previously followed his Aboriginal linux). I basically "dislike" small dependencies dragging-in huge dependencies.
-
Sorry moderators, GOT<-----Get Of Topic
He is very funny to listen to.
His rant about the licenses is also so funny.
He is also very active in toybox, that being installed in android.
https://github.com/landley/toybox (https://github.com/landley/toybox)<----Last edit one week ago.
I think there are 4 programs that are installed some way everywhere.
In lots of devices.
1. Linux Kernel.
2. SQLite.
3. Curl. <---- like it a lot because the main developer is Swedish like me.. :)
4. Busybox/Toybox.
-
Hi patrikg
I'm sorry but I had to modify your reply #25. One of the links
was removed and a note was added about lanfile.
The Forum Rules and Guidelines state:
2. No attachments/links of binary extensions
Found here:
http://forum.tinycorelinux.net/index.php/topic,7738.0.html
You are not allowed to post binary attachments, or direct links to external binaries.
You may post a link that leads to an external site, where someone can then choose to download something.
-
@Rich
Yes, you are absolutely correct in removing the link, I am the one
who should be sorry for including the link to the file.
Yes, rules are meant to be followed.
Thank you for edit the post.
-
Hihihihi.. have you seen Rob Landley's talk about not to cross compile :).
https://www.youtube.com/watch?v=Sk9TatW9ino (https://www.youtube.com/watch?v=Sk9TatW9ino)
Thanks for the link, but it is almost 2 hours long ( I ask for the spoiler - is it just for fun (I have another fun sources) or he tells something interesting about for example kick-starting the new platform without writing the cross-compiler? Or the point is not to use gcc as the cross-compiler?
Thanks in advance!
-
Hi @jazzbiker
Spoiler, he just talks about he's own stuff like the old aboriginal linux and gcc and toybox.
The links are little old, but i have saved them because i like to make make a small Linux that fit on floppy. Just with lilo kernel busybox.
Don't know how the feature about the compiler hell, with all platforms/cpu.
But i see some light in the tunnel, with clang and llvm.
So you make one more layer of obstruction.
So you can make the machine language assembly specific for each cpu separate.
And even with new new language that can compile c and c++ to different targets without compile the compiler. I am talking about ZIG. Don't know if this compiler can compile with diffrent width.(32/64), haven't tested that yet.
-
@jazzbiker: About your "he tells something interesting about for example kick-starting the new platform without writing the cross-compiler? Or the point is not to use gcc as the cross-compiler?"
Rob Landley is the pioneer of tempfs (init in RAM) and busybox. He hit and solved many corner-cases (in cross compiling) in reducing the "build from itself from scratch" of linux, with minimum original tools (kernel, shell, libc, compiler-tools).
He actually provides a mini/trimmed-kernel and a shell (toybox, static compiled), plus the static-compiled GCC, FOR EVERY architecture you want (supported by qemu simulator). It is READY to use it.
So YOU can compile everything you want. ex: using a x86-64 OS host, to compile for an ARM guest, etc.
He (already) compiled (the a mini-host OS, smaller than TC) so that you do NOT need to cross-compile :)
http://landley.net/toybox/downloads/binaries/toolchains/latest/ (http://landley.net/toybox/downloads/binaries/toolchains/latest/)
Basically you start qemu and load the desired HOST OS in qemu as the SAME architecture you want to compile for. ex: on TC14_64 host you run qemu with "OS" of 32 bits to compile for 32 bits; you can ever compile, inside that qmeu, a NEW kernel version, a new shell (busybox), a new licb (musl), because you natively compile, in an isolated "host".
-
Hi notferrari
I am going to have the spit the dummy on further attempts to build this 32 bit kernel in qemu.
I am getting each time errors for module symbols such that
[code]make all
# gives errors for unknown symbols
# but still makes the module
file 8188eu.ko
8188eu.ko: ELF 32-bit LSB relocatable, Intel 80386, version 1 (SYSV), BuildID[sha1]=37af6fa1c74e6a0cf8db905a071e2807b1a49979, not stripped
mkdir -p /lib/modules/6.1.2-tinycore/kernel/drivers/net/wireless
root@box:/tmp/rtl8188eu# make install
install -p -m 644 8188eu.ko /lib/modules/6.1.2-tinycore/kernel/drivers/net/wireless/
/sbin/depmod -a 6.1.2-tinycore
root@box:/tmp/rtl8188eu# modprobe 8188eu
modprobe: can't load module 8188eu (kernel/drivers/net/wireless/8188eu.ko): unknown symbol in module, or unknown parameter
#######
go into /usr/src/linux*
make modules# takes hours and I bork it at this point
# MODPOST modules-only.symvers
WARNING: vmlinux.o is missing.
Modules may not have dependencies or modversions.
You may get many unresolved symbol warnings.
WARNING: modpost: "device_destroy" [arch/x86/kernel/msr.ko] undefined!
SNIP
WARNING: modpost: suppressed 94945 unresolved symbol warnings because there were too many)
If other people think they can do better......let them help, I am giving up.
If no-one will help you, and I am assuming you can not run a 64 bit kernel
consider buying a better dongle, or a long ethernet cable
sorry to have wasted everyone's time. And yes time is valuable to me which is why I am spitting the dummy
-
Hi patrikg! Thanks for the input.
... i like to make make a small Linux that fit on floppy. Just with lilo kernel busybox.
Sounds too sweet to be possible :-) Still nice as the direction to move. But who knows what may happen? Linux is not the only kernel on our planet. And, maybe some new platforms will appear.
But i see some light in the tunnel, with clang and llvm.
In which way llvm is better than gcc? Both use some internal representation language, the difference is that gcc don't expose it. Both became monsters.
And even with new new language that can compile c and c++ to different targets without compile the compiler. I am talking about ZIG. Don't know if this compiler can compile with diffrent width.(32/64), haven't tested that yet.
c++ demands huge compiler by itself. And appetite grows and doesn't tends to stop. I see the light on the asm + C + Lua way.
Regards!
-
@nick65go, thanks for an abstract!
-
...
spitting the dummy
https://en.wiktionary.org/wiki/spit_the_dummy
learned a new potential jeopardy question.
-
@patrikg: about " i like to make make a small Linux that fit on floppy".
IMHO I think there is no USEFUL "linux" on a floppy (max. 1.2 -1.4MB), smaller than:
https://en.wikipedia.org/wiki/KolibriOS (https://en.wikipedia.org/wiki/KolibriOS)
https://en.wikipedia.org/wiki/Tomsrtbt (https://en.wikipedia.org/wiki/Tomsrtbt)
I mean to have a kernel + a shell + few utilities + (eventually) a GUI.
FYI: Kolibri-OS has one GUI, because was written in FASM (Fast ASM, machine code).
ps: KolibriOS is NOT Russian OS
https://en.wikipedia.org/wiki/Talk:KolibriOS
The smaller it gets, then the less useful it becomes, we go in micro-controllers etc. (no human interface, just signals).
-
Yes I know that, but i think that cheating.
I have build just with the current kernel and current busybox and booting that with old lilo that not have lot of tons of that i don't need, like systemdboot and grub or syslinux.
Menuet and Kolibri, i think it's little easier to use fasm and it's inbuilt preprocess macro language, then nasm gas or another assembler.
I think this two OS is not very easy to accomplish.
I don't use the floppy at all, i doing it because, i learning more and more, what's behind some hidden curtains. And in this summer i take the LFS for a challenge, and getting it running in a vm in libvirt. Just for fun and learning.
Lua, why not python :) ??
For our children to not get tired to type in some characters and not getting some thing back(output)
Every language have it's own potential to shine.
It's not the program language that desire what it's want to be built.
Right now humans is pressing the keys.
Don't know how the future will be with the AI.
-
Yes I know that, but i think that [is] cheating.
It says “all is fair in love and war.”.. and in linux! as long as the target is achieved in the affordable time frame. Time is the most scarce resource. So time has the maximum exchange value (is priceless). Why to invent the wheel again and again; maybe is better to "build"/cheat walking on the path the pioneers/experts already tried (K.I.S.S.).
-
Hi notferrari
I have picked up my dummy....kernel module is built on qemu, tested by direct injection on TC32, package not yet built as I was not sure if everything would work. IT DOES proof
tc@box:~$ inxi -Nxxx
Network:
Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
vendor: Micro-Star MSI driver: r8169 v: kernel pcie: speed: 2.5 GT/s
lanes: 1 port: f000 bus-ID: 22:00.0 chip-ID: 10ec:8168 class-ID: 0200
Device-2: Realtek 802.11n NIC driver: rtl8188eu type: USB rev: 2.0
speed: 480 Mb/s lanes: 1 bus-ID: 1-3:2 chip-ID: 2357:010c class-ID: 0000
serial: 00E04C0001
tc@box:~$ ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:2 errors:0 dropped:0 overruns:0 frame:0
TX packets:2 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:100 (100.0 B) TX bytes:100 (100.0 B)
wlan0 Link encap:Ethernet HWaddr 50:3E:AA:42:94:1D
inet addr:192.168.1.11 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:229 errors:0 dropped:4 overruns:0 frame:0
TX packets:182 errors:0 dropped:4 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:157644 (153.9 KiB) TX bytes:27738 (27.0 KiB)
-
The reason why I was failing in the past.....grrr....was I have only ever built one kernel module on TC
The error I was getting was unknown symbols in module.
This tricked me into thinking my kernel prep was somehow wrong. It was not.
The trick on TC32, which I did not do on TC64 was to load the run dependency module for 8188eu
Then build the module
modinfo 8188eu | grep dep
depends: cfg80211
I hope to build the package later today, test it and will give you a pm on how to get it early.
-
oops, I forgot Juanito does not like the name 8188eu which is the actual kernel module name.
I will call the TCE rtl8188eu.
I think I will attempt to add more modules in it, with appropriate attritubution so members do not have a dep file,
but choose wifi or some other wireless TCEs
thanks for reading
-
@nick65go
Thanks for correct me with my spelling :)
I am not the best English writer, but better in talking it.
I am so stubborn that time is not a factor. :)
I don't give up in the first place, if I meet resistance, I put the project down for a while, to pick it up again later. I have to take a little break now and then, to let my thoughts go in other directions.
@aus9
I am happy for you that you also stubborn and don't let the problem not be fighted. And meanwhile you learning things you have never know, like using qemu in some problems/project, if you went that route.
-
Hi patrikg
sorry if I did not make it obvious before, will fix in build script but post 36 mentions qemu was where I attempted to modprobe etc
Yes I used your qemu method and it works. I just did not want to package until I was on actual (real hardware not emulated) to package.
So far I have only done a direct injection for the module I built in qemu. Not yet packaged which I hope to build soon.
thanks again for suggestion, I accept all compliments ;D
-
@Rich
If you have time, yep is precious stuff delete info file in post 44 please.
Thanks for reading if not
-
OP just tested new TCE and am posting on wifi.
When you get pm, use this new info while you waiting for submission to filter thru. cheers and good luck
I am putting in code box as quote box was ugly to me
Title: rtl8188eu.tcz
Description: wifi kernel module & fw for below devices
Version: module: git-May4
fw: Jan17
Author: module: Ivan Ovborislav
fw: Realtek Semiconductor Corporation
Original-site: module: https://github.com/ivanovborislav/rtl8188eu
fw: https://git.kernel.org/pub/scm/linux/\
kernel/git/firmware/linux-firmware.git
Copying-policy: module: GPL v2
fw: accompanied
Size: 724K
Extension_by: aus9
Tags: wifi wlan wireless
Comments: fw=firmware
Supported class N USB wireless devices
TP-Link TL-WN722N V2/V3 High Gain
TP-Link TL-WN727N V5.20
TP-Link TL-WN725N V3 Nano
EDIMAX EW-7811Un V2 4 Nano
ASUS USB-N10 Nano B1
D-Link DWA-125 (rev.D)
D-Link DWA-123 (rev.D)
D-Link GO-USB-N150 Easy (rev.B)
D-Link DWA-121 (rev.B)
Realtek RTL8188EU
Realtek RTL8188ETV
802.11bgn Mini
ELECOM WDC-150SU2M
Sitecom WLA-1100 V2
MERCUSYS MW150US V2 Nano
Rosewill RNX-N150NUB Nano
simple instructions - insert dongle first pls
$ sudo ifconfig eth0 down # cable can remain connected
$ tce-load -i wifi rtl8188eu
$ sudo wifi.sh # and follow prompts
For module parameters, ids etc $ modinfo 8188eu
If you need power, managed mode etc
see README.txt in /usr/local/share/doc/8188eu dir
Those commands will need more TCEs downloaded and installed
Optional dependency- wireless-db.tcz -read its info please
dmesg outputs a lot of info.
Change-log: 2023/09/26 2reduce deps-fw added on 14.x
Current: 2023/09/26
-
@aus9 I am glad your solved the problem. :):)
-
Hi aus9
... delete info file in post 44 please. ...
Done. :)
-
OP just tested new TCE and am posting on wifi.
When you get pm, use this new info while you waiting for submission to filter thru. cheers and good luck
I am putting in code box as quote box was ugly to me
Title: rtl8188eu.tcz
Description: wifi kernel module & fw for below devices
Version: module: git-May4
fw: Jan17
Author: module: Ivan Ovborislav
fw: Realtek Semiconductor Corporation
Original-site: module: https://github.com/ivanovborislav/rtl8188eu
fw: https://git.kernel.org/pub/scm/linux/\
kernel/git/firmware/linux-firmware.git
Copying-policy: module: GPL v2
fw: accompanied
Size: 724K
Extension_by: aus9
Tags: wifi wlan wireless
Comments: fw=firmware
Supported class N USB wireless devices
TP-Link TL-WN722N V2/V3 High Gain
TP-Link TL-WN727N V5.20
TP-Link TL-WN725N V3 Nano
EDIMAX EW-7811Un V2 4 Nano
ASUS USB-N10 Nano B1
D-Link DWA-125 (rev.D)
D-Link DWA-123 (rev.D)
D-Link GO-USB-N150 Easy (rev.B)
D-Link DWA-121 (rev.B)
Realtek RTL8188EU
Realtek RTL8188ETV
802.11bgn Mini
ELECOM WDC-150SU2M
Sitecom WLA-1100 V2
MERCUSYS MW150US V2 Nano
Rosewill RNX-N150NUB Nano
simple instructions - insert dongle first pls
$ sudo ifconfig eth0 down # cable can remain connected
$ tce-load -i wifi rtl8188eu
$ sudo wifi.sh # and follow prompts
For module parameters, ids etc $ modinfo 8188eu
If you need power, managed mode etc
see README.txt in /usr/local/share/doc/8188eu dir
Those commands will need more TCEs downloaded and installed
Optional dependency- wireless-db.tcz -read its info please
dmesg outputs a lot of info.
Change-log: 2023/09/26 2reduce deps-fw added on 14.x
Current: 2023/09/26
Got tcz package from PM. It works perfectly, thank you very much!
-
good.
As prev suggested, if you are rarely going to use ethernet....I would suggest you add a blacklist=<modulename> to your bootloader.
inxi -Nxxx reveals the kernel module
dmesg should but for me its revealed towards the tail so
dmesg | grep eth0
does too
2) In the meantime you can reply and ask Rich to mark as solved please
-
Hi
I forgot to mention that if you want this TCE to be able to be booted, it needs to be in your tcedir. So move it there please.
There will always be some TCEs that are private and meant to be private. Example getlocale generates mylocale.tcz
Apps -> Maintenance -> Onboot Maintenance will show mylocale.tcz on the left until you click it and add it to your current boot list.
so for OP once you add it to your tcedir....do above and add it AND wifi.tcz
-
correction getlocale puts mylocale into tcedir for you.
Anyhow, whatever packages showup on the left can be included on the right for whatever your boot list is
Apps is smart enough to only edit your current list in case you are not using onboot.lst