[Xapian-discuss] Xapian 0.9.5, Cygwin and xapian-config
Patrick Mézard
pmezard at gmail.com
Mon May 8 21:56:29 BST 2006
Olly Betts wrote:
> On Mon, May 08, 2006 at 09:35:20PM +0200, Patrick M?zard wrote:
>
>> Do you know any short term workaround to remove or disable the "&"
>> substitution ?
>>
>>>> s, at ldflags@,-Wl&--enable-runtime-pseudo-reloc,;t t
>>>>
>
> Hand edit config.status and change that "&" to "\,", then save, and run
> "./config.status" from the shell prompt. Hopefully that will complete
> and you can then run "make", etc as if "./configure" had just worked.
>
Ok, the "&" generation can be avoided by rewriting the configure section
from line 20073 to line 20083 and removing the commas between "-Wl" and
"$ldflags" like:
"""
ldflags=
if test yesyes = "$GXX$enable_shared" ; then
case $host_os in
*mingw* | *cygwin*)
ldflags="--enable-runtime-pseudo-reloc"
if $CXX -Wl $ldflags 2>&1 >/dev/null|grep -e $ldflags >/dev/null
2>&1; then
{ { echo "$as_me:$LINENO: error: ld
version too old to support a shared build - configure with
--disable-shared, or install binutils 2.13.90-20030111-1 or later" >&5
echo "$as_me: error: ld version too old to support a shared build -
configure with --disable-shared, or install binutils 2.13.90-20030111-1
or later" >&2;}
{ (exit 1); exit 1; }; }
fi
ldflags="-Wl $ldflags"
;;
esac
fi
"""
xapian-config then generates immediatly.
Then I got another error : make cannot find any rule to build
xapian-config.1. This is because I am not compiling in "maintainer mode"
and therefore xapian-config.1 generation is skipped, see Makefile.in bottom:
"""
@MAINTAINER_MODE_TRUE at xapian-config.1: xapian-config
@MAINTAINER_MODE_TRUE@ $(HELP2MAN) -o xapian-config.1 --no-info -S
"$(PACKAGE_STRING)" -n "`sed 's/^PROG_DESC=\"\(.*\)\".*/\1/p;d'
$(srcdir)/xapian-config`" ./xapian-config
"""
Unfortunately, xapian-config.1 is referenced by "man_MANS" which is left
uncommented and triggers the make error. I solved it manually by editing
directly the generated Makefile. I guess the following section should be
compiled conditionally (Makefile.in (291)):
"""
man_MANS = xapian-config.1
MAINTAINERCLEANFILES = $(man_MANS)
"""
But it might trigger other dependency errors...
Now, it is libtool turn to complain:
"""
make[2]: Entering directory
`/c/dev/mz/libs/xapian/xapian-core-0.9.5/examples'
/bin/sh ../libtool --tag=CXX --mode=link g++ -Wall -W -Wredundant-decls
-Wundef
-Wpointer-arith -Wcast-qual -Wcast-align -Wno-multichar -Wno-long-long
-fno-gnu-
keywords -g -O2 -o quest.exe quest.o -Wl
--enable-runtime-pseudo-reloc ../get
opt/libgetopt.la ../libxapian.la
g++ -Wall -W -Wredundant-decls -Wundef -Wpointer-arith -Wcast-qual
-Wcast-align
-Wno-multichar -Wno-long-long -fno-gnu-keywords -g -O2 -o
.libs/quest.exe quest.
o -Wl --enable-runtime-pseudo-reloc ../getopt/.libs/libgetopt.a
../.libs/libxap
ian.dll.a -L/usr/local/lib
Info: resolving vtable for Xapian::SimpleStopperby linking to
__imp___ZTVN6Xapia
n13SimpleStopperE (auto-import)
Info: resolving vtable for Xapian::Stopperby linking to
__imp___ZTVN6Xapian7Stop
perE (auto-import)
quest.o(.text+0x84): In function `main':
c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include/xapian/queryparser.h
:60: variable 'vtable for Xapian::SimpleStopper' can't be auto-imported.
Please
read the documentation for ld's --enable-auto-import for details.
quest.o(.text+0x340):c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include
/xapian/queryparser.h:78: variable 'vtable for Xapian::SimpleStopper'
can't be a
uto-imported. Please read the documentation for ld's
--enable-auto-import for de
tails.
quest.o(.text+0xf3c):c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include
/xapian/queryparser.h:78: variable 'vtable for Xapian::SimpleStopper'
can't be a
uto-imported. Please read the documentation for ld's
--enable-auto-import for de
tails.
quest.o(.text+0x29b):c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include
/xapian/queryparser.h:42: variable 'vtable for Xapian::Stopper' can't be
auto-im
ported. Please read the documentation for ld's --enable-auto-import for
details.
quest.o(.text+0x2d3):c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include
/xapian/queryparser.h:42: variable 'vtable for Xapian::Stopper' can't be
auto-im
ported. Please read the documentation for ld's --enable-auto-import for
details.
quest.o(.text+0x370):c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include
/xapian/queryparser.h:42: variable 'vtable for Xapian::Stopper' can't be
auto-im
ported. Please read the documentation for ld's --enable-auto-import for
details.
quest.o(.text+0xf60):c:/dev/mz/libs/xapian/xapian-core-0.9.5/examples/../include
/xapian/queryparser.h:42: variable 'vtable for Xapian::Stopper' can't be
auto-im
ported. Please read the documentation for ld's --enable-auto-import for
details.
collect2: ld returned 1 exit status
make[2]: *** [quest.exe] Error 1
make[2]: Leaving directory
`/c/dev/mz/libs/xapian/xapian-core-0.9.5/examples'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/c/dev/mz/libs/xapian/xapian-core-0.9.5'
make: *** [all] Error 2
"""
Removing the examples from build targets solves this but you may be
interested by this issue. I would be happy to help but right now I
prefer to get xapian python bindings to compile.
Thank you for your help, I will try the bindings right now.
--
Patrick Mézard
More information about the Xapian-discuss
mailing list