[Xastir] Ubuntu 9.04 howto now on Xastir wiki

Tom Russo russo at bogodyn.org
Mon Jun 29 14:09:42 EDT 2009


On Mon, Jun 29, 2009 at 01:29:36PM -0400, we recorded a bogon-computron collision of the <kevin at kevinratcliff.com> flavor, containing:
> On Sat, Jun 27, 2009 at 10:08 PM, Tom Russo<russo at bogodyn.org> wrote:
> > The libgeotiff is fine, but unfortunately depends on proj.4 --- and the
> > proj.4 installation for Ubuntu (and all Debian distros) is compiled
> > incorrectly without NAD datum shift grids. ?This can be a problem.
> 
> Thanks for the warning Tom!
> 
> > If you are using proj.4 for *anything* other than Xastir (which requires it
> > solely for libgeotiff, but doesn't use it for datum shifting), you need to
> > build proj.4 from sources and do so by unpacking the NAD datum shift grids
> > in the "nad" directory first.
> 
> I will make some changes to the Ubuntu 9.04 wiki article to reflect
> this information.
> 
> > Just a warning. ?This doesn't impact Xastir directly, but does impact *anything*
> > else that uses proj.4 (QGIS, GRASS, or GDAL tools). ?If you build proj.4 from
> > source, you also need to build libgeotiff from source -- otherwise the
> > package management system will install the broken one anyway.
> 
> I recently used ogr2ogr to convert (not sure if that's the correct
> term) a shapefile from NAD27 UTM to WGS84 Lat/Lon. I had the Ubuntu
> proj binary installed and had compiled GDAL from source. Is my newly
> converted shapefile hosed?

It is highly likely that the datum shift was not correctly applied.   I know
that trying to convert from NAD83 to NAD27 (or vice versa) will be wrong with
the proj.4 in Ubuntu repositories, but I'm not sure what it'll do with 
NAD27-WGS84.  I would assume it does the wrong thing, but you'd need to check.

You can check if your proj.4 install has datum shift grids correctly installed
by running:

  cs2cs +proj=latlong +datum=NAD27 +to +proj=latlong +datum=NAD83

and typing in a coordinate pair (e.g. 106d32'47.8"W 35d18'16.5"N) and seeing
if it returns precisely the same number as a result.  If it does, your proj.4
is not built properly for NAD-NAD conversion.  Then try again with


  cs2cs +proj=latlong +datum=NAD27 +to +proj=latlong +datum=WGS84

and see if it does the same thing.  If the results of this are as bad as for
NAD27-NAD83, you will want to redo your conversion.

NAD83 and WGS84 are, for all practical APRS purposes, identical in North 
America and the two commands above should produce the same answer to many
(if not all) digits, and it should be different from the input.  If they simply
spit out the same numbers as the input, then the datum shift isn't being
applied.  Any program that uses proj.4 libraries to do the job (such as ogr2ogr)
will be similarly wrong.

This bug is reported in Ubuntu's bug tracker, and there is an unofficial package
with the fix applied.  The repositories themselves have NOT been updated yet,
and there appears to be no rush to get them fixed.

-- 
Tom Russo    KM5VY   SAR502   DM64ux          http://www.swcp.com/~russo/
Tijeras, NM  QRPL#1592 K2#398  SOC#236        http://kevan.org/brain.cgi?DDTNM
  In some cultures what I do would be considered normal. 
                                  -- Ineffective daily affirmation 



More information about the Xastir mailing list