Introduction

This page documents my experiences setting up Wine to run the NGS TOPO! program under linux.

My ultimate goal being to be able to view the National Geographic topos of California that I so bravely purchased. (Note that after this success, I have added several other sets of maps to my collection).

My California TOPO! version says it is version 2.7.6 Copyright 2002 from the National Geographic.

I first did this back in 2004 under Fedora Core 1. Today (late 2009) with Fedora Core 11, my setup still works.

One thing I never have gotten sorted out is printing topo sheets.

installing and setting up wine

Installing wine is simple. These days there is a good chance that it is already part of what gets installed on your system. If not, it should be readily available as a package, for example on a Fedora system, just do:
yum install wine.
I do what they call a "no windows" install, since I do not have windows on my machine in any shape or form (unless you count wine itself).

The first check: winemine

Type winemine at the command line. You should get a little minefield game. If this won't work, don't expect anything else to.

Textpad

I realize now that this wasn't strictly necessary, but it seemed like a good idea at the time. I went to www.textpad.com and got a trial version of textpad.
I made a directory ~/.wine/drive_c/stuff and placed the self extracting textpad.exe file in here as: ~/.wine/drive_c/stuff/txpeng473.exe and then bravely invoked wine as:

A graphical installer popped up on my screen briefly (for a couple of seconds), It labels itself as "InstallShield Wizard", and tells me it is going to install Textpad 4.7, a progress bar rattles from left to right and then I got a slew of ugly messages (for details, see textpad details

Despite all the messages, it turns out that the install actually went OK.
I look in drive_c/Program Files and I find a directory now called TextPad 4 Not only that, in that folder is a file TextPad.exe, and when I give it a try via:

something that looks a lot like textpad comes up, albeit with lots more confusing text messages. This looks like success.

TOPO!

On to the TOPO! program. The first CDROM for the California set is the installer, so I will need to set up some links for my cdrom drive and then run it, like so:

And voila, the whole setup dialog goes along just fine ... (with only 2 error messages)

And now I can invoke TOPO! by typing:

And in fact I create a little shell script wrapper that I put into ~/bin I call "topo" that looks like this:

#!/bin/sh
wine c:\\topo\!\\topo.exe

You could of course put an alias into your .bashrc or whatever, but this works for me, and now I just type "topo" to run the program, pretty cool, but I hate shoving in CDROMS, so on to the next part of the game.

TOPO! cdrom layout

This could (and just might) become a section of its own, but here is what I know so far. Each CD contains a directory named "AZ_D01" where 01 corresponds to the CD number (i.e. CD 3 contains just the directory "AZ_D03"). All the CD's except the first contain ONLY this directory. I am assuming that the extra stuff on CD 1 is what gets fiddled with during the setup phase and ignoring it in what follows. Here is what I do:

This seems to work great in the sense that I don't need to keep shoving in CDROMS as I roam around. As I look inside the AZ_D02 directory, I see directories with names D34113 - my impression (and it seems to be correct) is that this contains the map stuff for a single 1x1 degree of latitude and longitude with 34 degree latitude at the bottom and 113 degree longitude at the right edge. At last I know exactly what is on the "Kingman" CD number 2 !!

The .wine directory

This is where the action is at. In here, I have the all important drive_c directory along with the all important dosdevices directory.

My setup to run topo is now a bit different that it was before. I have a directory /u1/topo that holds all the stuff from the TOPO CD's (I used to put this in .wine, but there doesn't seem to be any reason to do that). This is useful to me because the gtopo program uses this same (large) collection of files.

My dosdevices directory looks like this:

lrwxrwxrwx 1 hank hank 10 Aug 10 13:04 c: -> ../drive_c
lrwxrwxrwx 1 hank hank  8 Aug 10 13:08 d: -> /u1/topo
lrwxrwxrwx 1 hank hank 10 Aug 10 13:09 e: -> /mnt/cdrom
lrwxrwxrwx 1 hank hank 10 Aug 10 13:09 e:: -> /dev/cdrom
lrwxrwxrwx 1 hank hank 17 Aug 10 13:39 t: -> /u1/topo/az_disk1
lrwxrwxrwx 1 hank hank  1 Aug 10 13:04 z: -> /

Notice the t: link. /u1/topo/az_disk1 is the contents of the first disk for arizona, minus the AZ_D01 directory (which just sits in /u1/topo/AZ_D01). This little wad of stuff (about 37 Megabytes) is sufficient to install TOPO via:

  • wine "t:\setup.exe"

  • Have any comments? Questions? Drop me a line!

    Adventures in Computing / tom@mmto.org