If you want to see the debug logging on stdout, there's no need to change the library code, you can just specify `/dev/stdout` as the output log file (`dev/stdout` isn't fully portable, but Linux has it and various other platforms do too):

```
env XAPIAN_DEBUG_LOG=/dev/stdout ./apitest
```