[sword-devel] CMake: Sword SVN trunk fails to configure without SVN

Jaak Ristioja jaak at ristioja.ee
Sat Feb 20 05:32:25 EST 2021


Correct. I suppose it stopped working after SVN 3840 ("Fixed 
CMakeList.txt to properly include SVN revision number if within an SVN 
repositor").

After some more research, I think the issue is that the 
IGNORE_SVN_FAILURE option to Subversion_WC_INFO() was only introduced in 
CMake 3.13 and does not work properly in CMake prior versions, hence it 
does not work in CMake 3.12 which BibleTime is using on Travis CI.

Please consider working around this issue for CMake versions prior to 
3.13 or bumping the CMAKE_MINIMUM_REQUIRED(VERSION 2.6.0) to 3.13.0.

J

On 16.02.21 20:12, Troy A. Griffitts wrote:
> Hi Jaak,
> 
> Thanks for reminding us there is a problem here. I am not sure I have my head around this one. What I added was supposed to be a cmake module which worked correctly within svn and outside, as long as a parameter was passed which basically says skip errors.
> 
> If I remember correctly, it was working for you at one point, and then we did some additional enhancements to the cmake build system and then it stopped working for you. Is that correct?
> 
> While I am sure checking for the .svn folder will work, as you suggest, I'd prefer to find out what we did to break the built-in support for skipping problems when not within an svn working directory.
> 
> Greg, any input on this one?
> 
> Troy
> 
> On February 16, 2021 7:07:47 AM MST, Jaak Ristioja <jaak at ristioja.ee> wrote:
>> Hello,
>>
>> If changes/fixes to the CMake build system is in queue, please consider
>>
>> taking a look at this BibleTime issue as well. Thanks!
>>
>> Best regards,
>> J
>>
>> On 08.01.21 01:49, Jaak Ristioja wrote:
>>> Hello!
>>>
>>> The capricious CI for BibleTime again fails to build the latest SVN
>>> trunk version of Sword with CMake:
>>>
>>> -- Found Subversion: /usr/bin/svn (found version "1.9.7")
>>>
>>> CMake Error at
>>>
>> /usr/local/cmake-3.12.4/share/cmake-3.12/Modules/FindSubversion.cmake:99
>>
>>> (message):
>>>
>>>     Command "/usr/bin/svn info /tmp/tmp.Tii77pWpje/source" failed with
>>
>>> output:
>>>
>>>     svn: E155007: '/tmp/tmp.Tii77pWpje/source' is not a working copy
>>>
>>>
>>> I took a look at the recent Subversion related changes in
>> CMakeLists.txt
>>> and propose to add detection that "${CMAKE_CURRENT_SOURCE_DIR}/.svn"
>>> exists and that the the Subversion client executable is available on
>> the
>>> system, e.g.:
>>>
>>>     if(IS_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/.svn")
>>>       find_package(Subversion)
>>>       if(COMMAND Subversion_WC_INFO)
>>>         Subversion_WC_INFO("${CMAKE_CURRENT_SOURCE_DIR}" MYSVN
>>>                            IGNORE_SVN_FAILURE)
>>>       endif()
>>>     endif()
>>>
>>> Note also that I double quoted "${CMAKE_CURRENT_SOURCE_DIR}" in the
>>> above so that directories with spaces wouldn't cause an incorrect
>> number
>>> of arguments getting passed to Subversion_WC_INFO(). Using if(COMMAND
>>
>>> Subversion_WC_INFO) instead of if(Subversion_FOUND) is safer as it
>>> allows users to provide their own Subversion_WC_INFO() command in
>> cases
>>> where FindSubversion() doesn't work for them (e.g. when subversion is
>>
>>> not installed, not found by FindSubversion.cmake or FindSubversion
>> fails
>>> to define Subversion_WC_INFO()).
>>>
>>>
>>> Best regards,
>>> J
>>> _______________________________________________
>>> sword-devel mailing list: sword-devel at crosswire.org
>>> http://crosswire.org/mailman/listinfo/sword-devel
>>> Instructions to unsubscribe/change your settings at above page
>>
>> _______________________________________________
>> sword-devel mailing list: sword-devel at crosswire.org
>> http://crosswire.org/mailman/listinfo/sword-devel
>> Instructions to unsubscribe/change your settings at above page
> 
> 
> _______________________________________________
> sword-devel mailing list: sword-devel at crosswire.org
> http://crosswire.org/mailman/listinfo/sword-devel
> Instructions to unsubscribe/change your settings at above page
> 



More information about the sword-devel mailing list