Tiny Core Linux

dCore Import Debian Packages to Mountable SCE extensions => dCore Armv7 => Allwinner A10 => Topic started by: roberts on September 29, 2012, 07:29:52 PM

Title: Import Debian Wheezy Armhf Packages
Post by: roberts on September 29, 2012, 07:29:52 PM
The armv7 tcz repository is now open. http://distro.ibiblio.org/tinycorelinux/4.x/armv7/tcz/
You should find that the command line tool tce works as expected and is recommended.

First in is the import utility that I have been toying with.
Like the chicken and the egg, Import needed squashfs-tools and findutils in order to function.
So I built squashfs-tools and findutils and they are in the tcz repository.

Please carefully read the info file for import.tcz. I am using exports for both the master index and your local debian mirror.
The package you select will be in placed in the directory of the same name with the converted tcz and its dependencies.
Once tested you should copy them to your tce directory.

I used exports and a local directory so that import can be run on both a10Core and Core x86. You might find it faster and more convient to use Core x86.

I have tested this with just a few packages. Namely links, wireless-tools and wpasupplicant. They all work as expected. However, note that I expect that this tool is not a panacea. I am hoping that by an early release many will help by contributing patches and suggestions so that it can support many package conversions.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on October 13, 2012, 04:29:22 AM
Hi will it be possible to make something similar for the Raspberry??
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on October 13, 2012, 08:26:38 AM
Yes. I have just begun.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: tinycorelinuxrocks on November 04, 2012, 08:15:38 PM
I'm a bit confused.  Does "import" import packages from Debian and Ubuntu?  Does it convert them to .tcz packages?
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 04, 2012, 10:16:22 PM
Both piCore and a10Core are kernel and library compatible with raspbian and debian wheezy. Therefore it should be possible to repackage debs into tcz. That is the stated goal of import. To dynamically create tczs by repacking existing binaries. It has been over a month since I have even had time to revisit this area.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 10, 2012, 08:39:47 AM
Finally been able to revisit import. Been playing with rpi and have been able to import rsync, mc, dillo, and leafpad!
Almost forgot.... ace-of-penguins. Now playing freecell on rpi  8)
Title: Re: Import Debian Wheezy Armhf Packages
Post by: hlavery on November 13, 2012, 05:52:57 AM
Is there some way to update the debian_wheezy file list that is accessed by import.tcz?  There seem to have been some updates on the debian repository affecting files that include version numbers.  For example, when I download mc, one of its dependencies is:

libglib2.0-0

However, the download fails as the current file is libgib2.0-0-2.33.3-1 and libglib2.0-0 is "not found".

I suppose I could search/change the debian_wheezy file to update this and its depends-on, but I suspect this would lead to disaster.  Further, there seem to be other instances of such changes. 

Thanks for any assistance.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 13, 2012, 07:38:00 AM
I am working on v0.2 of import and yes, I too have found what you describe.

In v0.2 I offer a select list for such "not found" packages with the closest matches currently found in the Wheezy repository.

I need to clean up some code and will then post v0.2 soon, next day or two.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on November 13, 2012, 08:33:28 AM
Finally been able to revisit import. Been playing with rpi and have been able to import rsync, mc, dillo, and leafpad! I
Almost forgot.... ace-of-penguins. Now playing freecell on rpi  8)

Hi Roberts, does this mean that it is working for raspberry now as well?
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 13, 2012, 11:20:30 AM
Yes. When I finish some clean up on v0.2 I will post it raspberry pi in the armv6 repo.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 14, 2012, 08:28:02 PM
v0.2 of import now posted and available for both rpiCore and a10Core.
This is only a tool. A work in process. It has been useful for me and for some others as posted.
It is not a panacea. As time permits and feedback is considered hopefully this tool will be honed over time.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: hlavery on November 15, 2012, 02:18:20 PM
Thank you for your work on import.  It is now much easier to use.  I downloaded links for example with no problems.  Unfortunately, the issue I described above (dependencies for mc, perl and maybe others) is still problematic;  import now offers a menu to select options, but the menu is empty.  I am working on a different Allwinner device (Miniand Hackberry) so perhaps there is some odd difference if import is working on other hardware?
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 15, 2012, 07:56:49 PM
OK. I will have the following shortly for v0.3:
1. Download Wheezy Master Index directly from Debian Mirror, lastest seems to be Nov 15.
2. Allow an option for import to skip dependencies and force only the specified package to be downloaded and converted.

Note: The not found items are in /tmp/import.log
Note: With our trusty links browser we can actually browse and even download missing items. :)
Note: I had been able to import mc, but mc did not work becuase bterm needs a terminfo item. :(
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 16, 2012, 06:48:20 AM
Re-posted import.tcz affects allwinner only devices.
The Raspberry PI version already downloads direct from Raspbian.

Now the Allwinner version  downloads Master Index direct from Debian.
You must remove the current Master Index from your tcedir.

Tested download of both mc and perl. Since I am not a user of either of
these. I could only verify that the extension builds, loads, and an ldd of
the binary passed.

The trivial hello.pl also ran. For mc we will need to find/make a terminfo
for bterm on allwiiner.

More to come...
Title: Re: Import Debian Wheezy Armhf Packages
Post by: hlavery on November 16, 2012, 09:04:31 AM
Thanks,  import now seems to work very well, and I gave it a workout importing build-essential and found no issues.  Is the bterm font easily changed now that I can access things...seriously ugly in my screen.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 18, 2012, 11:39:41 AM
A thank-you to hlavery. He has been helping test and even pushing the import scripts to their limits.
Even importing xorg. He got X started too and shared this with me.
Since then, I now have the basic Tiny Core X environment well underway, Xprogs, and flwm, on Allwinner devices.
This proves the concept and shows the power of import. Much tweaking still to do. Thought I would share this news.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 26, 2012, 02:52:05 PM
Import has been updated to v0.3. Now supports Debian postinst scripts. This again widens the packages that are supported for import. Currently the focus is on the Allwinner, although the potential can be much wider. This is an experimental approach and at present very timely. Much still to do.

Find it on the Allwinner page:  http://code.google.com/p/tinycore-a10/downloads/list
Title: Re: Import Debian Wheezy Armhf Packages
Post by: hlavery on November 26, 2012, 05:11:46 PM
Works perfectly and boots quickly to desktop on my Hackberry.  Pretty amazing, in all.  I'll be testing more imports, and will let you all know what happens.  Thanks!
Title: Re: Import Debian Wheezy Armhf Packages
Post by: hlavery on November 27, 2012, 11:50:05 AM
Here is what I did to get a working TinyCore desktop on Allwinner (Hackberry):

How to assemble TinyCore for Allwinner A10 from current "parts":

(1) Download all the *.bz2 files and the *.img.gz file from the code.google.com repository site.

(2) unzip the image file (gunzip *.img.gz) and dd the image file to card (dev/foo)

(3) Create a second partition, ext3 or your preference, on the rest of the card with gparted, etc.

(4) in the ext3 partition, mkdir /tce and within it mkdir /tce/optional and /tce/ondemand

(5) unzip the other repository files (tar xjvf *.bz2) into the /tce/optional directory

(6) in /tce, touch onboot.lst

****IF and only if you are NOT using a Mele, you will need to fix a few things now.
    For a Miniand Hackberry:
     (a) dd sunxi-spl.bin and u-boot.bin for your device to the "boot" section of the card AND
     (b) copy your script.bin to the first (FAT) partition to replace the one that is there.
EDIT:    "The two "boot sector" files came from jas-hacks' work at:
              https://www.miniand.com/forums/forums/development--3/topics/uboot
              with links to the sources at
              https://github.com/linux-sunxi/u-boot-sunxi." /EDIT

Continuing:

(7) Put your sd card in the device and BOOT!! (into the bterm interface)

( 8 ) Load import.tcz (tce-load -i import)

(9) Have import get the Debian wheezy list:  (import setup)

(10) Import xorg (import xorg); standby to answer q to one download, wander off for awhile.

(11) There will now be a directory xorg/ ; cd into it and mv * /mnt/mmcblk0p2/tce/optional/

(12) Similarly, import hsetroot and xterm and move the resulting files to optional.

(13) Might be a good time to create mydata.tgz;  (filetool.sh -b)

(14) Edit /mnt/mmcblk0p2/tce/onboot.lst to load on boot:
   import.tcz
   hsetroot.tcz
   xorg.tcz (note lowercase x)
   xterm.tcz
   Xprogs.tcz (note uppercase X)
   fltk-1.1.10.tcz
   flwm_topside.tcz

(15) reboot, use (right click)->SystemTools->RunProgram to launch xterm,

(16) In /home/tc, uncomment xterm in .xsession; backup (filetool.sh -b)

(17) reboot...desktop plus xterm will appear.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on November 27, 2012, 10:29:04 PM
I am posting this via the Surf browser. Imported and running on my Mele Allwinner Arm Computer!
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on December 11, 2012, 07:23:28 PM
With the latest discussion of dwb gui web browser imported and running great on the Allwinner Arm platform, just for kicks...
Using my latest import suite of scripts, I imported dwb on Raspberry Pi. I am posting this via dwb on Raspberry PI.  8)
Only one small adjustment which can easily be added to startup script, and later will be automatic via importscripts on server.
That being compiling desktop schemas. It is not as fast as Allwinner, which is to be expected but useable.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on December 12, 2012, 10:48:33 AM
I just uploaded import v0.4 suite of utilites.
New utilities are mkcpio, loadgz, and updstartscript

Use mkcpio to turn a package import directory into a single cpio gz.
You may then place the .gz in the root of your tce directory for much improved load times.
A good use of this new option is xorg. Using xorg.gz allows boot to X desktop in approx 15-20 seconds. I also use it for dbus. Note these load to ram so careful what you choose. Always have swap.

loadgz is similiar to load-tce. Make a gzs directory under your tce directory. Then load additional cpio gzs with loadgz. Startup scripts are honored.

Finally updtstartscript, will allow quick and easy access to create or update a tcz's startupscript. It unpacks, calls vi to edit the extension's startup script, and then repacks the extension.

Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on December 29, 2012, 08:21:40 AM
Using my latest import suite of scripts, I imported dwb on Raspberry Pi. I am posting this via dwb on Raspberry PI.  8)

Hi Roberts

I now have a working version of tinycore on the raspberry (4.7.2), and would like to try to import some of the Debian packages, however, I cant find the import.tcz in the Raspberry part of Army Core.
So do I simply take it from the Allwinner repro and use it in raspberry or?

 
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on December 30, 2012, 08:11:20 AM
Import from Allwinner supports Raspberry Pi.

Note however that my focus is first towards Allwinner as I do little import testing on Pi.
I now use my Pi as a local server and only boot a desktop to test new Core images as I build them.

I am currently revisiting Core's base to make it more resilient with regards to the use of imported packages.

While I, as well as several others, have a complete desktop, with GUI browser, all via import. Import is still at a very early stage of development with many changes forthcoming.

After I finish hardening Core I will revisit import for better support of more packages and a smoother operation.

The goal remains the same. Import is to be an additional option across all platforms, just as community built tczs and community built scms. Import's goal is to offer a wide range of available packages while maintaining Core unique feature of pristine boot and ultra fine grain control of applications to be loaded. 

Initial milestones will continue to target Allwinner. Others to follow.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on December 30, 2012, 12:32:38 PM
Thank you for the answer.
But how do i use it in raspberry, i mean i cant install the import.tcz on my raspberry, as it is not available for the raspberry?
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on December 31, 2012, 09:32:23 AM
http://repo.tinycorelinux.net/4.x/armv6/tcz/import.tcz
http://repo.tinycorelinux.net/4.x/armv6/tcz/import.tcz.dep
http://repo.tinycorelinux.net/4.x/armv6/tcz/import.tcz.md5.txt

You will need to get findutils.tcz and squashfs-tools-4x.tcz from repo.picorelinux.org

To use, create an import directory, e.g., in the root of your tce directory and cd into it
sudo import nano

It will create a directory named nano and will place all dynamically created tczs into the nano directory.

Upon successful completion, cd nano, tce-load -i nano.tcz

YMWV as import is early stage of development and is not actively being tested on raspberry pi
Title: Re: Import Debian Wheezy Armhf Packages
Post by: bmarkus on December 31, 2012, 09:58:15 AM
I will move it to the picorelinux.org repo next year. Now heading to the bar :)

Happy New Year to all!
Title: Re: Import Debian Wheezy Armhf Packages
Post by: bmarkus on December 31, 2012, 08:55:28 PM
import.tcz added to the armv6 (piCore) master repo, repo.picorelinux.org
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on January 01, 2013, 12:38:55 AM
Tanks, i Will give it a try.
Happy new year
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on January 01, 2013, 01:47:12 AM
Hi I see that the version in raspberry is version 0.2, whereas Roberts anounced version 0.4.
Is that something to wait for in raspberry?
Title: Re: Import Debian Wheezy Armhf Packages
Post by: bmarkus on January 01, 2013, 02:05:01 AM
I just copied over import.tcz.info file which may be for the previous release.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on January 01, 2013, 02:37:13 AM
Ok.
Think you i Will give it a try.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on January 01, 2013, 10:06:36 AM
Hi just to follow up.

The import script is working well for many packages, however, I also tried to import in order to Sound on the raspberry, without luck.

I imported alsa-utils and libasound, the tcz building went Well, everything seems to be ok, and tinycore seems to load alsa fine, But aplay Will not play, it complains about: Cannot access file /usr/local/share/alsa/alsa.conf.

So I Think that i Will wait until bmarkus have build a working alsa solution,
Title: Re: Import Debian Wheezy Armhf Packages
Post by: bmarkus on January 01, 2013, 01:33:00 PM
Now I can play back .wav through the 3.5 jack utput. Will check HDMI and first version of ALSA stack will be available in few days.

What is really a disappointment the complete lack of audio input on the board so you need USB sound modem to capture audio :( At least for me this is really annoying with the Pi.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on January 01, 2013, 01:44:27 PM
Fantastic, looking forward to try that.
How did you do, did you use the import script?
Title: Re: Import Debian Wheezy Armhf Packages
Post by: bmarkus on January 01, 2013, 01:46:01 PM
Fantastic, looking forward to try that.
How did you do, did you use the import script?

No, I'm not using import script or any alian applications. ALSA stack is built from source on Pi.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on January 07, 2013, 02:03:17 PM
Just for kicks, while testing my next iteration of the import suite, I imported moc on the Allwinner.
It works great. I am listening to my collection of mp3s while typing this is on the dwb browser.  8)
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on January 08, 2013, 10:12:59 AM
More progress on next iteration of the import suite.
Mplayer imports and plays videos smoothly with sound. Tested on my A10 set top box.
I can now play the two new videos that Curaga and Brian recently posted!  8)

Posting this from Allwinner A10 tablet running Tiny Core with wireless and using dwb browser.
All imports.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on January 15, 2013, 11:42:54 AM
Updated import.tcz is now available for the Allwinner port.

Change log:
* import directory is now official and is auto created under the tcedir
* debian package master index is maintained via zsync for faster and much improved import results
* modules and libs are better support for extensions.
* reduced redundancy for scanning and downloading packages.
* Support for import scripts. Import scripts create or merge with startup script, .i.e., postinst
* import program supports -i and -b after testing, i.e., import without flags, test run from import directory, and then run import again with flags, only the copy/merge to tce/optional will occur.

See the new updated README for a sample use and discussion of import:
http://tinycorelinux.net/4.x/armv7/README.txt

These changes should provide for a much improved import experience from the vast Debian repository.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on January 23, 2013, 11:18:27 AM
Updated import suite. Added the capability to do foreign imports.

You can use x86 Core with import suite to import for arm targets.
Example from x86 Core:

import nano armv7

Will create a nano directory under import directory containing the nano extension for armv7hf

This will be helpful for those needing to get wireless extensions on a device that does not have wired network support. As such needed extensions can be obtained from x86 machine while downloading and preparing the Core arm image.

Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on January 26, 2013, 11:46:44 AM
REPOSTED import.tcz to fix a typo in rarely used applet not likely encountered at this early stage of development.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: sbp on April 29, 2013, 11:16:33 AM
Hi
I just wanted to use the import script again on my raspberry, but now I can't locate it neither om the armv7 or the armv6 repro?

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

Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on April 29, 2013, 11:37:06 AM
Not supported on Rpi.
See: http://forum.tinycorelinux.net/index.php/topic,14332.msg88383.html#msg88383
Major changes were done to import, now a script in the deb2sce suite. While still not a panacea, it will continue to improve providing an additional option to community built tczs. 
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on May 03, 2013, 10:40:25 PM
Many enhancements have been made to deb2sce.tcz, aka import, namely meta packages and option flags.
See http://tinycorelinux.net/4.x/armv7/README/README-X-Desktop.txt and
http://tinycorelinux.net/4.x/armv7/README/README-import.txt
Title: Re: Import Debian Wheezy Armhf Packages
Post by: athouston on July 12, 2013, 04:39:37 AM
I have imported rdesktop on my MK802+ ARM stick (TCL v5) and it works a treat. However I cannot get the -o option to add it to the ondemand menu and have to loadsce it each time I want to use it. Any suggestions on the manual method to accomplish this.

I also imported firefox, it loadsce ok but when I run it it says it can't be found. ???

Any suggestions gratefully received.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on July 12, 2013, 07:58:04 AM
Thanks for reporting import -o. I have fixed this for next cut.
You should be able to use the ondemand command to add an item, e.g.,
$ ondemand rdesktop
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on July 12, 2013, 08:24:13 AM
FYI On arm platform, you will get better results with a light weight browser, e.g. midori.
If you are a vi fan, I find I get the best results with dwb.
I believe iceweasel is the "firefox" supported in Debian Wheezy.

Midori, dwb, and iceweasel all are known to work via an easy import.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: athouston on July 12, 2013, 05:10:40 PM
Thanks for the heads up on the performance issues. I'll try your suggestions.

What's the easiest way to "uninstall" firefox now that I have downloaded it?

HUGE KUDO's to all involved in this project. I have been playing with rdesktop imported from Debian and it seems pretty solid. My next step is to get printing and Erlang working and I am a very happy camper.
Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on July 12, 2013, 05:32:46 PM
To delete an sce is simply...

rm /etc/sysconfig/tcedir/sce/firefox.sce

You should also check that is it not in sceboot.lst
vi /etc/sysconfig/tcedir/sceboot.lst

And finally, in case you added it to the ondemand directory.
rm /etc/sysconfig/tcedir/ondemand/firefox
Title: Re: Import Debian Wheezy Armhf Packages
Post by: athouston on July 14, 2013, 05:44:55 PM
Great, thanks.

If I understand this correctly the solution suggests that the import process packages all files and dependencies into a single "executable" (.sce file). This also suggests that removing the .sce file automatically also cleans up unused dependencies so you are not left with a lot of unused files. I hope this is the case because I would really like that. There is an obvious space trade off but considering the minuscule OS core and the frugal nature of the whole install I think that would be a small price to pay.

This would be different to the other operating system which has a central core of all dependencies that are shared across all executables.

Thanks.

Title: Re: Import Debian Wheezy Armhf Packages
Post by: roberts on July 14, 2013, 09:10:42 PM
The goal of the .sce package type is to contain the application or system function and its needed dependencies beyond that offer by the base.

So, yes one can easily remove an application sce file and not break other applications.

An sce is not executable, it is merely a squashed file system, in tcz parlance, it is similar to the app (tcz) and its dependencies (.dep) in one single mountable squash file system (sce).
Title: Re: Import Debian Wheezy Armhf Packages
Post by: athouston on July 15, 2013, 12:38:13 AM
Cool... I like...