Page 1 of 1

Building MegaTunix On Debian/Ubuntu

Posted: Sun Mar 11, 2012 3:40 pm
by Fred
If you don't have instructions to do this, then it's quite painful because you have to run the configure script repeatedly and install one package at a time. So, I present to you today, some instructions so that this may be easy for the next person. This thread will likely get superceded by the quick start script fairly soon, however it can be used to put content into that script, so it's not in vein.

Before you start, update your apt cache like this:

Code: Select all

sudo apt-get update
First you need to get git! If you already have git, obviously you should skip this step.

Code: Select all

sudo apt-get install git
Note, if you have an old system you may need to use this command instead:

Code: Select all

sudo apt-get install git-core
Then you need to clone the source, choose or make a directory, such as "~/workspaces/freeems/" and do this inside it:

Code: Select all

mkdir -p ~/workspaces/freeems
cd ~/workspaces/freeems/
git clone <url from following thread>
You can get the git clone URL from the Recommended Versions Of All Software thread.

Then you need to get the prerequisite libraries of MTX, there are quite a few, I'll list them, then provide a single apt-get line:
  • autoconf
  • libtool
  • intltool
  • flex
  • bison
  • libpango1.0-dev
  • libglade2-dev
  • libgtkglext1-dev
  • g++
Everything else is pulled in transitively, so just run this command:

Code: Select all

sudo apt-get install autoconf libtool intltool flex bison libpango1.0-dev libglade2-dev libgtkglext1-dev g++
At this point you're ready to build, do these steps one by one:

Code: Select all

cd ~/workspaces/freeems/MegaTunix/
./autogen.sh
make
sudo make install
sudo ldconfig
MegaTunix is now installed on your system, so all you need to do to run it is this:

Code: Select all

megatunix
However you'll likely find it convenient to do this instead:

Code: Select all

megatunix -p FreeEMS -P /dev/ttyUSB0
The above build sequence assumes that the application will work flawlessly, which is sometimes not true. If you have trouble, make sure you can reproduce it, then rebuild like this:

Code: Select all

cd ~/workspaces/freeems/MegaTunix/
make clean
./autogen.sh --enable-debug
make
sudo make install
Now run it a little differently by following these steps:

Code: Select all

cd ~/workspaces/freeems/MegaTunix/src/
gdb .libs/megatunix
run --g-fatal-warnings <options you use normally>
Record the actions required to generate the fault exactly, and any info about the application such as a screen shot of it when frozen, the git hash you were using, etc and file an issue report on the tracker using this guide.

If you've already cloned the MegaTunix git repository, to update it do this:

Code: Select all

cd ~/workspaces/freeems/MegaTunix/
make clean
git pull
And then build it as per the instructions above.

Tested OK 11th Feb 2013 on hash 8991b6ee98ac4bddd4bd67396968e1989014f15e

I hope that gets you up and running with MegaTunix quickly and easily.

Fred.

Re: Building MegaTunix On Debian/Ubuntu

Posted: Sun Apr 19, 2015 1:39 pm
by Fred
Add this to deps list for deb/ubuntu: libgtkgl2.0-dev
run ldconfig after install before it'll work.

Tested OK on 20th April 2015 with 0.9.24-SNAPSHOT-1373-ga39831b