Opened 16 years ago
Last modified 13 years ago
#126 closed task (fixed)
Don't include private PROJ.4 header projects.h
Reported by: | mloskot | Owned by: | |
---|---|---|---|
Priority: | medium | Milestone: | PostGIS 1.4.0 |
Component: | postgis | Version: | 1.4 |
Keywords: | Cc: |
Description (last modified by )
In current SVN trunk, PostGIS file lwgeom_transform.c includes private header of PROJ.4 - projects.h. This header is…private and should not be included form PROJ.4 client code. Instead, proj_api.h should be used. However, replacing these headers requires number of changes in lwgeom_transform.c. For instance, use API call(s) instead of accessing internal structures:
current code:
if( !srcdefn→is_latlong )
new code:
if( !pj_is_latlong( srcdefn ) )
Including private header projects.h makes it impossible to compile using Microsoft Visual C++ compiler, becasue of well-known conflicts with definitions from windows.h. Here is confirmation of existence of that issue: http://lists.osgeo.org/pipermail/gdal-dev/2005-May/005669.html
I've just (re)hit this problem and it stops me from moving forward with building PostGIS using Visual C++.
Change History (4)
comment:1 by , 16 years ago
comment:4 by , 13 years ago
Description: | modified (diff) |
---|
This ticket lacks a reference to a revision id, ouch…
I think it was r3827 (thanks GIT for making the research so easy
Hi Mateusz,
I've just committed the fix for this to SVN trunk. Can you please test and report back?
ATB,
Mark.