How to build Amap from source, for Windows XP, using Cygwin

Here's a rough guide to building Amap 5.2 from source code for windows users. I've been playing with this rather old tool recently and noticed that the web update functionality is broken due to a change of location for the update files. I decided to patch the source and thought it might be helpful to knock-up a quick build guide in the process. If you have any issues with any of the steps herein, mail me (jah) and let me know.

Install Cygwin.

On top of the default cygwin installation, you'll need to install the following packages (selecting these will add other required packages):

"Utils/diffutils" diffutils-2.8.7-1.tar.bz2
"Devel,Libs/openssl" openssl-0.9.8g-1.tar.bz2
"Devel,Libs/openssl-devel" openssl-devel-0.9.8g-1.tar.bz2
"Devel/gcc-core" gcc-core-3.4.4-3.tar.bz2
"Devel/make" make-3.81-2.tar.bz2

If you intend to patch the source code as described below you'll need:

"Utils/patch" patch-2.5.8-9.tar.bz2

Get AMAP source code and patch it.

Download http://freeworld.thc.org/releases/amap-5.2.tar.gz
Download amap.h.patch.txt
Copy these into C:\Cygwin\home\<Username> where username is your Cygwin username
Fire-up the Cygwin shell and unpack the AMAP source code:
$ tar -zxvf amap-5.2.tar.gz
$ cd amap-5.2/
$ cp ../amap.h.patch .
$ patch -p0 -u -i amap.h.patch

Build AMAP source

$ ./configure
$ make

Create a folder to hold the compiled amap files:

$ mkdir amap-5.2
$ cd amap-5.2/
$ cp ../amap.exe .
$ cp ../amapcrap.exe .
$ cp ../README README.TXT
$ cp ../appdefs.trig .
$ cp ../appdefs.rpc .
$ cp ../appdefs.resp .
$ cp /bin/cygwin1.dll .
$ cp /bin/cygssl-0.9.8.dll .
$ cp /bin/cygcrypto-0.9.8.dll .
$ ln -s amap amap6
$ cd ..
$ logout

Update the trigger and response files

Open a Windows Command Prompt and:

> cd \Cygwin\home\<Username>\amap-5.2\amap-5.2
> amap -W -D ./appdef

That's it! The folder at \Cygwin\home\<Username>\amap-5.2\amap-5.2 now contains all you need to run amap on Windows and can be moved to wherever you see fit.

Leave a comment

Recent Entries

  • Is The Internet On?

    The following is a link to an invaluable resource which will tell you ["whether or not the Internet is On":http://jahboite.co.uk/is-the-internet-on.php].......

  • How To Enable the PHP Fileinfo Extension under Windows

    These five steps will hopefully help you to enable the Fileinfo extension for PHP under Windows....

  • The TCP/IP Guide - Greasemonkey Userscript

    jah has written a greasemonkey userscript to fix the page layout for The TCP/IP Guide free online edition - it's very simple, but it took him ages!...

  • PicaVue

    jah has begun work on an open source javascript gallery to display his Picasa Web Albums - it's called PicaVue...

  • Nmap 5 - An Introduction

    The newest version of Nmap - Nmap 5.00 - is now available for download and is the best Nmap ever. This is a short introduction to Nmap and the Nmap family of tools: Zenmap; Ncat and Ndiff which are included with this latest release....

  • Enable apache mod_userdir on Debian

    How to enable mod_userdir for apache2 on Debian 5.0 (Lenny)....