Building CTDB 1.10 on AIX

John P Janosik jpjanosi at us.ibm.com
Thu Jun 23 14:24:31 MDT 2011


I'm having issues building CTDB on AIX, hopefully this is the correct 
place to post.  Let me know if not and/or if I should be opening bugs 
against the CTDB component.

1.
Compiling lib/util/fault.c
lib/util/fault.c:113:2: error: #error bla

I didn't look into how HAVE_BACKTRACE is set during the configure and if 
there is a good way to do this on AIX, I just commented out the #error 
line to get by this.  Is there a reason this error is there for systems 
that don't detect this support?

2. 
Compiling libctdb/ctdb.c
In file included from ./include/ctdb.h:30,
                 from libctdb/ctdb.c:19:
./include/ctdb_protocol.h:190: error: field 'start' has incomplete type
./include/ctdb_protocol.h:191: error: field 'finished' has incomplete type
./include/ctdb_protocol.h:499: error: field 'sa' has incomplete type
./include/ctdb_protocol.h:622: error: field 'statistics_start_time' has 
incomplete type
./include/ctdb_protocol.h:623: error: field 'statistics_current_time' has 
incomplete type

The first two and last two are because of "struct timeval".  Looks like on 
linux sys/types.h includes time.h, but this doesn't happen on AIX.  The 
other is because sys/socket.h is not getting included, my linux box has it 
included via netinet/in.h, but not on AIX.  I'm not sure the proper way to 
fix these so I just included them for now in ctdb.h to get past this.

3.
Linking bin/ltdbtool
ld: 0711-317 ERROR: Undefined symbol: .main
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more 
information.

I don't understand the Makefile on this one, it doesn't seem to include 
the objects needed.  Here is what was in Makefile.in:

bin/ltdbtool: tools/ltdbtool.o @TDB_OBJ@
        @echo Linking $@
        @$(CC) $(CFLAGS) -o $@ $+

I changed it to look like the other client tools:

bin/ltdbtool: tools/ltdbtool.o @TDB_OBJ@
        @echo Linking $@
        @$(CC) $(CFLAGS) -o $@ tools/ltdbtool.o $(CTDB_CLIENT_OBJ) 
$(LIB_FLAGS)


John Janosik
jpjanosi at us.ibm.com


More information about the samba-technical mailing list