...
/home/mysqldev/rpm/BUILD/mysql-5.0.27/libmysql/my_compress.c:58: undefined reference to `compress'
...
/home/mysqldev/rpm/BUILD/mysql-5.0.27/libmysql/my_compress.c:85: undefined reference to `uncompress'
...
"undefined reference" means that linker was unable to resolve (=find) functions "compress" and "decompress" in all given libraries - mysql probably use them for client/server protocol compression.
Next steps can vary:
1) search google: "mysql undefined reference compress uncompress" will take you to the
http://dev.mysql.com/doc/refman/5.0/en/link-errors.html,'>
http://dev.mysql.com/doc/refman/5.0/en/link-errors.html, "Problems Linking to the MySQL Client Library" with solution: "If you get undefined reference errors for the uncompress or compress function, add -lz to the end of your link command and try again."
2) grep *.so/*.a files in your /usr/lib (/lib, etc) for missing symbol. You can later check exact library using "nm" tool:
alk@ns$ nm libz.a | grep "T compress"
000000a4 T compress
00000000 T compress2
"T" means that this function exist in this exact library.