From: Tomohiro Kusumi Date: Fri, 14 Apr 2017 21:06:23 +0000 (+0300) Subject: Make lib/zipf.c a stand-alone library X-Git-Tag: fio-2.20~38 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=b58e3cee98842a9333de90202dc217e421e6c8f2;ds=sidebyside Make lib/zipf.c a stand-alone library lib/zipf.c not having dependency on fio header (log.h) enables it to be a stand-alone library, which is useful for debugging purpose. In fact, most of the files under lib/ directory do things this way. lib/zipf.c doesn't use log.h (log(3) is apparently from -lm). This requires the previous commit. -- # cat ./test8.c #include #include "lib/zipf.h" int main(void) { /* just to see if it compiles */ zipf_init(NULL, 0, 0, 0); return 0; } # gcc -Wall -g -lm -DBITS_PER_LONG=64 ./test8.c ./lib/zipf.c ./lib/rand.c ./lib/pattern.c ./lib/strntol.c Signed-off-by: Tomohiro Kusumi Signed-off-by: Jens Axboe --- diff --git a/lib/zipf.c b/lib/zipf.c index 681df700..3d535c79 100644 --- a/lib/zipf.c +++ b/lib/zipf.c @@ -6,7 +6,6 @@ #include #include #include "ieee754.h" -#include "../log.h" #include "zipf.h" #include "../minmax.h" #include "../hash.h"