[bt-devel] SWORD Library Discovery (Re: On Linux too?)

Troy A. Griffitts scribe at crosswire.org
Mon Feb 1 09:51:51 MST 2010


Hi Eeli,

Yes, LocalePath was added after that documentation was written.  It 
should probably be updated.  I can't remember the exact changes there, 
but they were made to assist the Xiphos team with their Windows port, if 
I remember correctly.

All the rules in the INSTALL doc are what happens if you simply:

SWMgr library;

They have a long history and have evolved by a number of needs 
throughout the years.  They might not be obvious from a cursory glance, 
but they enable bibletime to be used in a number of different scenarios 
by simply configuring SWORD differently:

SWORD_PATH=/media/cdrom bibletime
cd experimental_repository; bibletime
cat <<!
[Install]
DataPath=/mnt/network/server/sword
!> ~/.sword/sword.conf; bibletime


The engine has methods to add additional augment paths programmatically 
at runtime, and also to impede the default discovery mechanisms.  But I 
would strongly advise against this for a full frontend like bibletime. 
The problem seems to be coordination between projects on the same 
platform.  This is hard.  The easy way out would be to use the engine 
methods to override the logic to what the bibletime developers see as 
the correct way.  But in the long run, I think it is extremely important 
to spend the time discussing this with the other frontend providers and 
come up with a good configuration solution.

If I remember correcly, the JSword guys asked for SWORD_PATH to be 
defined when BibleCS was installed.  Now that we have 5+ frontends that 
work on Windows, further coordination needs to take place, as SWORD_PATH 
takes precedence over most other configuration options (all but CWD 
config files, I believe, so your $(BIBLETIME_ROOT)/sword.conf should 
override SWORD_PATH if you update it to include a DataPath entry.

Something good to see how things are being discovered in your current 
configuration is sword/tests/mgrtest.  This will exhaustively output the 
steps being taken to determine the SWORD library configuration.  Simply 
run it in the say way as you are running bibletime and it will show you 
how the engine has resolved things.

Hope this helps,

Troy




Eeli Kaikkonen wrote:
> On Mon, 1 Feb 2010, Eeli Kaikkonen wrote:
>> I may have found the Windows problem, too. The search for the modules is
>> stopped if there's mods.d directory in $SWORD_PATH. We use that env
>> variable if it's found. Therefore, if the BibleCS is installed, the
>> engine doesn't find modules installed elsewhere. Gary, am I right?
>>
>> Doesn't this also destroy the idea of adding e.g. CD or USB stick
>> locations, because they can't be used if $SWORD_PATH is used? Does the
>> engine really work this way?
> 
> No, I don't know if it really works this way. I'll try to find it out
> but appreciate any help, especially on the Windows port.
> 
> The locale problem seems to have a solution. The engine documentation
> isn't quite correct, it doesn't mention the LocalePath in the
> sword.conf. I found it in our own code. It just isn't used on Linux,
> Gary has written it for Windows. I hope it works there.
> 
>   Yours,
> 	Eeli Kaikkonen (Mr.), Oulu, Finland
> 	e-mail: eekaikko at mailx.studentx.oulux.fix (with no x)
> 
> _______________________________________________
> bt-devel mailing list
> bt-devel at crosswire.org
> http://www.crosswire.org/mailman/listinfo/bt-devel




More information about the bt-devel mailing list