summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
ad231bc)
Loaded ioengines would like to use the logging functions but can't, as
they can't see f_out and f_err. Create get_f_{out,err}() so that
the libraries can dlsym() them. Compile fio with -rdynamic so dlopen()
works.
Signed-off-by: Joel Becker <joel.becker@oracle.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
CC = gcc -W
DEBUGFLAGS = -D_FORTIFY_SOURCE=2
OPTFLAGS= -O2 -g
CC = gcc -W
DEBUGFLAGS = -D_FORTIFY_SOURCE=2
OPTFLAGS= -O2 -g
-CFLAGS = -Wwrite-strings -Wall -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(OPTFLAGS) $(DEBUGFLAGS)
+CFLAGS = -Wwrite-strings -Wall -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(OPTFLAGS) $(DEBUGFLAGS) -rdynamic
PROGS = fio
SCRIPTS = fio_generate_plots
OBJS = gettime.o fio.o ioengines.o init.o stat.o log.o time.o md5.o crc32.o \
PROGS = fio
SCRIPTS = fio_generate_plots
OBJS = gettime.o fio.o ioengines.o init.o stat.o log.o time.o md5.o crc32.o \
fprintf(stderr, ##args); \
} while (0)
fprintf(stderr, ##args); \
} while (0)
+FILE *get_f_out(void);
+FILE *get_f_err(void);
+
struct ioengine_ops {
struct list_head list;
char name[16];
struct ioengine_ops {
struct list_head list;
char name[16];
static int write_lat_log = 0;
int write_bw_log = 0;
static int write_lat_log = 0;
int write_bw_log = 0;
+FILE *get_f_out()
+{
+ return f_out;
+}
+
+FILE *get_f_err()
+{
+ return f_err;
+}
+
/*
* Return a free job structure.
*/
/*
* Return a free job structure.
*/