Description:
To test a code change specific to the client side, I did the following:
1) Run a full build
2) test it: success
3) run a build "--without-server"
4) test it: an NDB test fails because "perror" doesn't handle NDB error codes.
While it is safe to ignore that test failure, it shows a bug in our Makefiles:
"perror" is (AIUI) a tool to explain server error codes, so it should be built with the server only and not with the clients.
This is also the way our RPM spec files handle it: "perror" is part of the "server" RPMs, not the "client" ones.
How to repeat:
configure --without-server ; make
"perror" will be built.
Suggested fix:
Currently, subdirectory "extra" will participate in a make run if either server or client are built.
If this is necessary (not checked), and we don't want to shuffle source files into different directories (I assume so), I propose we should make more use of conditional make, like we already do for InnoDB:
# "innochecksum" should be switched
if BUILD_INNODB_TOOLS
bin_PROGRAMS += innochecksum
endif
In a similar line, we could introduce "BUILD_SERVER" and "BUILD_CLIENT",
use them throughout all our "Makefile.am"s,
and so get rid of the varying list of directories (by client vs server build), rather explicitly control the list of targets.