[sword-devel] problems compiling sword

Le Scribe lescribe at bonbon.net
Wed Oct 13 19:03:09 MST 2004

hey guys, i love the software, i just decided to start helping out in my
extremely limited spare time. However, i have been hindered in that most of
the programs in the "utilities" dir were not included in the sarge apt
repositories, so i can't just apt-get them.
However, when i try to compile the program from source (1.5.7a to be
specific), i get several errors when compiling.

first off, it tells me that:
../src/mgr/installmgr.cpp: In member function `char
   sword::InstallMgr::FTPURLGetFile(void*, const char*, const char*)':
../src/mgr/installmgr.cpp:158: warning: converting of negative value `-1' to
 ` char'

so i go into the installmgr.cpp file and i realize that on line 132, it has
retVal declared as a char, but later on, it seems like it is used as a
if/then value, and should be an int. so i changed the line from:
        char retVal = 0;
 int retVal = 0;

now it compiles. However, i run into another problem later on. it says:

 ../src/modules/common/rawstr.cpp -o rawstr.o
../src/modules/common/rawstr.cpp: In member function `void
   sword::RawStr::doSetText(const char*, const char*, long int)':
../src/modules/common/rawstr.cpp:419: warning: comparison is always true due
   limited range of data type

so i go to line 419, and this is what the comparison is:
else if (strcmp(key, dbKey) > 0) {
                if (errorStatus != -2)  // not a new file
                        idxoff += 6;
                else idxoff = 0;

well, not even sure what this is supposed to do, and not being very familiar
with c++ (i've coded some before, but never in c++), i'm not sure what to do
here. Keep in mind, all i'm trying to do is get a workable set of utilities
to make some modules with. I'm planning on helping you guys with coding, but
once i have
A. Gotten a hang of the module creation process
B. Familiarized myself with c++

anywho... thanks for any help you guys can give me


prov. 4.23


More information about the sword-devel mailing list