Friday, October 31, 2008

Tutorial of the Week: How to Install 3.0 on Ubuntu 8.10

I guess everyone already knows that 3.0.0 will not be available  for the Intrepid Ibex (Ubuntu 8.10), because the developers did not wanted to include it could create new bugs
and delayed the release 

 What do I need to get started? Ubuntu 8.10 (32-bit or 64-bit)...

 Read the full tutorial here.

I like it to do it from the command line 

sudo gedit /etc/apt/sources.list.d/openoffice.list
deb intrepid main
sudo apt-get update
sudo apt-get dist-upgrade

Vote for a beautiful, usable Ubuntu

If you'd like to see this theme instead of the current Intrepid theme, please let them know!

read more | digg story

How to make money with free software...

An awesome story of designing the new 5 euro commemorative coin with the theme 'Netherlands and Architecture', using free software.

read more | digg story

Thursday, October 23, 2008

Why pascal ?

it’s all the power of the simplicity (oo pascal follows the kiss philosophy and in a way is better than c++ for example)

Most of the time you have to rewire and damage your brain for c++

but pascal is focused to be an learning tool and it’s easier for the brain it seems close to pseudo code and the way brain works

Just go in an computer science class and ask students what they like:c++ or pascal
I’m not talking about the genius but the average guy
The same is with php or java script it’s easier to catch and learn them than java or c++

Check the tiobe index and you will see how the scripting languages take over the work

Wednesday, October 22, 2008

Frames in Lazarus

If you miss the Delphi frames now you can use them in Lazarus too if you are doing Delphi/pascal style programming

Tuesday, October 21, 2008

speeding up kernel/firebird compile on my home machines

cpu on laptop is a little bit slower (c7@1.2) so i started to use the cpu on the desktop too (athlon3000+) with the help of distcc

Here is the debian way to build the kernel with distcc

Also is good for building mozilla or other c++ programs (firebird)

The Mono team has released their better version so far, including a number of huge improvements such us .NET 2.0 compatibility (yes, generics and everything), the initial Moonlight (Silverlight for Linux) and many more.

But the best is yet to come: they already have LINQ and lambda expressions (.NET 3.5) almost there, ParallelFX (the multi-core .NET library) and totally new stuff.

When people talk about Mono, they normally focus on its compatibility with the .NET platform and how good it is for a number of companies tied to the Microsoft stack. But let me look at it from a different perspective.

[I like their new C#shell, and the fact that it works ok with firebird 2.1 on all platforms:macosx,linux,windows ]

I saw Delphi Developers Guide by Steve Teixeira and , Xavier Pacheco in an Book shop

and it is translated to Romanian language
I had tears in my eyes because I remember the days when I learned the Delphi/OOPascal/Interbase(Firebird) and all the examples are still fresh in my memory

This book I took it everywhere at school/at work /at home

Of course there are many other good books but today for me the free pascal docs are enough and the source

ps: also from the firebird conference I got the Marcu Cantu's book : Essential Pascal with his signature on it :)

Delphi/Free Pascal could be 2008 Language of the Year

It seems that Delphi Programming is an popular thing
and we must push it more (Delphi + Firebird)
check the tiobe

I wonder when i will start an kernel module in pascal :)
imagine some kernel components on the components panel

Monday, October 20, 2008

Artport an good and beautiful idea

There are not many sites in Romania where you can buy art and combines the gallery idea with the bazar one

I like the religious paintings but i will look soon on the other items

Sunday, October 19, 2008

64M of memory used for kernel crashes !

[ 0.000000] Reserving 64MB of memory at 16MB for crashkernel (System RAM: 441MB)

so you need to remove that from /boot/grub/menu.lst


Saturday, October 18, 2008

i wish the changes to ubuntu repositories to be done faster
and i think the core distro can stay unchanged a little bit longer
but some apps should and must move faster than the rest of the distro
like:openoffice , firebird 2.1, lazarus , fpc

because stable releases are already there and the intrepid is already dated at the release

also i think the gentoo ideea with continuous upgrade to be good
at least for me is better to have latest stable applications and kernel

also backports in ubuntu is completely broken so is better to use the next release or debian experimental to be up to date with all apps
building process for free pascal compiler

it's amazing how much work is done behind compiling your applications
Also this is an amazing team that progressed from an simple compiler
to an truly cross platform one (arm/x86,windows,x64,macosx,linux) and is really fast.
Howto use Lazarus 0.9.26 in Ubuntu Hardy/Intrepid
You can install the new version and you don't need to wait another 6 months to be included
in next Ubuntu release
if you have an "old" stable lazarus 0.9.24
you can install/upgrade to latest stable by using
the official lazarus repository

In my case i created an getlazarus bash script with this content

gpg --keyserver hkp:// --recv-keys 6A11800F
gpg --export 6A11800F | apt-key add -
echo "deb lazarus-stable universe" \
apt-get update
apt-get install lazarus

$chmod +x getlazarus
$sudo ./getlazarus

also you must be sure to have te fpc source so here is how i usually install

sudo apt-get install fp-units-db fp-units-gfx fp-units-gnome1 fp-units-misc fp-units-net fpc-source fp-compiler fp-docs fp-utils lazarus

then start it with
$lazarus-ide in console or from the menu
Applications -> Programming -> Lazarus

To update all free pascal related packages from the new repository (I had old fpc2.2.0 and lazarus from intrepid repository)

$sudo apt-get dist-upgrade

In my case I got this message

The following packages will be upgraded:
fp-compiler fp-docs fp-ide fp-units-base fp-units-db fp-units-fcl
fp-units-fv fp-units-gfx fp-units-gnome1 fp-units-gtk fp-units-gtk2
fp-units-misc fp-units-multimedia fp-units-net fp-units-rtl fp-utils fpc
fpc-source lazarus-doc lazarus-ide lazarus-src

What is next ? Try to use it with firebird

And seems that works without problems.

Saturday, October 11, 2008

My quote for the Firebird conference Ending

"In the early days of my career, I wondered why software engineers and their managers occasionally traveled when we had email, instant messaging, wikis and video conferencing. Gradually, I've figured out that face-to-face meetings facilitate trust, collaboration and unity more effectively.

For me, the success of this conference re-emphasizes the value of face-to-face communication."

I can repeat the same for the conference , why I went there and when i could use emails/gtalk/skype ? Maybe is another sense that we have developed and you can't trust people if you don't see them , also the communication is better when you are not in the office . My problem now is going back to normal stuff or
routine doing stuff that usually must be done it's like going from heaven to earth . Going back to daily work . Now i understand better what is the future of firebird and maybe i understand better what core developers are thinking and what is on their roadmap and maybe i can help with that.
Installing flash plugin on debian
Here is an nice howto

Testing Firebird 2.1 on Debian experimental

Testing Firebird 2.1 on Debian experimental

Update: There is now Firebird 2.5 final in experimental
also if you want 2.1 is already in testing and unstable (no need for experimental repository)

Here is my sources.list
cat /etc/apt/sources.list

deb unstable main
deb-src unstable main


deb experimental main
deb-src experimental main

# apt-get update -t experimental
# apt-get install -t experimental firebird2.1-classic
or install super-server
# apt-get install -t experimental firebird2.1-classic
Install examples and flamerobin
apt-get install -t experimental firebird2.1-examples flamerobin

follow the examples extaction procedure from this page [Scrooll down and ignore the apt sources.list lines]

With firebird2.1-classic i have this error when i try to connect to employee.fdb

Engine Code : 335544653
Engine Message :
cannot attach to password database

This is a caveat with classic server and not a bug in Flamerobin.

This is the recipe to reproduce it:
* install Debian classic-server package
* (before anything else) connect to any database using a direct path
to the database, not server:/path/to/db using any program linked
with libfbembed, for example the firebird-supplied tools (sql,
gfix etc)
- this starts the lock manager as the currently running user
(let's name it 'X', which most probably is *not* 'firebird')
* try to connect to any database either using the server:/path/to/db
connection string, or using an utility that is linked with
libfbclient (which preepends localhost: on raw connection
strings), for example flamerobin
- you can't as that utility would connect via the fb_inet_server,
which runs as user 'firebird' by default and cannot open the
lock files created by the user 'X'.

To avoid this

* always use localhost: in front of any paths. this way the lock
files and the shared memory segment will be owned by the
'firebird' user.

Testing debian installer on windows box

I had at Lechinta an wubi installer but the cpu is too slow for ntfs-ng
so i decided to install debian/ubuntu on an native partition

So i installed the debian on windows and after it finished it rebooted and started
the classic debian installer (graphic mode)

I installed the base system then i dist-upgraded to lenny (testing)
and then to sid(unstable)

Just replace etch with testing in /etc/apt/sources.list
#apt-get update ; apt-get dist-upgrade
Just replace testing with unstable in /etc/apt/sources.list
#apt-get update ; apt-get dist-upgrade

so now i have an modern distro
The space is small on this p3 machine @500Mhz so i had to install an lightweight window manager
so i installed xfce4 from command line

#apt-get install xfce4 xorg gdm
#/etc/init.d/gdm start

Then i needed an browser so i typed
#sudo apt-get install iceweasel

That is firefox3.0.x under debian , they didn't accepted mozilla firefox restrictions and EULA so they decided to name it that way

Next install synaptic and it should give you an starting point to installing packages
#sudo apt-get install synaptic

Here is how to install flash player under debian

Friday, October 10, 2008

Here is how the libdbi example should look for firebird

I have installed libdbi and libdbi-driver for firebird

Here is the example i try to test for firebird

gedit employee.c


int main() {
dbi_conn conn;
dbi_result result;

double threshold = 4.333333;
unsigned int idnumber;
const char *fullname;

conn = dbi_conn_new("firebird");

dbi_conn_set_option(conn, "host", "localhost");
dbi_conn_set_option(conn, "username", "SYSDBA");
dbi_conn_set_option(conn, "password", "masterkey");
dbi_conn_set_option(conn, "dbname",
dbi_conn_set_option(conn, "encoding", "UTF-8");

if (dbi_conn_connect(conn) < 0) {
printf("Could not connect. Please check the option settings\n");
else {
result = dbi_conn_queryf(conn, "SELECT EMP_NO, FIRST_NAME FROM EMPLOYEE");

if (result) {
while (dbi_result_next_row(result)) {
idnumber = dbi_result_get_uint(result, "ENP_NO");
fullname = dbi_result_get_string(result, "FIRST_NAME");
printf("%i. %s\n", idnumber, fullname);


return 0;

gcc -lm -ldl -ldbi employee.c

for the moment it crashes
Installing and libdbi layer for c api and libdbi-driver for firebird

I wish firebird was more simpler to use similar to dbi api for example that i use in perl world

You can see more about libdbi C api in the bacula manual

The according to libdbi ( project:
libdbi implements a database-independent abstraction layer in C,
similar to the DBI/DBD layer in Perl. Writing one generic set of code,
programmers can leverage the power of multiple databases and multiple
simultaneous database connections by using this framework.

Here is how the Firebird libdbi driver is implemented and you can see how the layer is made over the standard
firebird api

sudo apt-get install libostyle-dev libfbembed2.1 firebird2.1-dev

tar -zxvf libdbi-0.8.3.tar.gz
cd libdbi-0.8.3/
./configure --prefix=/usr
sudo make install
cd ..

tar -zxvf libdbi-drivers-0.8.3-1.tar.gz
cd libdbi-drivers-0.8.3-1/
./configure --with-firebird --with-firebird-dir=/usr --prefix=/usr --disable-docs

sudo make install
make check
libdbi-drivers test program: $Id: test_dbi.c,v 1.46 2008/02/06 16:22:44 mhoenicka Exp $
Library version: libdbi v0.8.3

libdbi driver directory? [/usr/lib/dbd]
1 drivers available: firebird
test which driver? firebird

database administrator name? SYSDBA

database administrator password? masterkey
database directory? [.] /var/lib/firebird/2.1/data

database hostname? [(blank for local socket if possible)]
database name? [libdbitest]

Driver information:
Name: firebird
Filename: /usr/lib/dbd/
Desc: Firebird/Interbase database support
Maintainer: Christian M. Stamgren
Version: dbd_firebird v0.8.3-1
Compiled: Oct 10 2008
Use CONNECT or CREATE DATABASE to specify a database
CREATE DATABASE '/var/lib/firebird/2.1/data/libdbitest';


Thursday, October 09, 2008

Compiling 2.6.27 RC9 Vanilla on Hardy - Ubuntu/Debian Way

This article is about compiling a Kernel on Ubuntu systems. It describes how to build a custom kernel using the latest unmodified kernel sources from (Vanilla Kernel) so that you are independent from the kernels supplied by your distribution.

-rc kernel patches are generated from the base stable release.

For example: to create the 2.6.27-rc9 kernel, you must:

  • download 2.6.26 (not 2.6.26.x)
  • and then apply the 2.6.27-rc9 patch.

Yes, you want 2.6.26 not 2.6.27. Remember, that's an -rc kernel, as in, 2.6.27 doesn't exist yet. :)

seems tha the kernel you want is prepatch , choose B from this area "The latest prepatch for the stable Linux kernel tree is" also choose 2.6.27-rc9 the same area.

cd /usr/src
wget --continue
tar jxvf linux-2.6.26.tar.bz2
get the patch
bunzip2 patch-2.6.27-rc9.bz2
cd linux-2.6.26
patch -p1 < ../patch-2.6.27-rc9
cd ..
mv linux-2.6.26 linux-2.6.27-rc9
cd linux-2.6.27-rc9/
cp /boot/config-`uname -r` ./.config
make menuconfig or if you want to compile old config without questions make oldconfig
make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-custom kernel_image kernel_headers cd ..
I had to disable the nvidia postinstall scripts

chmod -x /etc/kernel/postinst.d/nvidia-common

dpkg -i linux-image-2.7.27-* in my case
sudo dpkg -i linux-image-2.6.27-rc9-custom_2.6.27-rc9-custom-10.00.Custom_amd64.deb shutdown -r
now you can install the headers too from /usr/src/linux-headers-2.6.27*

If you want to build it Vanilla way without debian tools then consult this page

Miguel de Icaza Interview: Mono 2.0

GNOME founder Miguel de Icaza discusses Mono's use as an iPhone and Wii gaming engine, and "uber-awesome" features like "C## eval," in this detailed interview with

read more | digg story
dyndns setup on ubuntu
I have setup the dyndns this way

now my home computer can be visible to the outside world :)
compiling 2.6.26 vanilla on hardy - ubuntu way

This article is about compiling a kernel on Ubuntu systems. It describes how to build a custom kernel using the latest unmodified kernel sources from (vanilla kernel) so that you are independent from the kernels supplied by your distribution.

cd /usr/src
wget --continue
tar jxvf linux-
ln -s linux- linux
cd linux
cp /boot/config-`uname -r` ./.config
make menuconfig
make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-custom kernel_image kernel_headers
cd ..
dpkg -i linux-image-*
shutdown -r now

you can install the headers too from /usr/src/linux-headers-*
in my case i can show you how the packages are named
ls *.deb

Wednesday, October 08, 2008

getting/building php6 from git

time sudo git clone git://
Initialized empty Git repository in /opt/build/php-tsrm-ze2/.git/
remote: Counting objects: 378 time sudo git clone git://
Initialized empty Git repository in /opt/build/php-tsrm-ze2/.git/
remote: Counting objects: 378786, done.
remote: Compressing objects: 100% (75006/75006), done.
remote: Total 378786 (delta 302801), reused 378786 (delta 302801)
Receiving objects: 100% (378786/378786), 128.79 MiB | 1651 KiB/s, done.
Resolving deltas: 100% (302801/302801), done.
Checking out files: 100% (11007/11007), done.

real 4m35.256s
user 2m41.826s
sys 0m7.860s
786, done.
remote: Compressing objects: 100% (75006/75006), done.
remote: Total 378786 (delta 302801), reused 378786 (delta 302801)
Receiving objects: 100% (378786/378786), 128.79 MiB | 1651 KiB/s, done.
Resolving deltas: 100% (302801/302801), done.
Checking out files: 100% (11007/11007), done.

real 4m35.256s
user 2m41.826s
sys 0m7.860s

mariuz@borkstation64:/opt/build/php-tsrm-ze2$ sudo ./buildconf
using default Zend directory
buildconf: checking installation...
buildconf: autoconf version 2.61 (ok)
buildconf: Your version of autoconf likely contains buggy cache code.
Running cvsclean for you.
To avoid this, install autoconf-2.13.
rebuilding aclocal.m4
rebuilding configure
rebuilding acconfig.h
rebuilding main/
autoheader: WARNING: Using auxiliary files such as `acconfig.h', `'
autoheader: WARNING: and `', to define templates for `'
autoheader: WARNING: is deprecated and discouraged.
autoheader: WARNING: Using the third argument of `AC_DEFINE' and
autoheader: WARNING: `AC_DEFINE_UNQUOTED' allows one to define a template without
autoheader: WARNING: `acconfig.h':
autoheader: [Define if a function `main' is needed.])
autoheader: WARNING: More sophisticated templates can also be produced, see the
autoheader: WARNING: documentation.

sudo apt-get install libicu-dev

create configure script
to look this way
#! /bin/sh
# Created by configure

'./configure' \
'--disable-all' \
'--with-interbase' \
'--prefix=/opt/php5.3' \
'--disable-cgi' \
'--disable-cgi' \
'--enable-debug' \
'--enable-maintainer-zts' \

$ sudo sh

$ sudo su
#make test > out.err

inspect the out.err

install it
# make install

/opt/php5.3/bin/php -v
PHP 6.0.0-dev (cli) (built: Oct 8 2008 22:50:48) (DEBUG)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v3.0.0-dev, Copyright (c) 1998-2008 Zend Technologies

Tuesday, October 07, 2008

Firebird 2.1.x Mingw build successfully

Firebird 2.1.x Mingw build successfully

First some screnshots with the proof that it works and i will continue with the Howto

Here are the binaries that resulted from the build , You must put the icu dll in system folder

How it was done ? and why

Is painful for an open source project to require an proprietary compiler
I think all these projects could donate time and money to speed up an
good compiler and improve an common c++ IDE but this will be a future goal

Another issues is that IBM, Intel and others they sell c++ compilers
too so they are not so interested to invest too much in g++
maybe google have some interest in it who knows (to make it better)

But many other projects that they realy use mingw for their windows ports
From my head vlc inkscape and thousands of others

Milan B. told me that is possible to build firebird with mingw compiler so you
have the choice to build firebird binaries with that and release them

The official Firebird minGW build has been supported and updated many times and it started
several years ago (Blas Rodriguez, Dmitry Sibiryakov, etc). It's not
maintained as often as the official build files for Windows, but it's not
abandoned.[ED: so there is still hope]

Here is my starting point with mingw
I Downloaded mingw and msys

At mingw installer i choose G++

I started cmd.exe and then from the

I started msys.bat

I have added mingw binaries to the path


check it with echo $PATH

I downloaded Firebird 2.1.x Source Code

and unziped it in c/msys/1.0/home/mariuz$

tar -jxvf Firebird-2.1.*

now run ./configure and i waited a lot :)

I run this under wine but the steps should be the same on windows
xp for example

./configure part is [OK]
and it runs the compiling part

It stopped at the icu testing
I tried even with g++ 4.3.0 and still got some crashes with building icu
even with ones from ibm 3.8.1

here is the crash log with icu 3.8.1

Alex Told me to use the --with-system-icu option in configure

I saw that perl6/parrot is using system icu with mingw when compiling

I downloaded ICU 3.8.1 (similar to the one used in ubuntu/debian)

run cmd.exe then
mkdir c:\usr\lib

unziped the icu downloaded from here

in c:\usr\lib

export PATH=$PATH:/c/usr/lib/icu/bin:
export CPPFLAGS="$CPPFLAGS -I /c/usr/lib/icu/unicode"

run ./configure --with-system-icu --enable-superserver

it compiles but seems to ignore the CPPFLAGS

-c ../src/jrd/unicode_util.cpp -o ../temp/boot/jrd/unicode_util.o
../src/jrd/unicode_util.cpp:39:29: unicode/ustring.h: No such file or directory

quick hack was to modify after configure

make.rules in gen dir and to add to cppflags -I /c/usr/lib/icu/include
and now compilation goes on

i moved the icu/libs into /mingw/lib/

seems that is how msys expects

and continues until the linking

cannot find -licudata

I modified in

ICU_LIBS = -licuuc -licudt -licuin
and seems that compiling continues

And is this part is DONE you saw the screenshots

Here is the full thread on firebird-devel mailing list

What is next ?
I should do some QA with python
and next finish Linux-> Windows cross compiling (seems that is faster to build on linux)
make an install using scripts from builds/win32 dir

Test Cross Compiling from ubuntu with codeblocks/eclipse

Monday, October 06, 2008

installing awn in intrepid

Remove bottom pannel and let only the above one (in gnome)

Add these lines to a new file/etc/apt/sources.list.d/reacocard-awn.list

deb intrepid main
deb-src intrepid main

sudo apt-get update
sudo apt-get install avant-window-navigator-bzr awn-core-applets-bzr awn-manager-bzr


Sunday, October 05, 2008

installing openttd on ubuntu hardy

sudo apt-get install openttd

vi /usr/share/doc/openttd/README.Debian

cd ~/Desktop/Transport Tycoon Deluxe
sudo cp *.grf /usr/share/games/openttd/data
sudo cp *.cat /usr/share/games/openttd/data
cd gm/
sudo cp * /usr/share/games/openttd/gm/

$ openttd

Transport Tycoon Deluxe on wine ubuntu hardy

download the game
unzip it on desktop
run and import the registry key from zip Runme!.reg with
regedit from wine
$ regedit
and choose the import option from menu

start an terminal
cd ~/Desktop/Transport Tycoon Deluxe
wine cmd.exe
SET LANG=english
Transport Tycoon Deluxe.exe

Friday, October 03, 2008

I killed the mingw compiler with icu 3.8 or icu 3.0.x when compiling firebird 2.1.x

decimfmt.cpp: In member function `icu_3_8::UnicodeString& icu_3_8::DecimalFormat::toPattern(icu_3_8::UnicodeString&, UBool) const':
decimfmt.cpp:2966: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See for instructions.

or if you prefer

norm.cpp: In function `UNormalizationCheckResult _quickCheck(const UChar*, int32_t, UNormalizationMode, UBool, const icu_3_0::UnicodeSet*, UErrorCode*)':
unorm.cpp:3108: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See for instructions.

Seems that i need to use the icu from the system like they are using on perl6/parrot and i will see if mingw compiles firebird 2.x

Here is my shot with mingw+wine on ubuntu hardy

Thursday, October 02, 2008

HowTo boot linux in 5 seconds ,

I will add some optimizations to my everex cloudbook so it can boot faster

This is my QOD:

"We hate splash screens. By the time you see it, we want to be done." The development time that distributions spend on splash screens is much more than the Intel team spent on booting fast enough not to need one.

Wednesday, October 01, 2008

pidgin broken in hardy backports and is segfaulting

So get pidgin 2.5.1 from source

purge old pidgin from ubuntu

$sudo apt-get purge pidgin pidgin-data libpurple0

$tar -jxvf pidgin-2.5.1.tar.bz2

$./configure ; make ; sudo make install