Compiled on X8DTU with 2 physical Intel Xeon E5530 CPU (8C16T)

Compile Flags:
# require '-fexceptions'
# IMPORTANT
# DON"T USE -fno-rtti
# or the downstream packages wouldn't build
# that's asking for trouble in the long run
CFLAGS='-mtune=generic -Os -pipe -fuse-linker-plugin -flto'
CXXFLAGS='-mtune=generic -Os -pipe -fuse-linker-plugin -flto'
LDFLAGS='-Wl,-O1'
export CFLAGS CXXFLAGS LDFLAGS

Dependencies:
autoconf
autogen-dev
automake
compiletc
apr-util-dev

Commands:

tar xf apache-log4cxx-0.11.0.tar.gz

cd apache-log4cxx-0.11.0

# IMPORTANT
# Don't do "mkdir build && cd build"
# It took me hours to realize that

# required
./autogen.sh

./configure --prefix=/usr/local --with-gnu-ld --disable-html-docs --with-charset=iso-8859-1

time make -j15
real    0m 38.25s
user    7m 25.26s
sys     0m 40.31s

make DESTDIR=/tmp/log4cxx install

make DESTDIR=/tmp/d-log4cxx install

# fix .la before packing
sed 's:lib/../lib:lib:g' -i /tmp/d-log4cxx/usr/local/lib/liblog4cxx.la