[geos-devel] [GEOS] #556: Build error using cmake: ../geos_svn_revision.h: No such file or directory

GEOS geos-trac at osgeo.org
Wed Jun 6 06:43:27 PDT 2012


#556: Build error using cmake: ../geos_svn_revision.h: No such file or directory
------------------------+---------------------------------------------------
 Reporter:  dburken     |       Owner:  geos-devel@…              
     Type:  defect      |      Status:  new                       
 Priority:  major       |   Milestone:  3.3.5                     
Component:  Default     |     Version:  3.3.4                     
 Severity:  Unassigned  |    Keywords:                            
------------------------+---------------------------------------------------
 The cmake build is not auto-generating geos_svn_revision.h so you get
 error:

 {{{
 [ 83%] Building CXX object capi/CMakeFiles/geos_c.dir/geos_ts_c.cpp.o
 /work/osgeo/geos/geos-svn/capi/geos_ts_c.cpp:96:34: fatal error:
 ../geos_svn_revision.h: No such file or directory
 }}}

 Potential fix would be to change CMakeLists.txt to call existing:
 {{{
 sh tools/svn_repo_revision.sh geos_svn_revision.h
 }}}

 Or use cmake macro to generate file. Example of pulling revision in cmake:
 {{{
 This will initialize ${Project_WC_REVISION}:

 #################################################################################
 #  MACRO: GET_SVN_REVISION
 #
 #  DESCRIPTION:
 #      MACRO FOR GETTING THE SVN revision for this build
 #################################################################################
 MACRO (GET_SVN_REVISION)
    FIND_PACKAGE(Subversion)
    IF(SUBVERSION_FOUND)
       Subversion_WC_INFO(${PROJECT_SOURCE_DIR} Project)
       MESSAGE("Current revision is ${Project_WC_REVISION}")
       Subversion_WC_LOG(${PROJECT_SOURCE_DIR} Project)
       MESSAGE("Last changed log is ${Project_LAST_CHANGED_LOG}")
    ENDIF()
 ENDMACRO(GET_SVN_REVISION)
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/geos/ticket/556>
GEOS <http://geos.refractions.net/>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).


More information about the geos-devel mailing list