How compile sample libxslt program?

What are the command I use to compile the sample program at the bottom of the page of libxslt Tutorial?

Here are my attempts:

g++ -c libxslt_tutorial.cpp -I/usr/include/libxml2
g++ libxslt_tutorial.o -l xslt -l xml

Here are the errors I get when I try these with cygwin/bash on windows:

In file included from libxslt_tutorial.cpp:45:
/usr/include/libxml2/libxml/DOCBparser.h:22:2: warning: #warning "The DOCBparser module has been deprecated in libxml2-2.6.0"
libxslt_tutorial.o:libxslt_tutorial.cpp:(.text+0x1d8): undefined reference to `_xmlLoadExtDtdDefaultValue'
collect2: ld returned 1 exit status

Thanks,
Siegfried

Try -lxml2