Article:
|
http://picasaweb.google.com/robinwmills/GPSTesting | ||||||||||||||
And the solution is platform independent. I've written it in Python. It requires quite a collection of software to make this work including:
That's quite a list to get started! If you don't want to be bothered downloading and building all this stuff, I've got good news. You can download the libraries from this site. I've built it for Mac OS X (Universal binaries for 10.4 and up) and Windows (XP and up), and Linux. Unix guys - you'll have to build your own libraries. However the Python script should work fine. To download the libraries, please see box at top of page. | |||||||||||||||
Article | |||||||||||||||
AcknowledgementsBefore launching into the details here, I'd like to thank somebody who's made it possible to do this work. Olivier Tilloy wrote the python wrapper for libexiv2. I've enjoyed email correspondence with Olivier and he has been very encouraging of my efforts. Andreas Huggel is the author of libexiv2 and of course he's made it possible for Olivier to do his part. I've spoken to Andreas about this and he has also been very helpful. I'd like to thank Rob Wallace in New Zealand for cooperating in the preparation of the windows notes. Rob was especially helpful in the development of the cross-plaform SConscript file required for pyexiv2. Thank you, Rob. I believe I haven't needed to even look at a line of code written by Olivier or Andreas - everything just builds and works fine. Well the build isn't a lot of fun - however it does build on Mac OS X, Windows and Linux. And I've also had some help from Frank and Stani and Anders. Open Source Warriors. Thanks guys. About the Python CodeThe python code's here: click here. I hope you'll find the code clear and obvious. There are several things which happen:
And that's the story. I hope you find this useful. Send me your bug reports! Building the libraries on Mac OS XSeparate document: click here. Building the libraries on WindowsSeparate document: click here. Building the libraries on LinuxI built this on the Hardy Heron distribution of Ubuntu (8.0.4). I didn't find it as easy to build as described on the Development web site: http://tilloy.net/dev/pyexiv2/developers.htm. I encountered the following gotchas:
Your mileage may differ. I'll be interested to learn how to avoid these steps. Anyway, it's done and working. Here's my build tree: 44 /home/rmills/gnu> ls -alt drwxr-xr-x 6 rmills staff 16384 Aug 19 19:43 pyexiv2 drwxrwxrwx 12 rmills staff 16384 Aug 19 19:04 boost_1_35_0 drwxr-xr-x 9 rmills staff 16384 Aug 1 16:43 exiv2-0.17.1 drwxrwxrwx 11 rmills staff 16384 Apr 9 21:14 gettext-0.17 drwxrwxrwx 13 rmills staff 16384 Apr 9 21:08 expat-2.0.1 drwxr-xr-x 19 rmills staff 16384 Apr 9 21:07 Python-2.5.2 45 /home/rmills/gnu> The build scriptThis script doesn't build the libraries. It builds the zip file which is published on the web. It was surprisingly difficult to construct and contains some useful lessons. I wanted to be able to collect all the things together into a zip archive to be published on the web. And I thought "Oh, that can't be difficult". Well it took time to figure out how to mount the Linux correctly from the Mac. And then the script had to be written and tested. So it took a couple of days. I construct the universal binaries in the build script. And finally, I create the zip file. The Mac can create zip files from directories directly in finder. This is actually implemented as you would NOT expect by the "ditto" command instead of one of the "gz**" utiliities. Anyway it's done. Build script: click here. There's another script "release" which actually copies stuff to the web using ftp (and some other details). I've decided not to publish this because it's too boring. setup.pyI really wanted to create a setup.py script for the release. Then you could simply do: sudo python setup.py This would install the stuff and set up the links. However, I haven't done this. I was fed up with the project by this time. If somebody would like to contribute, I'd be very happy to accept their assistance. One of the difficulties of setup.py is that it has to know where to install gps.py and surd.py on your path. I haven't studied or thought about this puzzle. Maybe the python setup generator has some magic to make this trivial. Road Map: jBrout, Phatch and exiv2jBrout is a photo browsing application. It's python based and ships on Windows and Linux. The next version will include my build of pyexiv2. http://jbrout.python-hosting.com. Phatch is an opensource project for a 'Photo Batcher'. It has a library of Action Items such as photo scaling. Actions can be easily sequenced into a work flow to perform processes. Phatch is written in Python - so this seems like the natural home for my code. The Geotag 'action' in Phatch is based on the python code in this article. http://photobatch.stani.be/. Andreas, the wonderful author of the exiv2 library has asked me to work on the Windows build. I'm delighted to accept this challenge. | |||||||||||||||
Comments? | |||||||||||||||
I'm very happy to accept comments, feedback and suggestions for any of my articles. I'm always happy to hear you - especially if you have constructive suggestions. And I'm particularily pleased if you can let me know about corrections. |
|||||||||||||||
|