[Box Backup] Bundled TDB fails to build

Achim achim+box at qustodium.net
Fri Oct 1 20:58:03 BST 2010


Hello Chris:

Just FYI, I cannot seem to compile TDB that has been synced to trunk in 
2710. I tried with an updated cygwin (1.7.7) and a fresh checkout from 
SVN, but the error stays the same. Do you have any suggestions?

I ran:

./bootstrap
./infrastructure/mingw/configure.sh
make

make[2]: Entering directory `/usr/src/boxi.after/boxbackup/lib/server'
[CXX]     LocalProcessStream.cpp
[CXX]     ServerControl.cpp
[CXX]     autogen_ConnectionException.cpp
[CXX]     autogen_ServerException.cpp
[AR]      ../../release/lib/server/server.a
[RANLIB]  ../../release/lib/server/server.a
make[2]: Leaving directory `/usr/src/boxi.after/boxbackup/lib/server'
make[2]: Entering directory `/usr/src/boxi.after/boxbackup/bundled/tdb'
Compiling common/tdb.c
common/tdb.c: In function `tdb_increment_seqnum':
common/tdb.c:62: error: `F_WRLCK' undeclared (first use in this function)
common/tdb.c:62: error: (Each undeclared identifier is reported only once
common/tdb.c:62: error: for each function it appears in.)
common/tdb.c: In function `_tdb_fetch':
common/tdb.c:192: error: `F_RDLCK' undeclared (first use in this function)
common/tdb.c: In function `tdb_parse_record':
common/tdb.c:241: error: `F_RDLCK' undeclared (first use in this function)
common/tdb.c: In function `tdb_exists_hash':
common/tdb.c:267: error: `F_RDLCK' undeclared (first use in this function)
common/tdb.c: In function `tdb_purge_dead':
common/tdb.c:350: error: `F_WRLCK' undeclared (first use in this function)
common/tdb.c: In function `tdb_delete_hash':
common/tdb.c:393: error: `F_WRLCK' undeclared (first use in this function)
common/tdb.c: In function `_tdb_store':
common/tdb.c:550: error: `F_WRLCK' undeclared (first use in this function)
common/tdb.c: In function `tdb_store':
common/tdb.c:615: error: `F_WRLCK' undeclared (first use in this function)
common/tdb.c: In function `tdb_append':
common/tdb.c:633: error: `F_WRLCK' undeclared (first use in this function)
make[2]: *** [common/tdb.o] Error 1
make[2]: Leaving directory `/usr/src/boxi.after/boxbackup/bundled/tdb'
make[1]: *** [dep_modules] Error 2
make[1]: Leaving directory `/usr/src/boxi.after/boxbackup/bin/bbackupd'
make: *** [release/bin/bbackupd/bbackupd.exe] Error 2


Even if I try to compile within "pure" cygwin (no MingW variables set), 
TDB fails:

$ cd /usr/src/boxi.after/boxbackup/bundled/tdb

$ ./autogen.sh
Now run ./configure and then make.

$ ./configure
checking build system type... i686-pc-cygwin
checking host system type... i686-pc-cygwin
checking target system type... i686-pc-cygwin
LIBREPLACE_LOCATION_CHECKS: START
LIBREPLACE_LOCATION_CHECKS: END
LIBREPLACE_CC_CHECKS: START
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for version of gcc... 3.4.4
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking whether byte ordering is bigendian... no
checking for inline... inline
checking for C99 designated initializers... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking for library containing strerror... none required
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
checking standards.h usability... no
checking standards.h presence... no
checking for standards.h... no
checking for long long... yes
checking size of int... 4
checking size of char... 1
checking size of short... 2
checking size of long... 4
checking size of long long... 8
checking for int8_t... yes
checking for uint8_t... yes
checking for int16_t... yes
checking for uint16_t... yes
checking for int32_t... yes
checking for uint32_t... yes
checking for int64_t... yes
checking for uint64_t... yes
checking for size_t... yes
checking for ssize_t... yes
checking size of off_t... 8
checking size of size_t... 4
checking size of ssize_t... 4
checking for intptr_t... yes
checking for uintptr_t... yes
checking for ptrdiff_t... yes
checking for immediate structures... yes
LIBREPLACE_CC_CHECKS: END
LIBREPLACE_BROKEN_CHECKS: START
checking for uid_t in sys/types.h... yes
checking for mode_t... yes
checking for off_t... yes
checking for size_t... (cached) yes
checking for pid_t... yes
checking for struct stat.st_rdev... yes
checking for ino_t... yes
checking for loff_t... yes
checking for offset_t... no
checking for working memcmp... yes
checking for pipe... yes
checking for strftime... yes
checking for srandom... yes
checking for random... yes
checking for srand... yes
checking for rand... yes
checking for usleep... yes
checking for setbuffer... yes
checking for lstat... yes
checking for getpgrp... yes
checking for utime... yes
checking for utimes... yes
checking stdbool.h usability... yes
checking stdbool.h presence... yes
checking for stdbool.h... yes
checking for stdint.h... (cached) yes
checking sys/select.h usability... yes
checking sys/select.h presence... yes
checking for sys/select.h... yes
checking setjmp.h usability... yes
checking setjmp.h presence... yes
checking for setjmp.h... yes
checking utime.h usability... yes
checking utime.h presence... yes
checking for utime.h... yes
checking for stdint.h... (cached) yes
checking for stdbool.h... (cached) yes
checking for bool... yes
checking for _Bool... yes
checking for working mmap... yes
checking sys/syslog.h usability... yes
checking sys/syslog.h presence... yes
checking for sys/syslog.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking time.h usability... yes
checking time.h presence... yes
checking for time.h... yes
checking stdarg.h usability... yes
checking stdarg.h presence... yes
checking for stdarg.h... yes
checking vararg.h usability... no
checking vararg.h presence... no
checking for vararg.h... no
checking sys/mount.h usability... yes
checking sys/mount.h presence... yes
checking for sys/mount.h... yes
checking mntent.h usability... yes
checking mntent.h presence... yes
checking for mntent.h... yes
checking stropts.h usability... no
checking stropts.h presence... no
checking for stropts.h... no
checking unix.h usability... no
checking unix.h presence... no
checking for unix.h... no
checking for seteuid... yes
checking for setresuid... no
checking for setegid... yes
checking for setresgid... no
checking for chroot... yes
checking for bzero... yes
checking for strerror... yes
checking for strerror_r... yes
checking for vsyslog... yes
checking for setlinebuf... yes
checking for mktime... yes
checking for ftruncate... yes
checking for chsize... no
checking for rename... yes
checking for waitpid... yes
checking for wait4... yes
checking for strlcpy... yes
checking for strlcat... yes
checking for initgroups... yes
checking for memmove... yes
checking for strdup... yes
checking for pread... yes
checking for pwrite... yes
checking for strndup... yes
checking for strcasestr... yes
checking for strtok_r... yes
checking for mkdtemp... yes
checking for dup2... yes
checking for dprintf... yes
checking for vdprintf... yes
checking for isatty... yes
checking for chown... yes
checking for lchown... yes
checking for link... yes
checking for readlink... yes
checking for symlink... yes
checking for realpath... yes
checking for fdatasync... yes
checking for clock_gettime... yes
checking for get_current_dir_name... no
checking for setresuid declaration... no
checking for setresgid declaration... no
checking for errno declaration... yes
checking for secure mkstemp... yes
checking stdio.h usability... yes
checking stdio.h presence... yes
checking for stdio.h... yes
checking for strings.h... (cached) yes
checking whether snprintf is declared... yes
checking whether vsnprintf is declared... yes
checking whether asprintf is declared... yes
checking whether vasprintf is declared... yes
checking for snprintf... yes
checking for vsnprintf... yes
checking for asprintf... yes
checking for vasprintf... yes
checking for C99 vsnprintf... yes
checking for va_copy... yes
checking for __FUNCTION__ macro... yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking for comparison_fn_t... no
checking for setenv declaration... yes
checking for setenv... yes
checking for unsetenv... yes
checking for environ declaration... yes
checking for strnlen... yes
checking for strtoull... yes
checking for __strtoull... no
checking for strtouq... no
checking for strtoll... yes
checking for __strtoll... no
checking for strtoq... no
checking for memmem... yes
checking for sig_atomic_t type... yes
checking for O_DIRECT flag to open(2)... no
checking that the C compiler understands volatile... yes
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking sys/fcntl.h usability... yes
checking sys/fcntl.h presence... yes
checking for sys/fcntl.h... yes
checking sys/resource.h usability... yes
checking sys/resource.h presence... yes
checking for sys/resource.h... yes
checking sys/ioctl.h usability... yes
checking sys/ioctl.h presence... yes
checking for sys/ioctl.h... yes
checking sys/mode.h usability... no
checking sys/mode.h presence... no
checking for sys/mode.h... no
checking sys/filio.h usability... no
checking sys/filio.h presence... no
checking for sys/filio.h... no
checking sys/fs/s5param.h usability... no
checking sys/fs/s5param.h presence... no
checking for sys/fs/s5param.h... no
checking sys/filsys.h usability... no
checking sys/filsys.h presence... no
checking for sys/filsys.h... no
checking sys/acl.h usability... yes
checking sys/acl.h presence... yes
checking for sys/acl.h... yes
checking acl/libacl.h usability... no
checking acl/libacl.h presence... no
checking for acl/libacl.h... no
checking sys/file.h usability... yes
checking sys/file.h presence... yes
checking for sys/file.h... yes
checking for sys/select.h... (cached) yes
checking for sys/time.h... (cached) yes
checking for utime.h... (cached) yes
checking whether time.h and sys/time.h may both be included... yes
checking for utime... (cached) yes
checking for utimes... (cached) yes
checking if gettimeofday takes TZ argument... yes
checking for sys/wait.h that is POSIX.1 compatible... yes
checking sys/capability.h usability... no
checking sys/capability.h presence... no
checking for sys/capability.h... no
checking grp.h usability... yes
checking grp.h presence... yes
checking for grp.h... yes
checking sys/id.h usability... no
checking sys/id.h presence... no
checking for sys/id.h... no
checking compat.h usability... no
checking compat.h presence... no
checking for compat.h... no
checking shadow.h usability... no
checking shadow.h presence... no
checking for shadow.h... no
checking sys/priv.h usability... no
checking sys/priv.h presence... no
checking for sys/priv.h... no
checking pwd.h usability... yes
checking pwd.h presence... yes
checking for pwd.h... yes
checking sys/security.h usability... no
checking sys/security.h presence... no
checking for sys/security.h... no
checking for getpwnam_r... yes
checking for getpwuid_r... yes
checking for getpwent_r... no
checking for getpwent_r declaration... no
checking for prototype struct passwd *getpwent_r(struct passwd *src, 
char *buf, int buflen)... ./con
figure: line 7246: 
ac_cv_c_prototype_struct_passwd_pgetpwent_r_struct_passwd_psrc__char_pbuf__int_bu
flen_=no: command not found

checking for prototype struct passwd *getpwent_r(struct passwd *src, 
char *buf, size_t buflen)... ./
configure: line 7293: 
ac_cv_c_prototype_struct_passwd_pgetpwent_r_struct_passwd_psrc__char_pbuf__siz
e_t_buflen_=no: command not found

checking for getgrnam_r... yes
checking for getgrgid_r... yes
checking for getgrent_r... no
checking for getgrent_r declaration... no
checking for prototype struct group *getgrent_r(struct group *src, char 
*buf, int buflen)... ./confi
gure: line 7388: 
ac_cv_c_prototype_struct_group_pgetgrent_r_struct_group_psrc__char_pbuf__int_buflen
_=no: command not found

checking for prototype struct group *getgrent_r(struct group *src, char 
*buf, size_t buflen)... ./co
nfigure: line 7436: 
ac_cv_c_prototype_struct_group_pgetgrent_r_struct_group_psrc__char_pbuf__size_t_
buflen_=no: command not found

checking for getgrouplist... no
checking ctype.h usability... yes
checking ctype.h presence... yes
checking for ctype.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking langinfo.h usability... yes
checking langinfo.h presence... yes
checking for langinfo.h... yes
checking fnmatch.h usability... yes
checking fnmatch.h presence... yes
checking for fnmatch.h... yes
checking sys/ipc.h usability... yes
checking sys/ipc.h presence... yes
checking for sys/ipc.h... yes
checking sys/mman.h usability... yes
checking sys/mman.h presence... yes
checking for sys/mman.h... yes
checking sys/shm.h usability... yes
checking sys/shm.h presence... yes
checking for sys/shm.h... yes
checking termios.h usability... yes
checking termios.h presence... yes
checking for termios.h... yes
checking termio.h usability... yes
checking termio.h presence... yes
checking for termio.h... yes
checking sys/termio.h usability... yes
checking sys/termio.h presence... yes
checking for sys/termio.h... yes
checking for library containing dlopen... none required
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for dlopen... yes
checking for dlsym... yes
checking for dlerror... yes
checking for dlclose... yes
checking for library containing shl_load... no
checking dl.h usability... no
checking dl.h presence... no
checking for dl.h... no
checking for shl_load... no
checking for shl_unload... no
checking for shl_findsym... no
checking for prototype void *dlopen(const char* filename, unsigned int 
flags)... ./configure: line 7
723: 
ac_cv_c_prototype_void_pdlopen_const_charp_filename__unsigned_int_flags_=no: 
command not found

checking for getpass... yes
checking for getpassphrase... no
checking whether getpass should be replaced... yes
checking whether strptime is available and works... no
checking direct.h usability... no
checking direct.h presence... no
checking for direct.h... no
checking windows.h usability... yes
checking windows.h presence... yes
checking for windows.h... yes
checking winsock2.h usability... no
checking winsock2.h presence... yes
configure: WARNING: winsock2.h: present but cannot be compiled
configure: WARNING: winsock2.h:     check for missing prerequisite headers?
configure: WARNING: winsock2.h: see the Autoconf documentation
configure: WARNING: winsock2.h:     section "Present But Cannot Be Compiled"
configure: WARNING: winsock2.h: proceeding with the compiler's result
checking for winsock2.h... no
checking ws2tcpip.h usability... no
checking ws2tcpip.h presence... yes
configure: WARNING: ws2tcpip.h: present but cannot be compiled
configure: WARNING: ws2tcpip.h:     check for missing prerequisite headers?
configure: WARNING: ws2tcpip.h: see the Autoconf documentation
configure: WARNING: ws2tcpip.h:     section "Present But Cannot Be Compiled"
configure: WARNING: ws2tcpip.h: proceeding with the compiler's result
checking for ws2tcpip.h... no
checking whether mkdir supports mode... yes
checking for timegm... yes
checking for broken readdir... failure: readdir [
Failed for rmdir - 90 = Directory not empty
]
yes
checking for dirfd... yes
checking for dirfd declaration... yes
checking for getdirentries... no
checking for prototype long telldir(const DIR *dir)... ./configure: line 
8033: ac_cv_c_prototype_lon
g_telldir_const_DIR_pdir_=no: command not found

checking for prototype int seekdir(DIR *dir, long ofs)... ./configure: 
line 8077: ac_cv_c_prototype_
int_seekdir_DIR_pdir__long_ofs_=no: command not found

checking for replacing readdir using getdirentries()... no
checking for getdents... no
checking for replacing readdir using getdents()... no
checking a usable readdir()... no
configure: WARNING: the provided readdir() is broken
checking crypt.h usability... yes
checking crypt.h presence... yes
checking for crypt.h... yes
checking for library containing crypt... -lcrypt
checking for CLOCK_MONOTONIC... yes
checking for CLOCK_PROCESS_CPUTIME_ID... no
checking for CLOCK_REALTIME... yes
checking for printf... yes
checking for memset... yes
checking for memcpy... yes
LIBREPLACE_BROKEN_CHECKS: END
checking for mmap... yes
checking for pread... (cached) yes
checking for pwrite... (cached) yes
checking for getpagesize... yes
checking for utime... (cached) yes
checking getopt.h usability... yes
checking getopt.h presence... yes
checking for getopt.h... yes
checking for sys/select.h... (cached) yes
checking for sys/time.h... (cached) yes
checking for pread declaration... yes
checking for pwrite declaration... yes
checking for python2.6-config... no
checking for python2.5-config... no
checking for python2.4-config... no
checking for python-config... no
checking for python2.6... no
checking for python2.5... no
checking for python2.4... no
checking for python... no
checking for xsltproc... /usr/bin/xsltproc
configure: creating ./config.status
config.status: creating Makefile
config.status: WARNING:  'Makefile.in' seems to ignore the --datarootdir 
setting
config.status: creating tdb.pc
config.status: creating include/config.h
config.status: executing rm-stdint.h commands
config.status: executing rm-stdbool.h commands


$ make
tdb will be compiled with flags:
  CFLAGS = -I./include -Iinclude   -I./../replace
  CPPFLAGS = -I./include -Iinclude
  LDFLAGS =
  LIBS =
Compiling tools/tdbtool.c
Compiling common/tdb.c
Compiling common/dump.c
Compiling common/transaction.c
Compiling common/error.c
Compiling common/traverse.c
Compiling common/freelist.c
Compiling common/freelistcheck.c
Compiling common/io.c
Compiling common/lock.c
Compiling common/open.c
Compiling common/check.c
Compiling common/hash.c
Compiling ../replace/replace.c
Compiling ../replace/snprintf.c
Compiling ../replace/getpass.c
Compiling ../replace/strptime.c
ar -rv libtdb.a common/tdb.o common/dump.o common/transaction.o 
common/error.o common/traverse.o com
mon/freelist.o common/freelistcheck.o common/io.o common/lock.o 
common/open.o common/check.o common/
hash.o ./../replace/replace.o ./../replace/snprintf.o 
./../replace/getpass.o ./../replace/strptime.o

ar: creating libtdb.a
a - common/tdb.o
a - common/dump.o
a - common/transaction.o
a - common/error.o
a - common/traverse.o
a - common/freelist.o
a - common/freelistcheck.o
a - common/io.o
a - common/lock.o
a - common/open.o
a - common/check.o
a - common/hash.o
a - ./../replace/replace.o
a - ./../replace/snprintf.o
a - ./../replace/getpass.o
a - ./../replace/strptime.o
gcc -I./include -Iinclude   -I./../replace  -o bin/tdbtool 
tools/tdbtool.o -L. -ltdb
Compiling tools/tdbrestore.c
gcc -I./include -Iinclude   -I./../replace  -o bin/tdbrestore 
tools/tdbrestore.o -L. -ltdb
Compiling tools/tdbdump.c
gcc -I./include -Iinclude   -I./../replace  -o bin/tdbdump 
tools/tdbdump.o -L. -ltdb
Compiling tools/tdbbackup.c
gcc -I./include -Iinclude   -I./../replace  -o bin/tdbbackup 
tools/tdbbackup.o -L. -ltdb
gcc -shared  -o libtdb.so.1.2.6 common/tdb.o common/dump.o 
common/transaction.o common/error.o commo
n/traverse.o common/freelist.o common/freelistcheck.o common/io.o 
common/lock.o common/open.o common
/check.o common/hash.o ./../replace/replace.o ./../replace/snprintf.o 
./../replace/getpass.o ./../re
place/strptime.o    libtdb.so.1
gcc: libtdb.so.1: No such file or directory
make: *** [libtdb.so.1.2.6] Error 1



More information about the Boxbackup mailing list