ECToo / xdelta

Automatically exported from code.google.com/p/xdelta
0 stars 0 forks source link

Freeze (race condition) when using compressed files #141

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I use xdelta3 on my backups. Yesterday's backup got stuck.
It looks like one of the xdelta3's decompress processes have exited.
The xdelta3 main process waits on the other one.
The second xdelta3 decompress process is trying to write data, but it's pipe 
buffer is full.

What steps will reproduce the problem?
# pstree
bash,29783 -c set -o pipefail && xdelta3 -s "$1" "$2" /dev/stdout | gpg 
<SECRETS> -- backup-20120708_051428_mysql.tar.xz 
backup-20120709_051439_mysql.tar.xz
  ├─gpg,29785 <SECRETS>
  └─xdelta3,29784 -s backup-20120708_051428_mysql.tar.xz backup-20120709_051439_mysql.tar.xz /dev/stdout
      ├─xdelta3,29787 -s backup-20120708_051428_mysql.tar.xz backup-20120709_051439_mysql.tar.xz /dev/stdout
      ├─(xdelta3,29790)
      ├─xz,29786 -dc
      └─(xz,29789)

# strace -p 29785
Process 29785 attached - interrupt to quit
read(0, ^C <unfinished ...>

# strace -p 29784
Process 29784 attached - interrupt to quit
wait4(29786,

# strace -p 29786
Process 29786 attached - interrupt to quit
write(1, 
"\4\207\370\4\0\0\0\24\0\0\0\0\4\207\367\360\0\0\0\0\4\207\370\30\0\0\0\30\0\0\0
\0"..., 8192

What version of the product are you using? On what operating system?
  Debian 6.0 Squeeze with 3.0.0.dfsg-1 (not the one in stable repos; had some similar problems with that one and tried upgrading)

Original issue reported on code.google.com by stevie.t...@gmail.com on 10 Jul 2012 at 9:58

GoogleCodeExporter commented 9 years ago
I've now tried the running xdelta3 three times on these files, and it froze 
each time (when I had similar problems with earlier versions, it worked to just 
run xdelta3 again).

The output file is ~1G. Normally they are ~20M. I think my friend ran some 
commands to optimize the tables, reorganizing the data.
666M    backup-20120708_051428_mysql.tar.xz
601M    backup-20120709_051439_mysql.tar.xz

I can't give away the reproducing files since they have lots of user data in 
them :(

Original comment by stevie.t...@gmail.com on 11 Jul 2012 at 8:37

GoogleCodeExporter commented 9 years ago
I believe the issue is fixed in the latest SVN 361 (same as reported in issue 
132).  Can you try it?

Original comment by josh.mac...@gmail.com on 12 Jul 2012 at 7:20

GoogleCodeExporter commented 9 years ago
Yes, now it exited!

gcc (4.4.5 from Debian) complained that it didn't know size sa
2175   struct sigaction sa;

And kill() was undefined.

Also lots of format string warnings ("%lld expects long long int, got xoff_t" 
etc)

Tests also failed to compile, so I skipped them.

Original comment by stevie.t...@gmail.com on 12 Jul 2012 at 9:56

GoogleCodeExporter commented 9 years ago
Thanks.  The sigaction issue has been reported.  Can you send me a compiler 
transcript?  I do most of my development on OS X these days, but I suppose I 
can sneak into someone's Linux box to get these compilation matters resolved.

Original comment by josh.mac...@gmail.com on 13 Jul 2012 at 6:00

GoogleCodeExporter commented 9 years ago
Ok, first I had to remove some symlinks to have autoreconf run:

py-compile
ltmain.sh
m4/libtool.m4
m4/lt~obsolete.m4
m4/ltoptions.m4
m4/ltsugar.m4
m4/ltversion.m4

Debian's autotools were too old so ran them on another box.

$ ./configure
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking how to print strings... printf
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
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 a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to 
x86_64-unknown-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-unknown-linux-gnu file names to toolchain 
format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking for gawk... gawk
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -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 for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared 
libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU
checking how to create a ustar tar archive... gnutar
checking dependency style of gcc... gcc3
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking how to run the C++ preprocessor... g++ -E
checking for ld used by g++... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared 
libraries... yes
checking for g++ option to produce PIC... -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works... yes
checking if g++ static flag -static works... yes
checking if g++ supports -c -o file.o... yes
checking if g++ supports -c -o file.o... (cached) yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared 
libraries... yes
checking dynamic linker characteristics... (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking dependency style of g++... gcc3
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: executing libtool commands
config.status: executing depfiles commands

$ make 
(CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash 
/home/cnu/xdelta/xdelta-read-only/missing --run autoheader)
aclocal.m4:16: warning: this file was generated for autoconf 2.68.
You have another version of autoconf.  It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
To do so, use the procedure documented by the package, typically `autoreconf'.
configure.ac:3: error: Autoconf version 2.68 or higher is required
configure.ac:3: the top level
autom4te: /usr/bin/m4 failed with exit status: 63
autoheader2.50: '/usr/bin/autom4te' failed with exit status: 63
WARNING: `autoheader' is probably too old.  You should only need it if
         you modified `acconfig.h' or `configure.ac'.  You might want
         to install the `Autoconf' and `GNU m4' packages.  Grab them
         from any GNU archive site.
rm -f stamp-h1
touch config.h.in
cd . && /bin/bash ./config.status config.h
config.status: creating config.h
config.status: config.h is unchanged
make  all-am
make[1]: Entering directory `/home/cnu/xdelta/xdelta-read-only'
gcc -DHAVE_CONFIG_H -I.    -Wall -Wshadow -fno-builtin -Wextra -Wsign-compare 
-Wextra -Wno-unused-parameter -DGENERIC_ENCODE_TABLES=0 -DREGRESSION_TEST=1 
-DSECONDARY_DJW=1 -DSECONDARY_FGK=1 -DXD3_POSIX=1 -DXD3_USE_LARGEFILE64=1 
-DXD3_MAIN=1 -pedantic -std=c99 -g -O2 -MT xdelta3-xdelta3.o -MD -MP -MF 
.deps/xdelta3-xdelta3.Tpo -c -o xdelta3-xdelta3.o `test -f 'xdelta3.c' || echo 
'./'`xdelta3.c
In file included from xdelta3-main.h:330,
                 from xdelta3.c:771:
xdelta3-blkcache.h: In function ‘main_set_source’:
xdelta3-blkcache.h:244: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 5 has type ‘xoff_t’
xdelta3-blkcache.h: In function ‘main_read_seek_source’:
xdelta3-blkcache.h:366: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:366: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-blkcache.h:386: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:416: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:416: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-blkcache.h: In function ‘main_getblk_func’:
xdelta3-blkcache.h:536: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:536: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-blkcache.h:542: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:548: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
In file included from xdelta3.c:771:
xdelta3-main.h: In function ‘main_format_bcnt’:
xdelta3-main.h:599: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
In file included from xdelta3.c:771:
xdelta3-main.h: In function ‘main_print_window’:
xdelta3-main.h:1263: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:1274: warning: format ‘%06llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1288: warning: format ‘%-6llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1316: warning: format ‘%-6llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1333: warning: format ‘%06llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h: In function ‘main_print_func’:
xdelta3-main.h:1453: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1479: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1487: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
In file included from xdelta3.c:771:
xdelta3-main.h: In function ‘main_external_compression_cleanup’:
xdelta3-main.h:2151: warning: implicit declaration of function ‘kill’
xdelta3-main.h: In function ‘main_pipe_copier’:
xdelta3-main.h:2175: error: storage size of ‘sa’ isn’t known
xdelta3-main.h:2177: warning: implicit declaration of function ‘sigaction’
xdelta3-main.h:2216: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:2175: warning: unused variable ‘sa’
xdelta3-main.h: In function ‘main_input’:
xdelta3-main.h:3260: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3260: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3274: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3304: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3315: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3405: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3405: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3407: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3407: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3408: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3408: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3409: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3409: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3423: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3423: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
In file included from xdelta3.c:775:
xdelta3-test.h: In function ‘compare_files’:
xdelta3-test.h:418: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-test.h: In function ‘test_command_line_arguments’:
xdelta3-test.h:1775: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-test.h:1775: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 5 has type ‘xoff_t’
xdelta3-test.h: In function ‘test_string_matching’:
xdelta3-test.h:2598: warning: format ‘%lld’ expects type ‘long long 
int’, but argument 4 has type ‘xoff_t’
make[1]: *** [xdelta3-xdelta3.o] Error 1
make[1]: Leaving directory `/home/cnu/xdelta/xdelta-read-only'
make: *** [all] Error 2

After adding #include <signal.h> and _GNU_SOURCE (it looks like sigaction needs 
one of them: "sigaction(): _POSIX_C_SOURCE >= 1 || _XOPEN_SOURCE || 
_POSIX_SOURCE").
I think this one wants stdint.h/inttypes.h

$ make
make  all-am
make[1]: Entering directory `/home/cnu/xdelta/xdelta-read-only'
gcc -DHAVE_CONFIG_H -I.    -Wall -Wshadow -fno-builtin -Wextra -Wsign-compare 
-Wextra -Wno-unused-parameter -DGENERIC_ENCODE_TABLES=0 -DREGRESSION_TEST=1 
-DSECONDARY_DJW=1 -DSECONDARY_FGK=1 -DXD3_POSIX=1 -DXD3_USE_LARGEFILE64=1 
-DXD3_MAIN=1 -pedantic -std=c99 -D_GNU_SOURCE -g -O2 -MT xdelta3-xdelta3.o -MD 
-MP -MF .deps/xdelta3-xdelta3.Tpo -c -o xdelta3-xdelta3.o `test -f 'xdelta3.c' 
|| echo './'`xdelta3.c
In file included from xdelta3-main.h:330,
                 from xdelta3.c:771:
xdelta3-blkcache.h: In function ‘main_set_source’:
xdelta3-blkcache.h:244: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 5 has type ‘xoff_t’
xdelta3-blkcache.h: In function ‘main_read_seek_source’:
xdelta3-blkcache.h:366: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:366: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-blkcache.h:386: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:416: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:416: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-blkcache.h: In function ‘main_getblk_func’:
xdelta3-blkcache.h:536: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:536: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-blkcache.h:542: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-blkcache.h:548: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
In file included from xdelta3.c:771:
xdelta3-main.h: In function ‘main_format_bcnt’:
xdelta3-main.h:599: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
In file included from xdelta3.c:771:
xdelta3-main.h: In function ‘main_print_window’:
xdelta3-main.h:1263: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:1274: warning: format ‘%06llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1288: warning: format ‘%-6llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1316: warning: format ‘%-6llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1333: warning: format ‘%06llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h: In function ‘main_print_func’:
xdelta3-main.h:1453: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1479: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-main.h:1487: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
In file included from xdelta3.c:771:
xdelta3-main.h: In function ‘main_pipe_copier’:
xdelta3-main.h:2216: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h: In function ‘main_input’:
xdelta3-main.h:3260: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3260: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3274: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3304: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3315: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3405: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3405: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3407: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3407: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3408: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3408: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3409: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
xdelta3-main.h:3409: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3423: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 3 has type ‘xoff_t’
xdelta3-main.h:3423: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
In file included from xdelta3.c:775:
xdelta3-test.h: In function ‘compare_files’:
xdelta3-test.h:418: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-test.h: In function ‘test_command_line_arguments’:
xdelta3-test.h:1775: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 4 has type ‘xoff_t’
xdelta3-test.h:1775: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 5 has type ‘xoff_t’
xdelta3-test.h: In function ‘test_string_matching’:
xdelta3-test.h:2598: warning: format ‘%lld’ expects type ‘long long 
int’, but argument 4 has type ‘xoff_t’
mv -f .deps/xdelta3-xdelta3.Tpo .deps/xdelta3-xdelta3.Po
/bin/bash ./libtool --tag=CC   --mode=link gcc -Wall -Wshadow -fno-builtin 
-Wextra -Wsign-compare -Wextra -Wno-unused-parameter -DGENERIC_ENCODE_TABLES=0 
-DREGRESSION_TEST=1 -DSECONDARY_DJW=1 -DSECONDARY_FGK=1 -DXD3_POSIX=1 
-DXD3_USE_LARGEFILE64=1 -DXD3_MAIN=1 -pedantic -std=c99 -D_GNU_SOURCE -g -O2   
-o xdelta3  xdelta3-xdelta3.o  
g++ -DHAVE_CONFIG_H -I.    -Wall -Wshadow -fno-builtin -Wextra -Wsign-compare 
-Wextra -Wno-unused-parameter -DGENERIC_ENCODE_TABLES=0 -DREGRESSION_TEST=1 
-DSECONDARY_DJW=1 -DSECONDARY_FGK=1 -DXD3_POSIX=1 -DXD3_USE_LARGEFILE64=1 
-DXD3_MAIN=1 -DNOT_MAIN=1 -DXD3_DEBUG=1 -g -O2 -MT xdelta3regtest-regtest.o -MD 
-MP -MF .deps/xdelta3regtest-regtest.Tpo -c -o xdelta3regtest-regtest.o `test 
-f 'testing/regtest.cc' || echo './'`testing/regtest.cc
In file included from /usr/include/c++/4.4/ext/hash_map:60,
                 from testing/test.h:60,
                 from testing/regtest.cc:2:
/usr/include/c++/4.4/backward/backward_warning.h:28:2: warning: #warning This 
file includes at least one deprecated or antiquated header which may be removed 
without further notice at a future date. Please use a non-deprecated interface 
with equivalent functionality instead. For a listing of replacement headers and 
interfaces, consult the file backward_warning.h. To disable this warning use 
-Wno-deprecated.
In file included from testing/regtest.cc:3:
testing/random.h: In member function ‘uint32_t 
MTRandom::ExpRand32(uint32_t)’:
testing/random.h:63: error: ‘UINT32_MAX’ was not declared in this scope
testing/random.h: In member function ‘uint64_t 
MTRandom::ExpRand64(uint64_t)’:
testing/random.h:74: error: ‘UINT32_MAX’ was not declared in this scope
testing/regtest.cc: In member function ‘void 
Regtest<Constants>::TestRandomNumbers()’:
testing/regtest.cc:227: error: ‘UINT32_MAX’ was not declared in this scope
testing/regtest.cc: In function ‘void MainTest() [with T = SmallBlock]’:
testing/regtest.cc:875:   instantiated from here
testing/regtest.cc:846: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
testing/regtest.cc: In function ‘void MainTest() [with T = MixedBlock]’:
testing/regtest.cc:876:   instantiated from here
testing/regtest.cc:846: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
testing/regtest.cc: In function ‘void MainTest() [with T = PrimeBlock]’:
testing/regtest.cc:877:   instantiated from here
testing/regtest.cc:846: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
testing/regtest.cc: In function ‘void MainTest() [with T = OversizeBlock]’:
testing/regtest.cc:878:   instantiated from here
testing/regtest.cc:846: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
testing/regtest.cc: In function ‘void MainTest() [with T = LargeBlock]’:
testing/regtest.cc:879:   instantiated from here
testing/regtest.cc:846: warning: format ‘%llu’ expects type ‘long long 
unsigned int’, but argument 2 has type ‘xoff_t’
make[1]: *** [xdelta3regtest-regtest.o] Error 1
make[1]: Leaving directory `/home/cnu/xdelta/xdelta-read-only'
make: *** [all] Error 2

Original comment by stevie.t...@gmail.com on 13 Jul 2012 at 7:37

GoogleCodeExporter commented 9 years ago
I've tested a build on a very recent Ubuntu w/ gcc-4.6.  It required defining 
_POSIX_SOURCE, _ISOC99_SOURCE, etc.  Please try release 3.0.3 and let me know 
if you're still having trouble.  Thank you.

Original comment by josh.mac...@gmail.com on 15 Jul 2012 at 10:32