Forum: CFEngine Help
Subject: Re: Fwd:CFEngine Help: Compile tokyocabinet AIX 7.1
Author: matter
Link to topic: https://cfengine.com/forum/read.php?3,25774,27000#msg-27000

Tokyocabinet does need a little work to make a dynamic library. So instead of 
fighting the configs, let it make a static, and convert it yourself.

# ./configure --enable-off64 --prefix=/var/cfengine --disable-zlib 
--disable-bzip --enable-static --disable-shared
# gmake

Let it do it's think and make a libtokyocabinet.a.

# file libtokyocabinet.a
libtokyocabinet.a: archive (big format)

Let take the object files and make our own shared library:

# gcc -shared tcutil.o tchdb.o tcbdb.o tcfdb.o tctdb.o tcadb.o myconf.o md5.o 
-o libtokyocabinet.a -lpthread -lm 
# file libtokyocabinet.a                                                        
                                          
libtokyocabinet.a: executable (RISC System/6000) or object module not stripped

# dump -gov libto* | head -n 20
libtokyocabinet.a:

                        ***Object Module Header***
# Sections      Symbol Ptr      # Symbols       Opt Hdr Len     Flags
         5      0x00111894          59254                72     0x3002
Flags=( EXEC DYNLOAD SHROBJ DEP_SYSTEM )
Timestamp = "Aug 09 19:28:55 2012"
Magic = 0x1df  (32-bit XCOFF)


There we go. Just copy that to your library directory. CFE will work with it 
nicely.

_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to