Author Topic: My Updated Beta3  (Read 5777 times)

kkazakov13

  • Sr. Member
  • ****
  • Posts: 408
    • View Profile
My Updated Beta3
« on: May 11, 2008, 02:08:45 pm »
Last updated: 13 may 2008


fixes by default (located in the default "backup" file that the system is restored from):

These changes you can see / replace in backups/backup*.tar.gz (can't remember the name right now, but it's only one file)

note: for the .tar file, check section 'The upgrade/fix all-in-one'

* image files open with gpicview
* mc is now able to open .ipk files on enter key
* /usr/bin/mbsession - can't remember what i've fixed there ...
* startx - added  '-kb -screen 480x640@270'
* /etc/X11/kb - added usb.xmodmap (most of the things do work ...)
* /etc/X11/kb - userdefined.xmodmap - F1-F10 support, Insert key support, some other fixes - see it closer
* /etc/apm/scripts.d/hwclock fixes suspend/resume problems with clock setup
* /etc/mplayer - best setup (my opinion) for playing with mplayer in console
* /etc/pcmcia/ide.opts - this is a strictly setup like mine - /dev/hda3 points to /storage here
* /etc/rc.d/rc.sysinit ... can't remember what I've fixed here
* /etc/sysconfig/clamshell/* - adds support to switch wallpaper in ROX with /home/root/rox_wallpaper_landscape and /home/root/rox_wallpaper_portrait ( simple text files which contains path to images )
* /etc/fstab - strictly set up for my hdd setup - do not use if your's is not like mine ( or change to your preference )

scripts in /usr/local/bin ( also installed with the backup file mentioned above ):

* backup.sh - allows you to make full backups of all directories that you might need, in a specific location - PLEASE EDIT BEFORE USE!!!
* build_prepare and build_prepare_compat - development scripts
* change_wallpaper - this is for ROX desktop
* cleanup_some_space - removes some doc files
* cpu1, cpu2, cpu3, cpu4, cpu5, cpu6 - underclocks/overclocks the cpu (SL-C3200 tested ONLY. might work on SL-C3X00, but not for others - please check the values inside)
* distcc_use_home - development script
* dt - the right way to synchronize your date and preserve it correctly. Check sync server inside, if you don't like Bulgarian one
* duh - the same as 'du -hacs'
* lt_set and lt_unset - sets and unsets timezone - this is needed for correct operation of 'dt' script. CHECK CONTENTS and change to your timezone.
* make2 and make3 - development scripts
* mp - script that will switch to 624mhz, play the file you want and then go back to 416mhz. Use under console for best results! It will play greatly encoded files in 640x480. Check my script for making such files.
* reb - okay, this is cleaner way to reboot your system. If you don't clean /etc/mtab , you might end up with some non-working X terminal screens. But if you reboot with 'reb' - everything is perfect
* s - suspend the machine (if used in console/x console) - actually equivalent to 'sync ; date ; apm ; apm --suspend' - sync, show some info and suspend, but it's faster for me to type 's'
* search_remote - useful script to search for packages
* socklist - borrowed from slackware - better way to show what's listening on your machine
* zstore.sh - okay, this one is actually VERY powerfull, if you use it correctly. I suggest that you clean it up from my stuff, and then add your stuff. The idea is to backup ONLY WHAT YOU WANT from your Z machine, not everything. The resulting backup file is stored (right now) in /mnt/card/backups/backup_stored_files.tar.gz and later used in the install procedure. So, the idea is after you setup zaurus the final way you want - run 'zstore.sh' (of course, edit it first!) and it will backup ONLY the settings/files that you want. If you do this, the first time it might take you some more time, but the next time you add something, it will be really fast. Using this script, it's really quite fast for me to restore in clean system from plain beta3 to _exactly_ what I've setup before the reinstallation. It's worth checking it.


Here's how I do it (more info to follow):

[size=]Initial info[/size]
My HDD setup is this:

/dev/hda1 points to /mnt/ide - place for additionally installed application. This is by DEFAULT.
/dev/hda2 is swap file or some experimental partition
/dev/hda3 points to /storage - a place where I store everything that's mp3s or videos or devel files

beware that some system files might not work correctly if this is not the way your system is set up.

To have more space in /tmp, create directory in /storage ( /dev/hda3 ) named 'tmp' ( /storage/tmp ), it will be used in install procedure to link it to /tmp

I will explain, according to my setup. Whenever appropriate - please check and edit the target /dev/hda* or /dev/whatever and target locations.

[size=]The upgrade/fix all-in-one[/size]

1. Download this archive:

http://z.drun.net/upgrade/3heavy-20080512.tar

and unpack it in /mnt/card or wherever you want. If you use different location, don't forget to edit install/functions and replace the paths with the appropriate ones.

2. Edit files according to your settings ( if needed ) AND check the installed files:

a ) GENERIC settings: /mnt/card/install/functions - these are for target locations. Note that by default ipkg will not install in / - because it can easily go short on space, but on the secondary location ( /mnt/ide by default ). This can easily be changed by editing /etc/ipkg.conf later.

b ) PLEASE, examine /mnt/card/install/fixes/* files and if needed - replace or remove parts of them, to suit your installation and/or preference. Specially fix_other scripts needs a lot of changes or things to be removed. I've left some of mine for reference.

c ) edit /mnt/card/install/install_packages_upgrade and check the removed packages section. Normally there's a good reason for them to be removed, so you can leave them as-is.

d ) Check the files that are processed. they are named packages_upgrade, packages_required, packages_development, packages_custom_root, packages_custom_additional. While you can edit freely *custom* directory contents, beware that _upgrade, _required might be essential for correct system installation/upgrade. Files from packages_custom_additional will go to the specified secondary location. packages_custom_root will go to / .

e ) I suggest, after editing the files, store them somewhere safe.

3. cd to /mnt/card/install/

Note:
./install script basically runs these 4 scripts:

./install_network $@                                                                                                                      
./install_scripts_fix $@                                                                                                                  
./install_packages_upgrade $@                                                                                                              
./install_recover_settings $@  

so, if you don't want any of them - just comment it out.

In order to install the updates/required upgrades and additional packages, run

Code: [Select]
./install ok
It will remove some files, install the required ones, upgrade the newer, and then add packages from  *custom* directories. You should check to see if there are things that you don't need, inside. I copied my setup, so you can just remove files, not add  Of course, you're free to add whatever packages you need additionally.

for development ( -devel ) packages installation, run

Code: [Select]
./install_development ok

[size=]Multimedia[/size]

I use this script to convert movies on my slackware box for playing under console in pdaX b3

http://z.drun.net/upgrade/zencoder

usage is like this:

zencoder /path/to/movie.avi /path/to/output.avi [/path/to/subtitle.sub|srt]

You need working mplayer with codecs that can handle opening the file you want.

Best playback expirience you will get if you use my mplayer.conf setup and the script 'mp' located in /usr/local/bin/ . Beware that it overclocks the machine to 624mhz (tested on SL-C3200 - might be different on others). Althought everyone says it's dangerous to do this, I've played more than 150 whole movies like this, without _any_ problem so far, and my Z is working still

This should cover what I wanted to say in general, I will add more info if needed, or when I have it, or when I fix bug. Hope you enjoy painless updated beta3 setup, as I do.


[size=]Cross compilation setup[/size]
It should be noticed that I use Slackware -current, but the setup is compatible with any distro ( It should be ). You may need to install distcc server, don't know - with Slackware it comes preinstalled.


Desktop setup

Download this archive:

http://z.drun.net/devel/opt_cross-20080511.tar.bz2

Unpack it somewhere ( it contains subdir cross/ ) and symlink this cross to /opt/cross, like this

Code: [Select]
ln -s /storage/devel/cross /opt/cross
Okay. When I need distcc running, I execute (normal user, not root) this shell script:

http://z.drun.net/devel/start_distccd

It basically contains only the following:

Code: [Select]
#!/bin/sh
PATH=/opt/cross/arm/3.4.6-xscale-softvfp/bin:$PATH nice -19 distccd -j 2 --daemon -a 192.168.3.10

What it does is to setup path to cross compiler before the normal path to compiler and execute nice ( no need to get all the cpu for your desktop ) which executes distccd with 2 threads in daemon mode and will accept requests for IP 192.168.3.10 ( That's my Zaurus ). Refer to distccd documentation for more parameters, those are mine.

When you execute it, distccd listens and basically, your box is ready to accept connections. Note: the cross compiler might be outdated in terms of header files and whatsoever. But I've compiled SO much programs without _any_ problem, so I don't consider it a major thing. However, if something fails in crosscompilation, it will be built natively automatically.


Zaurus setup

download and extract somewhere where you have space, this archive:

http://z.drun.net/devel/native-20080512.tar.bz2

I personally extract it in /storage/devel/ and do

Quote
ln -s /storage/devel/native /opt/native


I have this in /etc/profile: (note that my custom built setup updates /etc/profile with this code already, it's here for anyone who wants to use onboard (and cross) compilation of programs:

Code: [Select]
###### devel env

export QMAKESPEC=/usr/lib/qt/mkspecs/default/
export QTDIR=/usr/lib/qt
export KDEDIR=/usr/lib/kde
export KDEDIRS=$KDEDIR
export LD_LIBRARY_PATH=$KDEDIR/lib:/opt/native/arm/3.4.6-xscale-softvfp/lib:$QTDIR/lib:/opt/native/arm/3.4.6-xscale-softvfp/armv5tel-cacko-linux/qt3/lib:$KDEDIR/lib:/usr/lib:$LD_LIBRARY_PATH
export NATIVE_SDK_FILES_PREFIX=/opt/native/arm/3.4.6-xscale-softvfp/armv5tel-cacko-linux
export QMAKESPEC=/opt/native/arm/3.4.6-xscale-softvfp/armv5tel-cacko-linux/qt3/mkspecs/default
export DISTCC_HOSTS="192.168.129.1 localhost"
export PKG_CONFIG_PATH=/usr/lib/pkgconfig:/usr/local/lib/pkgconfig:/usr/X11R6/lib/pkgconfig:/opt/native/arm/3.4.6-xscale-softvfp/armv5tel-cacko-linux/lib/pkgconfig:/opt/native/arm/3.4.5-xscale-softvfp/armv5tel-cacko-linux/lib/pkgconfig:/usr/local/lib/pkgconfig:/usr/X11R6/lib/pkgconfig
export PKG_CONFIG=/opt/native/arm/3.4.6-xscale-softvfp/bin/pkg-config
PATH=$PATH:/opt/native/arm/3.4.6-xscale-softvfp/bin:$QTDIR/bin:$KDEDIR/bin


My /usr/local/bin/distcc_use_home contains (change the IP address to whatever you like):

http://z.drun.net/devel/distcc_use_home

Code: [Select]
#!/bin/sh

. /etc/profile

export PATH=/home/root/distcc:/usr/bin:$PATH
export DISTCC_HOSTS="192.168.3.1 localhost"

echo "Use 'exit' to exit"
echo ""

/bin/bash

Ok, so - my zaurus have 192.168.3.10 as IP and my box's IP is 192.168.3.1 - it's easy to understand, that those are my values - you need to change them if your setup differs.

If you want to compile something, you need to execute this shell script _before_ starting compilation.

Compiling ... autotools based programs

That's the easiest thing to compile. I personally use the following script for this:

http://z.drun.net/devel/build_prepare

or the more compatible one:

http://z.drun.net/devel/build_prepare_compat

the one have FLAGS="-mcpu=xscale -mtune=iwmmxt -O3 -fomit-frame-pointer -fno-common"
the other have FLAGS="-O2"

it's up to you to choose which one to use. I personally prefer more optimized one. In _some_ cases, the compilation may fail with very strange problems. Try make distclean and use the second one. May not fix it, but you can try.

If the compilation is okay, you will have your package pseudo-installed in $PWD/package directory.

Making package out of a directory

First, cd to $PWD/package/ or whatever your directory is. Then create directory named CONTROL and put a file inside, named control. In my case the full path to the file would be /storage/devel/build/program-1.0.1/package/CONTROL/control

It should contain something like this (those are the minimal required fields):

Code: [Select]
Package: lighttpd                                                                                                                          
Version: 1.0.0                                                                                                                            
Architecture: armv5tel                                                                                                                    
Maintainer: wasp@drun.net                                                                                                                  
Description: some text here

You can also add scripts inside CONTROL directory, named postinst, postrm, preinst, prerm - via them you can control whether to start/stop a service before/after install or removal.

Ok, so it's up to you to strip the binaries ( build_prepare tries to make install-strip, but this may fail sometimes ). It's up to you also to remove all doc, man pages, as your zaurus have limited space.

I normally also copy package dir to package-dev and separate the files - /usr/bin/include and /usr/lib/pkgconfig and /usr/lib/*.a and such files go into -devel package, all others are in the normal one.


Then, go to the directory that contains package/ directory, in my example - /storage/devel/build/program-1.0.1/ and type:

Code: [Select]
mkipkg package
If you don't have errors in your CONTROL/control file, you will get the ipk in the same directory with a small notice about it.


Common issues

1. If you encounter PATH_MAX undefined, edit config.h and add

Code: [Select]
#define PATH_MAX 65535
I fixed this while ago in the native compilation setup, but I lost it , and had to restore from backup, so I never fixed it again













more will follow soon ...
« Last Edit: May 13, 2008, 03:12:22 pm by kkazakov13 »
SL-C3200 ** FOR SALE :( **
https://www.oesf.org/forum/index.php?showtopic=25969

Canon K30225 CF wireless card
Taxan iTax-LAN10 wired card
My packages for customized pdaXrom beta 3

pwyll

  • Newbie
  • *
  • Posts: 7
    • View Profile
    • http://
My Updated Beta3
« Reply #1 on: May 11, 2008, 04:19:31 pm »
Quote from: kkazakov13
I will soon release download archive for updating beta3 my way ... for whoever might be interested in it.

...

I will post more details later. Just needed to say it, to hear some opinions, if you're interested.


I would be quite happy or the chance to try it, if I can run it on an Akita.


Thanks,

Scott

kkazakov13

  • Sr. Member
  • ****
  • Posts: 408
    • View Profile
My Updated Beta3
« Reply #2 on: May 11, 2008, 04:26:57 pm »
Might work on Akita, but I make usage of the extra space on hdd ... so ... you have to either remove most of the additional packages or install additional files to sd/cf.
« Last Edit: May 11, 2008, 04:27:19 pm by kkazakov13 »
SL-C3200 ** FOR SALE :( **
https://www.oesf.org/forum/index.php?showtopic=25969

Canon K30225 CF wireless card
Taxan iTax-LAN10 wired card
My packages for customized pdaXrom beta 3

scheck.r

  • Sr. Member
  • ****
  • Posts: 320
    • View Profile
    • http://
My Updated Beta3
« Reply #3 on: May 11, 2008, 05:41:00 pm »
That's great.
I am using a C-1000 and I have already updated/upgraded form pdaxii13 5.4.9 with your feed and it's rock solid. I started compiling natively some simple apps but it's very slow. A development distcc setup and archives and files would be very useful for everybody so that we can contribute more often.

Thanks
SL-C1000 from PriceJapan(cheap and very fast shipping) with EA-70 power adapter, iRiver USB Host cable, PDAIR case, pentopia stylus, ultra clear screen-protector from shop.brando.com.hk only $3 for shipping worldwide
4GB Hitachi Microdrive, 1GB Kingston Elite Pro CF, 4GB Transcend 150x SD, Symbol Spectrum 4137 CF WiFi(low power)
PdaXrom pdaxii13 5.4.9 updated with Kkazakov13's feed. I owned a SL-6000L before

pwyll

  • Newbie
  • *
  • Posts: 7
    • View Profile
    • http://
My Updated Beta3
« Reply #4 on: May 11, 2008, 11:56:08 pm »
Quote from: kkazakov13
Might work on Akita, but I make usage of the extra space on hdd ... so ... you have to either remove most of the additional packages or install additional files to sd/cf.

The only two distributions I've run (I'm relatively new to the Z scene) are PdaXii13 (full) and Debian (currently), so I am used to running from the sd card (have to keep the CF open for wifi).  While I'd love to have a 3100/3200 for the space and versatility, it's not in the cards right now.  I'll have another Akita on the way shortly, so if the install/conversion is problematic I should be able to help work on it.  The problem is I'm not really clever enough to come up with ideas on my own so I'll need someone else to tell me what to do--I'm *generally* good at following instructions    


Scott


Not suggesting that you take time to try to help me do something with your work that you never intended, just offering help to any other akita owners who may be interested in trying if the install turns out to be not as straight-forward as moving the additional files to the card...  

kkazakov13

  • Sr. Member
  • ****
  • Posts: 408
    • View Profile
My Updated Beta3
« Reply #5 on: May 12, 2008, 09:31:16 am »
I'm now preparing updated setup ... I'm currently replacing bluez with newer version, dbus - also with newer version (have some issues there, trying to fix them) and Python to 2.5.2 ... while that's not mandatory update - I found few programs ( blueman specifically ) that I would like to use on Z , that require newer Python. I will not build python-core, python-audio, etc, etc packages. Will compile Python-2.5.2.tar.gz and then add everything python-based programs need around it.
« Last Edit: May 12, 2008, 09:33:55 am by kkazakov13 »
SL-C3200 ** FOR SALE :( **
https://www.oesf.org/forum/index.php?showtopic=25969

Canon K30225 CF wireless card
Taxan iTax-LAN10 wired card
My packages for customized pdaXrom beta 3

kkazakov13

  • Sr. Member
  • ****
  • Posts: 408
    • View Profile
My Updated Beta3
« Reply #6 on: May 14, 2008, 11:11:26 pm »
Please, try it and tell me if you encounter any problems, mismatch or do not understand what I've written  I will then fix it.

Oh, yes, and I don't take any responsibility for any damage you may have  This works great here, but might not work for you. No idea why
« Last Edit: May 14, 2008, 11:18:23 pm by kkazakov13 »
SL-C3200 ** FOR SALE :( **
https://www.oesf.org/forum/index.php?showtopic=25969

Canon K30225 CF wireless card
Taxan iTax-LAN10 wired card
My packages for customized pdaXrom beta 3

ecc_hy

  • Full Member
  • ***
  • Posts: 125
    • View Profile
My Updated Beta3
« Reply #7 on: May 15, 2008, 11:15:31 pm »
Very google resouce, a lot of api need to be compiled again since gtk code has been upgrade.
SL-C1000, Roku wifi, pdaxii13v2/Debian dual booting