Can't add custom library path while compiling nginx from source on Windows

Francis Daly francis at
Thu Sep 16 22:57:16 UTC 2021

On Wed, Sep 15, 2021 at 11:50:10PM -0400, John Moreira wrote:

Hi there,

> I'm trying to compile nginx from source code on Windows with xslt support.
> I followed all of the directions from the official page
> to a tee and it works
> when I do not specify --with-http_xslt_module
> When specifying --with-http_xslt_module as part of the config, a
> notification appears indicating that I don't have libxlst/.libxml2
> libraries
> checking for libxslt ... not found
> checking for libxslt in /usr/local/ ... not found
> checking for libxslt in /usr/pkg/ ... not found
> checking for libxslt in /opt/local/ ... not found
> auto/configure: error: the HTTP XSLT module requires the libxml2/libxslt
> libraries. You can either do not enable the module or install the libraries.

You can read the file auto/lib/libxslt/conf to get an idea of what nginx
is testing for.

Do you have, for example, the file libxml/parser.h somewhere on your

> I am using MSYS2 as the official page recommends - the packages for
> libxml2/libxslt were already installed.

Did you install the library packages for running programs with; or did
you install the development packages to allow programs be built against
the libraries?

Possibly you want packages with "-dev" or "-devel" in the name, if you
don't already have them.

> How can I get the configure script to see these packages so I can compile
> from source?

The content of and makes it look like it
should Just Work, if both are installed.

If that doesn't happen, then probably auto/lib/libxslt/conf can be
adjusted to let it happen.

Good luck with it,

Francis Daly        francis at

More information about the nginx mailing list