How to build xapian 1.4.10 with MSVC2017

Olly Betts olly at survex.com
Wed Feb 20 02:33:48 GMT 2019


On Wed, Feb 20, 2019 at 09:53:56AM +0800, 烛秋 wrote:
> hi, I have read the install document,https://github.com/xapian/xapian/blob/v1.4.10/xapian-core/INSTALL,but don't how to build xapian project by MSVC.
> I execute command in mingw64.exe: ./configure CC="cl -nologo" CXX="$PWD/compile cl -nologo" CXXFLAGS=-EHsc AR=lib
> has some errors: 
> # ./configure CC="cl -nologo" CXX="$PWD/compile cl -nologo" CXXFLAGS=-EHsc AR=lib
> configure: loading site script /mingw64/etc/config.site
> checking for a BSD-compatible install... /usr/bin/install -c
> checking whether build environment is sane... yes
> checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
> checking for gawk... gawk
> checking whether make sets $(MAKE)... no
> checking whether make supports nested variables... no
> checking whether UID '1492654' is supported by ustar format... yes
> checking whether GID '1049089' is supported by ustar format... yes
> checking how to create a ustar tar archive... pax
> checking for style of include used by make... none
> checking for gcc... cl -nologo
> checking whether the C compiler works... no
> configure: error: in `/d/xapian_proj/xapian-core-1.4.10':
> configure: error: C compiler cannot create executables

Is "cl" found on your PATH?  To check you can try just running

cl /?

which should give the command line help.

If it says it can't find the command, make sure you've run the "vcvars"
batch file (also described in INSTALL).

> See `config.log' for more details

If "cl /?" does work, look in config.log to see why configure decided
the compiler doesn't work.

Cheers,
    Olly



More information about the Xapian-discuss mailing list