From: Jens Bauer Date: Tue, 28 Oct 2014 04:14:05 +0000 (+0100) Subject: Mac/PPC: Fix build. X-Git-Tag: v0.9.0-rc1~209 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=2eacb8fdfb4ea761acc3a3fbb51d048fefccd9b6;p=openocd Mac/PPC: Fix build. GCC-4.2 on Mac/PPC complains about size_t is expected for %zx and the build stops. In order to avoid other problems, I've chosen simply to typecast. Change-Id: I99b569c4d1100e729712e31d24d6539f8b5971b6 Signed-off-by: Jens Bauer Reviewed-on: http://openocd.zylin.com/2360 Tested-by: jenkins Reviewed-by: Paul Fertser --- diff --git a/src/target/target.c b/src/target/target.c index b74c6a0c..6f458bce 100644 --- a/src/target/target.c +++ b/src/target/target.c @@ -906,7 +906,7 @@ int target_run_flash_async_algorithm(struct target *target, } LOG_DEBUG("offs 0x%zx count 0x%" PRIx32 " wp 0x%" PRIx32 " rp 0x%" PRIx32, - (buffer - buffer_orig), count, wp, rp); + (size_t) (buffer - buffer_orig), count, wp, rp); if (rp == 0) { LOG_ERROR("flash write algorithm aborted by target");