Compiling Wine on the Raspberry Pi – Compiling the Kernel and Next Steps

It took me days to recompile the kernel for the Raspberry Pi. If you’ll remember from my last post, I was attempting to recompile the Ubuntu Mate kernel in order to remap the memory split to be 3G/1G user/kernel in order to be compatible with Wine’s memory mapping. I ran into many troubles while seeking to recompile the kernel that I will go over here.

The Raspberry Pi has one gigabyte of on-board RAM. Cloning the Ubuntu kernel source repository using git on a Raspberry Pi uses more than the one gigabyte window. In order to pull down the source to compile it, I had to reconfigure a spare USB external hard disk as a swap partition. This allowed me to pull down the source and begin the kernel configuration process.

The kernel was easy enough to configure, I noticed that the 3G/1G user/kernel configuration setting was set by default, so I was puzzled as to why it got turned off on my particular build. Then compiling the configured kernel takes hours. I’d sleep on it, and find out I hadn’t installed OpenSSL development files. I’d sleep on it again, and then I would discover another development library I had failed to consider. Finally I got my kernel recompiled and installed on my Raspberry Pi. Wouldn’t you know it, the Wine error remains; it appears that maybe my original kernel was configured correctly all along. I’m going to have to dig deeper on this one to figure out what can be done.

For now though I intend to return to generating and posting game reviews. I still want to pursue the idea of making a single board computer a universal gaming platform, but there is so much work that really should be done in building out the Bunny Gamer site and documenting the games in my game collection for the time being.

Compiling Wine on the Raspberry Pi – Making the Build and First Test

Before I went to sleep last night I ran the make command to compile the development version of Wine 2.12 from source. Understandably, the compilation took quite a lot of time. After spending two hours periodically glancing at it, I decided to just go to sleep. I woke up to a Raspberry Pi with a fully compiled version of Wine with no errors or warnings! I was excited the whole day I was at work wishing I could just be home to test an actual Windows game on my Raspberry Pi.

After finally getting home and attending to all of the urgent errands on my list for the day, I downloaded The Longest Journey from and attempted to run the setup utility on my Raspberry Pi system. It was then that I received an error I have never encountered in my history of using Wine.

Warning: memory above 0x80000000 doesn’t seem to be accessible.
Wine requires a 3G/1G user/kernel memory split to work properly.

My first thought was, “Since when does Wine require 4 GB of RAM? I’m going to need an external hard drive for some super slow swap space.” As I sat contemplating my dilemma, I decided to research the error to see how others handled it. Apparently this error has nothing to do with the amount of memory you have, but instead how it is handled by the kernel. When compiling the kernel, there are around four different ways to configure the allocation of memory between the user and the kernel. From what I have been reading it seems Ubuntu Mate’s default kernel is allocated 2G/2G.

Therefore, it appears it is time for me to reconfigure and recompile my kernel. Stepping through kernel recompilation instructions on the Ubuntu BuildYourOwnKernel Wiki, I have found significant differences in their instructions and how the Raspberry Pi kernel is actually configured. Over the next day I will attempt to recompile my own kernel and then post supplemental instructions to those who may have difficulty recompiling their Raspberry Pi Linux kernel and to my future self should I have to do this again.

Compiling Wine on the Raspberry Pi – Initial Attempt, the Configuration Script

Yesterday I used colorful words to convey my assumption that very little work has been done in the area of getting the free software program Wine to work on the Raspberry Pi platform. Boy was I wrong. I downloaded the version 2.12 release of the development source and ran the configuration script. I was greeted with a few errors for lack of dependencies, but they were the same errors I have received in the past when compiling on an x86 or x64 machine.

Once I had those dependencies installed, the configuration script completed successfully, but recommended several packages that would make a compiled instance of Wine more functional and enjoyable to use. I will list those packages here for those who wish to compile their own version of Wine for the Raspberry Pi using Ubuntu Mate 16.04.2. After I had those packages installed, I ran the configuration script one more time with no issue. It is remarkable how many libraries have been ported over for the armhf architecture. This almost seems too easy. I checked for an actual Wine binary in the Ubuntu package repository using Synaptic Package Manager. Wine-Development, libwine-development, wine-mono0.0.08, wine32-development, and winetricks are available in the repository, but the actual Wine runtime binary is not.

I will continue my attempt to compile the Wine development snapshot 2.12 on the Raspberry Pi and will report my progress. As promised, here are the suggested libraries and their current Ubuntu 16.04.2 packages.

libjpeg – libjpeg-dev
libgnutls – libgnutls-dev
libxslt – libxslt1-dev
libxml2 – libxml2-dev
libldap – libldap2-dev
libopenal – libopenal-dev
libmpg123 – libmpg123-dev
libtiff – libtiff5-dev
libgsm – libgsm1-dev
libcups – libcups2-dev
libcapi20 – libcapi20-dev
libudev – libudev-dev
gstreamer-1.0 – libgstreamer1.0-dev
libpulse – libpulse-dev
liblcms2 – liblcms2-dev
libgphoto2_port – libgphoto2-port12
libgphoto2 – libgphoto2-dev
libv4l – libv4l-dev
libsane – libsane-dev
lib(n)curses – libncurses5-dev
libdbus – libdbus-1-dev
pcap – libpcap-dev
OpenCL – ocl-icd-opencl-dev
libOSMesa – libosmesa6-dev
libGLU – libglu1-mesa-dev
libxcomposite – libxcomposite-dev
libxinerama – libxinerama-dev
libxfixes – libxfixes-dev
libxrandr – libxrandr-dev
libXxf86vm – libxxf86vm-dev
XShape – libxcb-shape0-dev
XShm – libxshmfence-dev
libxi – libxi-dev
libxcursor – libxcursor-dev

First Scrum

A little bit of a site update. I got sick, and then got busy, and then lost track of time. Here it is nearly a week since I last posted anything. I have decided therefore that I will be posting each day to keep my mind focused on keeping this site going. It has always been a dream of mine to host a gaming site, and I refuse to let it go by the wayside simply because I lose track of time.

It is my intention to publish a daily post of what I have been working on and what I am planning on working on each and every day. This daily post is more for my own purposes, to keep me focused on building the kind of site I wish to have. You could almost think of it as a public scrum to myself. It’s not necessary for anyone else to read; I won’t link to these daily posts from social media.

But these posts will give a reader, me included, some insight into the incremental thoughts that lead me to each planned iteration of every Bunny Gamer project. Each project will get me closer to delivering the kind of site that will help myself and gamers like me more easily find and play games. The original intent of the Bunny Gamer site is two-fold. To provide a database of game reviews that document the original platform, format, single and multi-player options, rules, and relative fun provided by each game in my collection. And to provide information on compatibility – how well does this game play on newer, various systems or how can I get this game to work on a newer or different kind of system.

When I first began seriously collecting games, DOS was the operating system that was compatible with the most games. Around five years later, it was Windows 98. Another ten years after that, it was Windows XP. It was at that point that I began to sort all of my games into a database and keep track of their stats. I figured the next Windows operating system would be the most compatible gaming operating system, with Windows XP being at least a fall-back. Now with Windows 10, and for most versions of Windows 7, there isn’t a lot of good compatibility for older games natively. I have been impressed, however, with the quality of Linux when it comes to playing games in recent years and Valve’s support through the Steam platform to ensure there are many games represented on Linux. The Wine program for Linux also provides an open, free software platform for potentially running any other game that might fall through the cracks.

The most impressive piece of game compatibility hardware I have used lately though is the Raspberry Pi. I set one up with a RetroPie install. Immediately after the initial install I was able to play NES, SNES, Genesis, Game Boy, Atari 2600, and Game Gear games. I attempted to play N64 games, but they were a little too laggy to play. I’m going to research further to see if it is possible to get the N64 games performing well enough to play. If I can get all of my games from prior to the end of the N64 era working on my Raspberry Pi, then it seems possible a single board computer could play around 30 years of gaming history, right from the television screen in my den.

What would really be impressive would be to get Wine working on the Raspberry Pi. I have been lurking in the Wine development forums and have been reading about some people trying to get help compiling the Wine source on the ARM architecture. I would imagine someone on the other end rolling their eyes if I were to send out such an email, but it’s got wheels turning in my head. My plan for tomorrow is to pull down the latest development snapshot of Wine on a fresh instance of Ubuntu Mate running on my Raspberry Pi. I will attempt to compile the source and see how many and what kind of errors I receive.