Currently, on Ubuntu 16.04 or 14.04, if we want to mailing photos from Picasa 3.9 in Thunderbird 52, new mail pop-up but missing photos attached. This is an old bug. There was a work-around with a script but no longer working with Picasa 3.9 and Thunderbird 52. It's very annoying, because old people using Picasa and Thunderbird really need to send their photos with Picasa and Thunderbird. Picasa 3.9 installed with wine and works fine. How to mailing photos with Picasa 3.9 and Thunderbird 52?

Send photos by email with Picasa:

How to send photos by email with Picasa


I assume that the picasa-hook-email.sh script is no longer used by Picasa 3.9 and is never invoked. Instead it most probably relies on the MAPI interface to send e-mails. The wine implementation of this interface however does not support attachments. It converts any request to send an e-mail into a mailto:-URL and this does not support attachments.

I'm now just starting to modify the MAPI in wine to use a direct call to Thunderbird using the -compose option. Let's see whether I'm successful, but stay tuned! I will inform you about my success (or failure) here.

For the wine MAPI source code see here: https://source.winehq.org/source/dlls/winemapi/sendmail.c. Look at line 157ff: attachments are explicitly ignored.

Two days later: yes, it works!

What I did:

  • I patched the sendmail.c source file to directly invoke Thunderbird instead of creating a mailto:-URL
  • I used the openSUSE Build Service to branch the official wine package and added the patch there
  • I downloaded the created package, extracted winemapi.dll.so and put it to the correct location.

But step by step. First have a look at https://build.opensuse.org/package/show/home:letsfindaway:branches:openSUSE:Leap:15.0/wine. This is where the branch is located. Everything is untouched, just the sendmail-thunderbird.patch was added and referenced in the wine.spec build file. You may have a look at the patch and apply it to the original source to see what I have changed.

The builds themselves can be found when you click on "standard" below "wine" on the right hand side or directly there: https://build.opensuse.org/package/binaries/home:letsfindaway:branches:openSUSE:Leap:15.0/wine/standard. Are you using a 64-bit wine or a 32-bit wine running in a 64-bit environment? Depending on that download one of the following files:

  • wine-3.7-lp150.<n>.1.x86_64.rpm for 64-bit wine
  • wine-32bit-3.7-lp150.<n>.1.x86_64.rpm for 32-bit wine running in a 64-bit environment
  • wine-3.7-lp150.<n>.1.i586.rpm for 32-bit wine running in a 32-bit environment

The number <n> is incremented each time I trigger a rebuild. Currently it should be "10".

Then extract the file /usr/lib/wine/winemapi.dll.so from the rpm package file. Under Linux, most graphical archivers should be able to open the file. So it does not matter whether you're using openSUSE as I do. Even if you're using Ubuntu or any other distribution you should be able to extract that file.

It also (nearly) does not matter which wine version you're using. The sendmail.c source file was not touched since wine 1.6.

Now place that file in the corresponding location of your wine installation. Just to be sure rename the original file first, so that you still have it. If you're using PlayOnLinux, then you might have more than one wine installation, located below ~/.PlayOnLinux/wine/. Be sure to do the replacement in the correct location!

The patch will not only affect Picasa, but any program using the MAPI to send e-mails. And it will of course never become an official patch, as it only works, when Thunderbird is installed as /usr/bin/thunderbird.


  • This patch enables the "send e-mail" function in Picasa when running under wine and when using Thunderbird as the mail program.
  • It works for a broad range of wine versions starting from 1.6 and almost any 32-bit or 64-bit Linux installation.
  • Make sure that Thunderbird is installed as /usr/bin/thunderbird.
  • Extract the correct version of winemapi.dll.so from one of the archives mentioned above and use it to substitute the official version.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.