Home Help Center

Compiling ICE 1.2.0

catalincatalin Member ✭✭
Hi!

Sorry for this post. I did install ICE so many times on different machines that I can not figure out what I am missing this time. I'm working on a RedHat 9.0 machine with absolutelly all packages from the 3 installation CDs installed:

I compiled Berkley DB like this, after setting the LD_ASSUME_KERNEL variable to 2.4.1:
make realclean
../dist/configure --enable-java --enable-cxx --prefix=/home/catalin/hfag/sysInstall/db-4.1.25-InstDir/
make
make install


I have set the following variable too:
[[email protected] Ice-1.2.0]# echo $LD_LIBRARY_PATH
/home/catalin/hfag/sysInstall/db-4.1.25-InstDir/lib


I am trying to compile ICE and get the following:

...
making all in Freeze
make[2]: Entering directory `/home/catalin/hfag/sysInstall/Ice-1.2.0/src/Freeze'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/catalin/hfag/sysInstall/Ice-1.2.0/src/Freeze'
making all in IceBox
make[2]: Entering directory `/home/catalin/hfag/sysInstall/Ice-1.2.0/src/IceBox'
rm -f ../../bin/icebox
c++ -g -ftemplate-depth-128 -fPIC -Wall -D_REENTRANT -L../../lib -o ../../bin/icebox ServiceManagerI.o Server.o -lIceBox -lFreeze -lIce -lIceUtil -lpthread -L/home/catalin/hfag/sysInstall/db-4.1.26-InstDir/lib -ldb_cxx
../../lib/libFreeze.so: undefined reference to `DbEnv::set_rep_limit(unsigned, unsigned)'
../../lib/libFreeze.so: undefined reference to `DbEnv::get_errpfx(char const**)'
../../lib/libFreeze.so: undefined reference to `DbEnv::set_rep_transport(int, int (*)(DbEnv*, Dbt const*, Dbt const*, DbLsn const*, int, unsigned))'
../../lib/libFreeze.so: undefined reference to `DbEnv::dbrename(DbTxn*, char const*, char const*, char const*, unsigned)'
../../lib/libFreeze.so: undefined reference to `Db::get_env()'
...


What did I forget to do? I keep reading the install docs without figuring it out.

Thanks
Catalin

Comments

  • taweilitaweili Member
    If I remeber correctly, you need to set the DB_HOME variable. I think you can set it in environment variable. If not, edit the file called Makefile.Linux or something similar.

    Sorry for the rough reply. I don't have a Ice installation near by to give precise path.
  • catalincatalin Member ✭✭
    Hi!

    I forgot to tell that I did set the following in Make.rules:

    #DB_HOME ?= /opt/db
    DB_HOME ?= /home/catalin/hfag/sysInstall/db-4.1.25-InstDir

    I tried both using "=" and "?=" but neither of them helps.

    Since you mentioned it I set the variable in the shell as well, just to test it. The same result.

    Thanks for your reply.

    Catalin
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Hi,

    The linker command in your first post seems to have the wrong BerkeleyDB version (4.1.26):
    ... -L/home/catalin/hfag/sysInstall/db-4.1.26-InstDir/lib ...
    
    Was that a cut & paste error? If not, that's the likely cause of the problem. The linker won't warn you about invalid link directory options.

    Take care,
    - Mark
  • catalincatalin Member ✭✭
    No, unfortunatelly it is not a cut and paste error.

    I did a cut and paste when posting the message, but the error was introduced by myself, on purpose, to see if it makes any differance. It didn't! I just forgot to correct the value of the variable prior to posting the message.

    I tried like 10 times to compile Berkley DB, and then make ICE; all attemptes ended with the same error. I even tried to compile two versions of Berkley DB, 4.1.25 and 4.2.52 (the latest version) and link to them. The same result.

    I have Berkley DB 4.1.25 compiled on another system where the making of ICE succeded. I even copied the contents of that install directory and tried to link angainst those libraries, with the same result.

    This shouldn't be the case but I almost suspect the something is cashed somewhere and that my runs of make are not done properly.

    I will shut down the system and try again, from scratch.

    I'll be back.

    Catalin
  • michimichi Member Michi HenningOrganization: Triodia TechnologiesProject: I have a passing interest in Ice :-) ✭✭✭
    Have you checked that you are picking up the correct include files for Berkeley DB? If you have an older version of Berkeley DB installed that came with your OS, you may be picking up the old header files, which won't work when you try to link with the newer library.

    Cheers,

    Michi.
  • bernardbernard Jupiter, FLAdministrators, ZeroC Staff Bernard NormierOrganization: ZeroC, Inc.Project: Ice ZeroC Staff
    I am also suspecting a mismatch header/library. You need to configure Berkeley DB 4.1.25 [please don't use another version] with --enable-cxx.

    See also:
    http://www.zeroc.com/vbulletin/showthread.php?s=&threadid=263

    Cheers,
    Bernard
  • catalincatalin Member ✭✭
    Thanks to everyone, I installed everything form scratch after a good night's rest. Everything worked out without any problem. What I could have done wrong yesterday was to have set the LD_LIBRARY_PATH variable to the InstDir of Berkeley DB instead of to the InstDir/lib.

    Catalin
Sign In or Register to comment.