wiki:CsMapRfc8

CS-Map RFC 8 - CS-MAP Clean Up

Remove and/or delete as appropriate obsolete and unused source code modules and unused code. Includes removing same from make files and project files.

Status

RFC Template Version(1.0)
Submission Date09 May 2014
Last ModifiedNorm Olsen Timestamp
Author Norm Olsen
RFC Status Approved
Implementation Status In Progress
Proposed Milestone 14(?)
Assigned PSC guide(s)(when determined)
Voting History(vote date)
+1Olsen Wisniewski
+0
-0
-1
no vote

Overview

Over the years, CS-MAP has accumulated a lot of unused and obsolete code which is no longer necessary. This baggage has accumulated due to a variety of factors:

  • Being maintain by separate organizations and developers
  • Features being replaces by new RFC's.
  • Provisions for obsolete and/or non-standard operating system and compilers.
  • Old features maintained for legacy purposes which are now a liability rather than a positive.

The intent of this RFC is to itemize the proposed clean up efforts, have them reviewed and discussed, and upon final agreement, implement the clean up.

Motivation

Implementing this clean up will:

  • reduce the amount of code maintained,
  • reduce confusion to new users and developers,
  • remove unnecessary restrictions originally written in to accommodate obsolete platforms/OS/compilers
  • improve build times
  • reduce distributable sizes

Proposed Solution

The following is a list of items proposed for the clean up. Modifications, deletions, and additions are encouraged.

  • Remove the 'C' based CS_Test module. It hasn't been maintained and is rarely, if ever, used any more.
  • Delete (SVN meaning of Delete) pre-RFC-2 geodetic transformation code modules which are no longer referenced.
  • Remove all code pertaining specifically to Windows CE.
  • Correct all warnings issued by VC++ and gcc compilers.
  • Enhance make files for Windows and Linux so that single make command builds the entire product.
  • Remove all .gdc and .mrt files from dictionaries and distributions.
  • Modify the capitalization of file names so that all comform to a consist naming convention.
  • Rename modules and internal functions to names conforming to the base CS-MAP naming convention.
  • Implement pre-compiled headers where ever possible in make/project files.
  • Re-organize the csTestCpp test module to better reflect the actual usage for the product (i.e. Categories in, Groups out, 3D coordinate testing, etc.)

Implications

I submit this as an RFC as it is likely that some of the changes may require an tweak or two external to the library itself. And also, a project such as this needs a lot of testing in different environments. Without the support of the entire community, embarking on this worthwhile project could be dangerous. Assuming that no one is using the CS-Test.c module, and that few (if any) use modules below the EXP_LVL1 external interface, no external changes are envisioned, BUT . . .

Implementation Plan

Each of the above listed items will be implemented, tested, reviewed, and submitted separately to the extent possible. The easiest and safest will be performed first. The following are considered to be the easiest and safest:

  • Remove the CS_Test module.
  • Delete RFC-2 left overs from the repository and remove all reference in project/make files.
  • Remove unused .gdc and all .mrt files from the distribution and code (i.e. the Dictionary compiler).
  • Remove the remaining .gdc files which are still used (Vertcon and Geoid Height), replacing them with the concept of simply using whatever files exist in a predefined folder.
  • Modify the names of source code modules to comply with the basic CS-MAP naming convention. (Changes to module names, and hence changes to make/project files only. Function/Interface names remain unchanged.)

Test Plan

The existing, then the improved, csTestCpp module will be used to verify computational results remain the same and that basic features retain functionality and performance.

Funding and Resources

Hopefully, the primary patrons of the library will contribute funding and/or personnel resources to support some or all of these efforts. In absence thereof, Norm Olsen will perform the work. In the latter case, the effort will take 12 or more months to complete.

Implementation Notes

June 19, 2014: What has been dubbed Phase One is now pretty much complete. The table below shows module deletions and name changes which may be of specific interest to users of the library. Precompiled headers are now used for Windows builds; use in Linux is deferred as the Linux build is so fast the effort seemed to be "not worth the effort". The MAKE files have been rewritten, and an over all make file for both Windows and Linus are now available. The MAKE files have been designed to specifically support efficient maintenance of several versions of the library in both the Windows and Linux environments. Testing of the MAKE files in environments other than Windows and Linux (CentOS 6.3 to be specific) have not been performed as such additional enviornments are not available to the developer. Am now proceeding to Phase Two: eliminating warning messages and removing obsolete code.

Note: modules marked as SVN delete will remain in the SVN repository, select revision 2452 or earlier to retrieve.

Action TakenOriginal NameNew NameComment
RenamedCS_ats77New.cCS_ats77.c
RenamedCS_japan.cCS_japanOld.cEventually deleted, see below
RenamedCS_japanNew.cCS_japan.c
Renamedcs_ctio.cCS_ctio.c
Renamedcs_wellknowntext.cppCS_wellknowntext.cpp
RenamedcsCsvFileSupport.cppCS_csvFileSupport.cpp
RenamedcsEpsgStuff.cppCS_epsgStuff.cpp
RenamedcsEpsgSupport.cppCS_epsgSupport.cpp
RenamedcsNameMapper.cppCS_nameMapper.cpp
Renamedcs NameMapperSupport.cppCS_nameMapperSupport.cpp
RenamedrcWellKnownText.cppCS_wktObject.cpp
RenamedrcWktKonstants.cppCS_wktObjKonstants.cpp
RenamedrcWellKnownText.hppcs_WktObject.hpp
RenamedcsCsvFileSupport.hppcs_CsvFileSupport.hpp
RenamedcsNameMapperSupport.hcs_NameMapperSupport.h
RenamedcsNameMapper.hppcs_NameMapper.hpp
Renamedcsepsgstuff.hcs_EpsgStuff.h
Removed from Projectscs_hlp.h MFC stuff
Removed from Projectscs_mfc.h MFC stuff
Removed from Projectscs_res.h MFC stuff
Removed from ProjectsmgTest.h MFC stuff
Removed from ProjectscsBrowser.cpp MFC stuff
Removed from ProjectscsDataDir.cpp MFC stuff
Removed from ProjectscsDualBrowse.cpp MFC stuff
Removed from ProjectscsEdit.cpp MFC stuff
Removed from ProjectscsKeyNm.cpp MFC stuff
Removed from ProjectscsTest.cpp MFC stuff
Removed from ProjectscsWinHlp.cpp MFC stuff
Removed from ProjectsdtEdit.cpp MFC stuff
Removed from ProjectsdtSelect.cpp MFC stuff
Removed from ProjectselEdit.cpp MFC stuff
Removed from ProjectselSelect.cpp MFC stuff
Removed from ProjectsgdcEdit.cpp MFC stuff
Removed from ProjectsmgTest.cpp MFC stuff
Removed from Projectscsmap.rc MFC stuff
DeletedCS_japanOld.c SVN delete
DeletedCS_caDatum.c SVN delete
DeletedCS_caV1GridFile.c SVN delete
DeletedCS_caV2GridFile.c SVN delete
DeletedCS_ch1903.c SVN delete
DeletedCS_csrs.c SVN delete
DeletedCS_dhdn.c SVN delete
DeletedCS_dtAgd66ToGda94.c SVN delete
DeletedCS_dtAgd84ToGda94.c SVN delete
DeletedCS_dtAts77ToNad83.c SVN delete
DeletedCS_dtCh1903ToPlus.c SVN delete
DeletedCS_dtDhdnToEtrf89.c SVN delete
DeletedCS_dtEd50ToEtrf89.c SVN delete
DeletedCS_dtNad27ToAts77.c SVN delete
DeletedCS_dtNad27ToNad83.c SVN delete
DeletedCS_dtNad83ToHarn.c SVN delete
DeletedCS_dtNzdg49ToNzgd2k.c SVN delete
DeletedCS_dtRgf93ToNtf.c SVN delete
DeletedCS_dtTokyoToJgd2k.c SVN delete
DeletedCS_hpgn.c SVN delete
DeletedCS_nad27.c SVN delete
DeletedCS_nzgd49.c SVN delete
DeletedCS_rgf93ToNtf.c SVN delete
DeletedCS_usDatum.c SVN delete
DeletedCS_usGridFile.c SVN delete
DeletedCSdatumSupport.c SVN delete
DeletedCSgridCellCache.c SVN delete
DeletedCSnad27ToCsrs.c SVN delete
DeletedCSnad83ToCsrs.c SVN delete

September 10, 2014: What has been dubbed as Phase Two is now complete. All compiler warnings have been removed at the (VC++) /W4 level and (gcc) -w level. Static code analysis on all modules was completed and all reports either corrected and/or flagged. See the "/*lint */" and "lint" comments in the code, and the exceptions listed in lcl.lnt. Static analysis was performed using PC-Lint 9.00k. All supported versions of Visual Studio (Win32/x64, Release/Debug) and Linux (x86/x64 on gcc/g++ 4.7 using CentOS 6.3) were built and tested. Geodetic Data Catalog files remain in use for Geoid Height and Vertcon; no changes there.

The Console Test facility will report EPSG audit errors if used for EPSG database newer than 8.02; EPSG has now released 8.05. Fixing these issues is yet another project which may need to be funded.

A few additional name changes and file deletions were made:

Action TakenOriginal NameNew NameComment
RenamedCS_COMP.cCS_Comp.c
Renamedcscscomp.cCScscomp.c
RenamedCS_GeoidHeight.cCS_geoidHeight.c
RenamedCS_VertconUS.cCS_vertconUS.c
RenamedcsTestCpp.cppCS_TestCpp.c
RenamedcsTestCpp.exeCS_TestCpp.exe
DeletedCSmrcomp.c Obsolete since RFC-2
DeletedCS_ed50.c Obsolete since RFC-2
DeletedcsBrowser.cpp MFC Stuff, Phase One delete was not completed
Deletedcsmap.rc MFC Stuff, Phase One delete was not completed
DeletedAgd66ToGda94.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedAgd84ToGda94.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedAts77ToCrsr.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedCh1903ToPlus.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedDhdnToEtrf89.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedEd50ToEtrf89.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad27ToCsrs.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad27ToAts77.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad27ToNad83.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad83ToCsrs.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad83ToHarn.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNzgd49ToNzgd2K.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedRgf93ToNtf.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedTokyoToJgd2k.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad27ToAts77.gdc Geodetic Data Catalog, obsolete since RFC-2
DeletedNad27ToAts77.gdc Geodetic Data Catalog, obsolete since RFC-2
Last modified 8 years ago Last modified on Sep 11, 2014, 10:22:47 AM
Note: See TracWiki for help on using the wiki.