[mapguide-commits] r4394 - in trunk/MgDev/Common: CoordinateSystem Geometry

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Tue Dec 8 23:55:28 EST 2009


Author: leaf
Date: 2009-12-08 23:55:27 -0500 (Tue, 08 Dec 2009)
New Revision: 4394

Added:
   trunk/MgDev/Common/CoordinateSystem/CoordSysEnvVariable.h
Modified:
   trunk/MgDev/Common/CoordinateSystem/CoordSysCatalog.cpp
   trunk/MgDev/Common/Geometry/Makefile.am
Log:
This submission fix Ticket #1153.
I removed the MapGuide Enterprise Coordinate System Dictionary path on Linux, and replace it with a OpenSource path.
My solution is:
1. Add a new header file named CoordSysEnvVariable.h, and define the OpenSource path in it.
2. Using the OpenSource path in the CoordSysCatalog.cpp.
3. Modify the makefile correspondingly.

Modified: trunk/MgDev/Common/CoordinateSystem/CoordSysCatalog.cpp
===================================================================
--- trunk/MgDev/Common/CoordinateSystem/CoordSysCatalog.cpp	2009-12-09 00:33:52 UTC (rev 4393)
+++ trunk/MgDev/Common/CoordinateSystem/CoordSysCatalog.cpp	2009-12-09 04:55:27 UTC (rev 4394)
@@ -54,6 +54,10 @@
 #undef GetMessage
 #endif
 
+#ifndef _WIN32
+#include "CoordSysEnvVariable.h"
+#endif
+
 //Global variables needed from Mentor
 extern "C"
 {
@@ -224,7 +228,7 @@
     if (sDir.empty())
     {
         bResult = true;
-        sDir = L"/opt/Autodesk/mapguideenterprise2010/share/gis/coordsys";  // NOXLATE
+        sDir = LINUX_COORD_PATH;
     }
 
 #endif

Added: trunk/MgDev/Common/CoordinateSystem/CoordSysEnvVariable.h
===================================================================
--- trunk/MgDev/Common/CoordinateSystem/CoordSysEnvVariable.h	                        (rev 0)
+++ trunk/MgDev/Common/CoordinateSystem/CoordSysEnvVariable.h	2009-12-09 04:55:27 UTC (rev 4394)
@@ -0,0 +1,11 @@
+//
+//  This library is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+//
+#define LINUX_COORD_PATH    L"/usr/local/mapguideopensource/share/gis/coordsys";  // NOXLATE
\ No newline at end of file

Modified: trunk/MgDev/Common/Geometry/Makefile.am
===================================================================
--- trunk/MgDev/Common/Geometry/Makefile.am	2009-12-09 00:33:52 UTC (rev 4393)
+++ trunk/MgDev/Common/Geometry/Makefile.am	2009-12-09 04:55:27 UTC (rev 4394)
@@ -389,7 +389,8 @@
   ../CoordinateSystem/CoordSysMgrsZone.h \
   ../CoordinateSystem/CoordSysMgrs.h \
   ../CoordinateSystem/CoordSysMgrsMajorRegion.h \
-  ../CoordinateSystem/CoordSysOneGrid.h
+  ../CoordinateSystem/CoordSysOneGrid.h\
+  ../CoordinateSystem/CoordSysEnvVariable.h
 
 INCLUDES = \
   -I../Security \



More information about the mapguide-commits mailing list