Posts Tagged ‘Malayalam’

Installing English – Malayalam Dictionary on Arch linux

Saturday, September 12th, 2009

From a discussion on ilug-tvm mailinglist

Prerequisites : yaourt should be installed

Installing the server

Step 1: Issue the following command on a terminal and answer whatever questions may pop up. This will install the dictd server to your system: yaourt -S dict-freedict-eng-mal

Step 2: start the dictd server by issuing the following command :
* If you have sudo installed , then : sudo /etc/rc.d/dictd start
* else become super user by typing in su at a terminal and inputting the super user password . Now run /etc/rc.d/dictd start

Step 3 [ optional ] : If you wish to use the server quiet frequently, you might want to have it running always.  For that, add dictd to the end of DAEMONS list in your rc.cof

eg: (syslog-ng dbus hal @cpufreq @net-profiles @network @netfs @crond alsa @sshd @dictd)

The @ makes your process startup in backround and init wont wait for the startup to complete before proceeding .

Installing the client :

I use a client called dikt. I installed it by issueing the following command  : yaourt -S dikt. Once this is complete, startup dikt. Click on Settings>Configure Dikt. In the window that pops up , you can add your own dict servers. Just type in ‘localhost’  and add it to the servers list. It will be better if you can move the dict.org entry or  you can remove the dict.org entry if you will be using only English-Malayalam dictionary. Now you can start using dikt to lookup words.

I know the whole thing looks a little tedious, but this is what i did ,  and it works :)

Malayalam using scim on Mandriva 2009 and 2009 Spring

Tuesday, February 3rd, 2009

Enabling Malayalam on Mandriva Linux 2009 is slightly different from Mandriva 2008 . I am using an installation from  Mandriva One 2009 KDE version disc

This is how you do it :

Download and install latest Meera and Rachana from
http://download.savannah.gnu.org/releases/smc/fonts/malayalam-fonts-04/ .
Installing involves right clicking on the file and choosing actions->install. ( This is with KDE, something similar should be there on GNOME )

  1. Invoke the Mandriva Control Centre [ Menu->Tools->System Tools->Configure your Computer ] choose Software Management -> ‘Install & Remove Software ‘
  2. There are two drop down lists on the top left , choose ‘All’ in both .
  3. Search for scim-tables-ml and select it.
  4. Accept the dependencies. It will also ask you to choose from scim-, scim-bridge, and skim. Just choose scim
  5. Click on Apply.
  6. Invoke the Mandriva Control Centre [ Menu->Tools->System Tools->Configureyour Computer ] choose System->’Manage localization for your System’ . Now choose Malayalam in the Window that shows up. Click next and carry on with the default choices to complete the wizard. When the last Ok button is clicked, it will present you with a logout/restart/shudown window. Click logout.
  7. Log in now
  8. Open up a terminal ( ALT+F2 invokes a run dialogue and then type in ’konsole’  (without quotes) in it and press enter )
  9. Type in ‘su -’  (without quotes)  and enter your root password when prompted.
  10. Now run ‘kwrite /etc/sysconfig/i18n’ (without quotes)
  11. Add the following text to its end

GTK_IM_MODULE=scim
XIM_PROGRAM=”scim -d”
QT_IM_MODULE=scim
XMODIFIERS=@im=SCIM

Now  Logout and log back in.

The scim icon should be there in the system tray and you should be able to type in Malayalam anywhere now, just by pressing Control+Spac and choosing Swanalekha/inscript  from the input method list that pops up.

English-Malayalam Dictionary beta release for Arch Linux

Sunday, January 18th, 2009

SMC released an English-Malayalam Dictionary for dict servers. I have made a package so any Arch – Malayalam (!!!)  users out there can use it. You can get the PKGBUILD from AUR.  If you have yaourt installed, you just have to run
yaourt -S dict-freedict-eng-mal
in a terminal.

I have also built a package that is available here. You can download and install it using
pacman -U dict-freedict-eng-mal-0.1-2-i686.pkg.tar.gz

How I got Malayalam input working in Arch.

Thursday, January 8th, 2009

I installed Arch. The setup is neat and I like it so very much , I am going to keep this for a while ( thats all I can say because my friends know me as a distro hopper ). Only one thing bugged me. I could’nt get Malayalam input methods working. Even though I tried copying Santhosh’s swanalekha m17 script, it didnt work properly. Yesterday I had a chat with Santhosh and he asked me to check the m17 version. On a whim , I checked scim-tables version too. It was 0.5.7 and scim-tables 0.5.8 contains Swanalekha. So I thought, why not try building it. I installed the Arch Build System ( pacman -Ss abs ). Running abs as root got all the build scripts that are used to build the distro into my system.

Now comes the actual package build part. I went digging into the tree that abs created in /var/abs. Thanks to the locate command, i found where scim-table package’s script resides. This build script, named PKGBUILD is an awesome piece. The makepkg program uses this script to create an Arch package. If you write this script properly, the package creation process is a breeze. It has all the information needed to get and build a package from source – its version,download URL, dependencies, build time dependencies, and md5 to verify if the downloaded package is corrupted and a lot more information. It also contains a function called build() which is called by makepkg to compile the package.

What i had to do was copy the PKGBUILD corresponding to scim-tables to an empty directory ( a work area ) of my choice, change the package version number from 0.5.7 to 0.5.8 and change the md5 sum to the one corresponding to v0.5.8 source tarball. Thats it .. or so it seemed, until I ran makepkg and I saw the build failing.

Now, what goes on during the build is simple. makepkg parses the PKGBUILD and uses the source found in it to get the source tarball. Then it extracts it to a sub directory called src and calls build(). The build(0 function usually contains the standard ./configure , make and make install ( to a sub directory called pkg in the work area directoy, not to the system directories ).

The build failed during make. This was shitty. I googled the error and found that a bug was filed against it in Debian tracker ( build fail ). Santhosh appeared online right then, and he asked me to go check Debian’s sources. And voila ! there was a patch !. But that patch contained a lot lot more other patches. So I checked what the patch did. It was just changing <string> to <cstring> in a source header. So I made the change and took a diff ( I used Kompare to do this. I like GUIs ).

Now i need to stick the diff file in the PKGBUILD script somehow so I can run patch inside the build() function just before ./configure. So I went to the Arch Package Making wiki. It said that I can just put the diff ( or any other file I want to use during build ) along with the PKGBUILD script and then refer to it from inside the script. I did so and added a line to patch the source file just before running the configure script.

Now I ran makepkg again, and Voila ! there it is. The shiny new scim-tables-0.5.8 package. I installed it ( pacman -U pkgname)

അതു കഴിഞ്ഞു സന്തോഷിന്റടുത്ത് മൊട കാണിച്ചു കഴിഞ്ഞപ്പൊഴേ സമാധാനമായുള്ളൂ. All this took around half an hour. I am loving it :D

The build script and patch I used are here.