Tiny Core Linux

dCore Import Debian Packages to Mountable SCE extensions => dCore Armv7 => Topic started by: tinycorelinuxrocks on October 20, 2012, 09:02:07 PM

Title: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on October 20, 2012, 09:02:07 PM
Would it be very difficult to add ALSA and jackd support to Tiny Core or Micro Core on a BeagleBone?
Title: Re: Tiny Core on the Beaglebone
Post by: curaga on October 21, 2012, 11:20:04 AM
You'll need to build your own kernel to support that board, we don't target the beagle family currently.

Besides that, those are "just" extensions, so you could build them. The ARM repos aren't quite full yet.
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on October 21, 2012, 11:47:19 AM
BeagleBone doesn't work from a vanilla kernel yet anyway.  Compiling my own kernel is no problem.

Copy Mode looks like the right choice for me so I can run everything including application extensions in RAM.

It looks like the ARM application extensions are very limited.  Can I compile jack in order to use it as an application extension?
Title: Re: Tiny Core on the Beaglebone
Post by: curaga on October 21, 2012, 01:15:44 PM
The members on ARM will have to answer the specifics, I'm not currently involved there. But in general, if jack runs on ARM, why couldn't you compile it?

Certainly you may need to also build dependencies.
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 02, 2012, 07:57:09 PM
I have Gentoo running on the Beaglebone and I'm trying to get Tiny Core working.  Should I need script.bin for this?  I have uEnv.txt, MLO, and uImage from Gentoo so I don't think I need the Tiny Core uImage or boot.scr.  I'm not sure where script.bin comes into play.  I don't use one with Gentoo.  If I start with my Gentoo boot stuff, should I only need uCore from Tiny Core?
Title: Re: Tiny Core on the Beaglebone
Post by: roberts on November 02, 2012, 09:17:51 PM
Script.bin, I believe, is an Allwinner specific, configuration file. It happens to be "compiled". Typically used to set devices, e.g., vga or hdmi, and screen resolutions, etc. I am not familiar with beagelboard.
Which version of arm does it support? Perhaps, I should consider posting a tarball of our rootfs then likely with your existing beagleboard kernel and modules you might have a starting point.
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 02, 2012, 10:37:55 PM
The Beaglebone is ARMv7.  I would love to get access to that rootfs.  I'm having a hard time getting uCore to load.  I tried adding the following to uEnv.txt:

fatload mmc 0 0x43100000 uCore

and changing:

bootm 0x80200000

to:

bootm 0x80200000 0x43100000

but I get the following "data abort":

## Booting kernel from Legacy Image at 80200000 ...
Image Name:   Linux-3.6.0-rc7-00219-g35e0f42
Image Type:   ARM Linux Kernel Image (uncompressed)
Data Size:    2878667 Bytes = 2.7 MiB
Load Address: 80008000
Entry Point:  80008000
Verifying Checksum ... OK
data abort
pc : [<8ff99480>]          lr : [<8ff996ac>]
sp : 8fe6abd0  ip : 8fe6d163     fp : 00000001
r10: 00000002  r9 : 00000000     r8 : 8fe6af68
r7 : 8ffbaebc  r6 : 43100000     r5 : 8ffbaec0  r4 : 43100000
r3 : 00000000  r2 : 00000010     r1 : 00000000  r0 : 43100000
Flags: nZCv  IRQs off  FIQs on  Mode SVC_32
Resetting CPU ...

I have the uCore file at /uCore.  How can I get uCore to load so init will work?
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 03, 2012, 11:08:09 AM
I've gotten farther along, but I get one of these two errors when loading the ramdisk:

RAMDISK: Couldn't find valid RAM disk image starting at 0.

Wrong Ramdisk Image Format
Ramdisk image is corrupt or invalid

Is it possible that the provided uCore doesn't work on the Beaglebone?
Title: Re: Tiny Core on the Beaglebone
Post by: roberts on November 03, 2012, 01:06:24 PM
I have posted the rootfs for armv7 used in the allwinner build.
Hope that will be helpful.
See: http://distro.ibiblio.org/tinycorelinux/4.x/armv7/
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 06:12:40 PM
Thanks roberts.  I wasn't able to get a shell prompt until I added rdinit=/bin/sh to my bootloader config.  Should that be necessary?

May I ask why proc is unmounted by /init?
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 09:29:52 PM
I've installed jack and its dependencies by extracting archives I created on a Gentoo system.  I'm hoping to install stuff this way instead of via the Tiny Core application management system.  I have:

# ls -l /usr/bin/jackd
-rwxr-xr-x    1 root     root         22148 Nov  4  2012 /usr/bin/jackd

But I get:

# /usr/bin/jackd
sh: /usr/bin/jackd: not found

Does anyone know what happened?
Title: Re: Tiny Core on the Beaglebone
Post by: tinypoodle on November 04, 2012, 09:40:41 PM
dynamically or statically linked?
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 09:58:09 PM
I believe my Gentoo install is dynamically linked.  What can I do to put together archives for jack and its dependencies that will work on Tiny Core?  I would rather not use the Tiny Core application management system.
Title: Re: Tiny Core on the Beaglebone
Post by: tinypoodle on November 04, 2012, 10:04:46 PM
You could install compile.tcz and some other dev extensions and compile by yourself.

For details on how to create extensions consult wiki.

BTW, prefix for post-install stuff (incl. tcz extensions) should be /usr/local rather than /usr
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 10:14:34 PM
I'm on ARM and compile.tcz doesn't seem to be available yet:

http://distro.ibiblio.org/tinycorelinux/4.x/armv7/tcz/

Are there any other options?
Title: Re: Tiny Core on the Beaglebone
Post by: tinypoodle on November 04, 2012, 10:18:44 PM
In that case you should post in corresponding subforum...
Perhaps a moderator could move this thread...
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 10:22:08 PM
OK but this doesn't seem like an ARM-related question.  I would be in the same situation on x86 if I didn't want to or couldn't install the necessary .tcz's.
Title: Re: Tiny Core on the Beaglebone
Post by: tinypoodle on November 04, 2012, 10:32:25 PM
OK but this doesn't seem like an ARM-related question.  I would be in the same situation on x86 if I didn't want to or couldn't install the necessary .tcz's.

Huh?
In Reply #4 you reject my Reply #3 (which assumed x86 based on subforum posted) as not applicable in your case by pointing out that for arm the situation differs   :o
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 10:34:25 PM
True, but this thread is about moving an archive compiled on one system to another system.  This applies to any architecture.
Title: Re: Tiny Core on the Beaglebone
Post by: tinypoodle on November 04, 2012, 10:50:57 PM
If you put it that way, then the short answer is that transplantation of aliens is basically unsupported and you are on your own.

Dirty hackery based on trial and error method of which I declare being guilty of now and then myself ;)

Generally speaking:
- Statically linked binaries have best chance to work
- The less deps the better
- Apps compiled either against newer or much older versions of libc are least likely to work

YMMV
Title: Re: Tiny Core on the Beaglebone
Post by: Rich on November 04, 2012, 10:55:25 PM
Hi tinycorelinuxrocks
That may be. But since you are running ARM based hardware, and there may be ARM specific information in
the answer, this thread belongs in the ARM section of the forum.
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 04, 2012, 11:00:43 PM
Quote
If you put it that way, then the short answer is that transplantation of aliens is basically unsupported and you are on your own.

Dirty hackery based on trial and error method of which I declare being guilty of now and then myself

Generally speaking:
- Statically linked binaries have best chance to work
- The less deps the better
- Apps compiled either against newer or much older versions of libc are least likely to work

YMMV

Sounds like I'm screwed. :)

I'm puzzled by curaga's answer to the question I asked before I started to make sure this was feasible:

http://forum.tinycorelinux.net/index.php/topic,14240.msg80211.html#msg80211
Title: Re: Tiny Core on the Beaglebone
Post by: tinypoodle on November 04, 2012, 11:07:22 PM
See also:
http://forum.tinycorelinux.net/index.php/topic,14130.msg79463.html
http://forum.tinycorelinux.net/index.php/topic,12448.msg67326.html
Title: Re: Tiny Core on the Beaglebone
Post by: roberts on November 05, 2012, 01:23:12 AM
I'm on ARM and compile.tcz doesn't seem to be available yet:

http://distro.ibiblio.org/tinycorelinux/4.x/armv7/tcz/

Are there any other options?
Compiling on native target allwinner is not very productive given the typical 384MB available ram space, as most are 512MB machines and given that the OS on an sdcard. Much better to use a cross-compiler on much more capable x86 machine. But if anyone wants to make a native tool chain extension then there is nothing stopping you. For myself I will continue to use a cross compiler.
Title: Re: Tiny Core on the Beaglebone
Post by: roberts on November 05, 2012, 01:25:08 AM
That rootfs is packed into an initial ramdisk and not used as is. You should consult your beagleboard docs on how to package and use, if supported, initial ram disk.
Title: Re: Tiny Core on the Beaglebone
Post by: bmarkus on November 05, 2012, 01:47:41 AM
Regarding cross-compilation this may be interesting:

http://cross-lfs.org/view/clfs-embedded/arm/
Title: Re: Tiny Core on the Beaglebone
Post by: tinycorelinuxrocks on November 05, 2012, 03:03:02 PM
As a note, I have Gentoo running on the 256MB Beaglebone and compiling on the device itself is no big deal.  I've never cross-compiled.