Saturday, 3 November 2007

Insufficient Disk Space reported under wine

Did you try to install/setup any Windows Application - actually a Game what else could be necessary - and got a message that you do not have enough free space on your drive meanwhile you had lot of free space on the chosen mounted partition?
You will learn the problem and hopefully the solution too. (Of course I suppose it is not the real situation you have no enough space. If so do not read ahead.)

The problem is that wine does not check the amount of free space on the mounted partition corresponds to the selected directory but reports the free on the root of the directory the partition mounted to . ;( Probably it is not clean so here is an example:
Let say you have / only and something is mounted as /mnt/part1
If you directly select /mnt/part1 during installation wine will check free space in fact on / and does not calculate free on the partition mounted under /mnt/part1.

How to solve it you may ask? It is easy. Start winecfg and create a new drive with the directory you want to use.

Keywords: Wine Insufficient free space not enough free space on drive

Thursday, 27 September 2007

Ubuntu Gutsy 64bit Wine misses ssl support so Google Picasa can not sign in.

Today I have realized that Picasa - I am using "windows version" of picasa under wine - can not sign me in - means no web upload is possible - from my home machine (Ubuntu Gutsy 64bit) and wine showed the following error:

fixme:win:FlashWindowEx 0x33afd4
fixme:wininet:InternetSetOptionW Option INTERNET_OPTION_CONNECT_TIMEOUT (10000): STUB
fixme:wininet:InternetSetOptionW INTERNET_OPTION_SEND/RECEIVE_TIMEOUT not supported on protocol 1
fixme:wininet:NETCON_init can't use SSL, not compiled in.

I was a bit surprised since Picasa on my office notebook (Ubuntu Feisty 32bit) worked fine. So checked the error and decided to recompile wine and see if ssl is really not compiled in.

First I downloaded the source and dependencies needed to compile.

# apt-get build-dep wine

I would mention that it will download a lot.
Then downloaded wine source too into a temporary directory and tried to compile.

# mkdir /tmp/wine_build
# cd /tmp/wine_build
# apt-get source wine
cd wine-0.9.45
dpkg-buildpackage -rfakeroot -b

And part of the result is:

checking for -lcapi20... not found [ CAPI support ISDN Cards ]
checking for -lcups... not found [ CUPS printing support ]
checking for -ljack... not found [ Jack audio server support ]
checking for -lssl... not found
checking for -lcrypto... not found
checking for -ljpeg... not found
checking for -lpng... not found

So configure could not find ssl library. After some check it turned out that this is a 32 bit compilation therefore it needs 32 bit libraries. And of course I did not have some 32 bit lib on my system. My current problem is the access of internet because of the missing ssl support so now focus on this.

I have downloaded libssl0.9.8_0.9.8e-5ubuntu1_i386.deb and extracted this and copied the missing files to the right place and created required soft links.
# mkdir /tmp/libssl
# dpkg -x libssl0.9.8_0.9.8e-5ubuntu1_i386.deb /tmp/libssl
# cp /tmp/libssl/usr/lib/ /usr/lib32/
# cp /tmp/libssl/usr/lib/ /usr/lib32/
# ln -s /usr/lib32/ /usr/lib32/
# ln -s /usr/lib32/ /usr/lib32/

If you try to compile wine again with dpkg-buildpackage -rfakeroot -b this should work now.

[ Update: It took a long time on my machine. :( But finally it is working. :) ]

[ Update: I saw sadly that some fonts are not visible under Picasa. Hmmm. Not easy to get it to work. But it can be. If you have font problem install msttcorefonts. But that is not all you have to do. After that you have to remove your ~/.wine directory and reinstall Picasa. The important thing is not Picasa reinstallation. But when wine does not find a ~/.wine it recreates and this is the point after all. I'll try to find another way to do this but this is working. ]

[ Update: Tried to start EVE Online under wine and found two problems. Both were discussed on wine web page but here are details.
Main error is below but first solve the easier one:
$ cp /usr/share/fonts/truetype/msttcorefonts/arial.ttf ~/.wine/drive_c/windows/fonts/

Main error message:
fixme:d3d_draw:drawPrimitive Using software emulation because not all material properties could be tracked
Still do not know really how to solve this.]

P.S. :
As you could see some other libraries are missing too. So if you have a similar problem just do a procedure like this and you can correct it.

The following libraries were also missing:
checking for -lcapi20... not found
checking for -lcups... not found
checking for -ljack... not found
checking for -lssl... not found
checking for -lcrypto... not found
checking for -ljpeg... not found
checking for -lpng... not found

The followings are also missing so in case of problem with wine on 64 bit linux you should consider this list:
checking for IceConnectionNumber in -lICE... no
checking for x86_64-linux-gnu-ar... no
checking for x86_64-linux-gnu-ranlib... no
checking for x86_64-linux-gnu-strip... no
checking for x86_64-linux-gnu-windres... no
checking for windres... no
checking for lclint... no
checking for lint... no
checking for i386_set_ldt in -li386... no
checking for _oss_ioctl in -lossaudio... no
checking AudioUnit/AudioUnit.h usability... no
checking AudioUnit/AudioUnit.h presence... no
checking for AudioUnit/AudioUnit.h... no
checking Carbon/Carbon.h usability... no
checking Carbon/Carbon.h presence... no
checking for Carbon/Carbon.h... no
checking CoreAudio/CoreAudio.h usability... no
checking CoreAudio/CoreAudio.h presence... no
checking for CoreAudio/CoreAudio.h... no
checking DiskArbitration/DiskArbitration.h usability... no
checking DiskArbitration/DiskArbitration.h presence... no

Monday, 24 September 2007

Line6 PodXT Linux Driver 0.7.2 is incompatible with kernel >= 2.6.22

I have updated my Ubuntu Feisty to Gutsy some weeks ago because of a problem booting up from raid. Upgrade solved the issue but brought some others. One of the most serious to me was that the Linux Line6 PodXt driver
could not be compiled anymore. The error I got was:

make default

make -C /lib/modules/2.6.22-12-generic/build
SUBDIRS=/home/user1/workspace/line6usb-0.7.2 modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.22-12-generic'
CC [M] /home/user1/workspace/line6usb-0.7.2/pcm.o
/home/user1/workspace/line6usb-0.7.2/pcm.c: In function
/home/user1/workspace/line6usb-0.7.2/pcm.c:40: warning: implicit
declaration of function ‘snd_pcm_group_for_each’
/home/user1/workspace/line6usb-0.7.2/pcm.c:40: error: expected ‘;’
before ‘{’ token
/home/user1/workspace/line6usb-0.7.2/pcm.c:33: warning: unused variable
/home/user1/workspace/line6usb-0.7.2/pcm.c:32: warning: unused variable
make[2]: *** [/home/user1/workspace/line6usb-0.7.2/pcm.o] Error 1
make[1]: Leaving directory `/usr/src/linux-headers-2.6.22-12-generic'
make[1]: *** [_module_/home/user1/workspace/line6usb-0.7.2] Error 2
make: *** [default] Error 2

So I investigated this a bit and found that some macro calls were obsoleted which is why pcm.c can not be compiled on 2.6.22 - actually neither on 2.6.21 and 2.6.20 is the latest working.
Fortunately this was very easy to correct this error. OK first I had to check kernel changelog and also Linux Cross Reference helped me a lot.
So here is the required modification in pcm.c of the driver to be able to compile the source again.

/* trigger callback */
int snd_pod_trigger(struct snd_pcm_substream *substream, int cmd)
struct snd_pod_pcm *chip = snd_pcm_substream_chip(substream);
struct list_head *pos;
struct snd_pcm_substream *s;
int err;
unsigned long flags;

printk(KERN_INFO "*** Entering snd_pod_trigger\n");
spin_lock_irqsave(&chip->lock_trigger, flags);
clear_bit(BIT_PREPARED, &chip->flags);

//snd_pcm_group_for_each(pos, substream) {
list_for_each(pos,&substream->group->substreams) {
//s = snd_pcm_group_substream_entry(pos);
s = list_entry(pos,struct snd_pcm_substream,link_list);

switch(s->stream) {

Just change the lines so old ones are commented out and below are the new ones:

//snd_pcm_group_for_each(pos, substream) {
list_for_each(pos,&substream->group->substreams) {
//s = snd_pcm_group_substream_entry(pos);
s = list_entry(pos,struct snd_pcm_substream,link_list);

As soon as I have a bit more free time I will make a patch - a diff - to apply.

This error was reported via sourceforge and I am pretty sure we can see a corrected version soon officially from Marcus Grabner. But till then you can do it on your own easily.

P.S. : I would like to say thanks to Marcus Grabner for the driver.

[Update] The patch can be downloaded from here or from here. First save it into your home directory. Download the driver also into your home than execute the following commands (I suppose that line6usb-0.7.2.tar.bz2 and line6usb-0.7.2_patch.diff are saved into your home) :
$ cd ~
$ bzip2 -dc line6usb-0.7.2.tar.bz2 | tar xfv -
$ cd ~/line
$ patch -p1 <~/line6usb-0.7.2_patch.diff That is all. Hope it works.