AuthAuthorizeHandler fails to build on s390
Also from Laszlo:
It also fails on s390, on the same file but with a different error message: g++ -DHAVE_CONFIG_H -I. -Wall -D__CEPH__ -D_FILE_OFFSET_BITS=64 -D_REENTRANT -D_THREAD_SAFE -rdynamic -g -O2 -MT AuthAuthorizeHandler.o -MD -MP -MF .deps/AuthAuthorizeHandler.Tpo -c -o AuthAuthorizeHandler.o `test -f 'auth/AuthAuthorizeHandler.cc' || echo './'`auth/AuthAuthorizeHandler.cc In file included from ./msg/msg_types.h:19, from auth/Auth.h:19, from auth/AuthAuthorizeHandler.cc:1: ./include/blobhash.h: In member function 'size_t blobhash::operator()(const char*, unsigned int)': ./include/blobhash.h:42: error: no match for call to '(rjhash<long unsigned int>) (size_t&)' make: *** [AuthAuthorizeHandler.o] Error 1 The full building log can be found on the same location. I would be grateful if someone with more knowledge of Ceph internals can look into them. Regards, Laszlo/GCS  https://buildd.debian.org/fetch.cgi?pkg=ceph&arch=armel&ver=0.24.3-2&stamp=1298712439&file=log&as=raw  https://buildd.debian.org/fetch.cgi?pkg=ceph&arch=s390&ver=0.24.3-2&stamp=1298712185&file=log&as=raw
blobhash: Avoid size_t in templatized hash functions.
On S/390, the earlier rjhash<size_t> failed with
"no match for call to '(rjhash<long unsigned int>) (size_t&)'".
It seems the rjhash<size_T> logic was only enabled
on some architectures, and relied on some pretty deep
internals of the bit layout (LP64).
Use an explicitly 32-bit type as early as possible, and
convert back to size_t only when really needed. This
should work, and simplifies the code. In theory, we might
have a narrower output (size_t might be 64-bit, max value
we now output is 32-bit), but this doesn't matter as this
is only ever used for picking a slot in an in-memory hash
table, hash(key) modulo num_of_buckets, there won't be >4G
Signed-off-by: Tommi Virtanen <firstname.lastname@example.org>