One of our developers would like to install the Xapian PHP bindings on a Mac OS X laptop, where he runs our site locally. This is the error message, which happens during "make" (NOT configure): checking for g++... g++ checking whether we are using the GNU C++ compiler... yes checking whether g++ accepts -g... yes checking how to run the C++ preprocessor... g++ -E checking for cin in -lstdc++... no configure: error: cannot run /bin/sh ./config.sub make[3]: *** [xapian/php_xapian.la] Error 1 make[2]: *** [all] Error 2 make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2 It seems that the ./configure didn't make the file php4/xapian/config.sub. It isn't there at all. This is the configure line he ran: ./configure --without-java --without-python --without-tcl XAPIAN_CONFIG=/usr/local/bin/xapian-config SWIG=/usr/local/bin/swig This warning it prints (on all operating systems) might be the problem, but I don't understand what it means: : # FIXME: this isn't going to work with an uninstalled libxapian : # The whole "--with-xapian" concept is deeply flawed really cd xapian &&\ ./configure --with-xapian="`echo -I/usr/local/include|sed 's!^-I!!;s!/include$!!'`" &&\ make Thanks for any suggestions or help! Francis -- Undemocratic Europe. Fix it. Vote Martin Bell. http://www.bellforeurope.org.uk
On Wed, May 26, 2004 at 11:24:36AM +0100, Francis Irving wrote:> One of our developers would like to install the Xapian PHP bindings on > a Mac OS X laptop, where he runs our site locally. > > This is the error message, which happens during "make" (NOT > configure): > > checking for g++... g++ > checking whether we are using the GNU C++ compiler... yes > checking whether g++ accepts -g... yes > checking how to run the C++ preprocessor... g++ -E > checking for cin in -lstdc++... no > configure: error: cannot run /bin/sh ./config.sub > make[3]: *** [xapian/php_xapian.la] Error 1 > make[2]: *** [all] Error 2 > make[1]: *** [all-recursive] Error 1 > make: *** [all] Error 2 > > It seems that the ./configure didn't make the file > php4/xapian/config.sub. It isn't there at all. > > This is the configure line he ran: > ./configure --without-java --without-python --without-tcl > XAPIAN_CONFIG=/usr/local/bin/xapian-config SWIG=/usr/local/bin/swigHmm, aren't XAPIAN_CONFIG and SWIG environment variables? I'm a bit rusty on the way autoconf magic works but i think these should go _before_ the invocation of ./configure (so the shell "sees" them): XAPIAN_CONFIG=/usr/local/bin/xapian-config SWIG=/usr/local/bin/swig ./configure --without-java --without-python --without-tcl> This warning it prints (on all operating systems) might be the > problem, but I don't understand what it means: > > : # FIXME: this isn't going to work with an uninstalled libxapian > : # The whole "--with-xapian" concept is deeply flawed really > cd xapian &&\ > ./configure --with-xapian="`echo -I/usr/local/include|sed > 's!^-I!!;s!/include$!!'`" &&\ > makeBasically it means what it says: you can only build/install the Xapian bindings once you have _installed_ the Xapian library, i.e. it's _not_ enough to download and build Xapian core and then give the place where you unpacked/compiled Xapian to '--with-xapian='.> Thanks for any suggestions or help!Hope this helps Ralf Mattes> Francis > -- > Undemocratic Europe. Fix it. Vote Martin Bell. http://www.bellforeurope.org.uk > > _______________________________________________ > Xapian-discuss mailing list > Xapian-discuss@lists.xapian.org > http://lists.xapian.org/mailman/listinfo/xapian-discuss
Francis Irving wrote:> One of our developers would like to install the Xapian PHP bindings on > a Mac OS X laptop, where he runs our site locally. > > This is the error message, which happens during "make" (NOT > configure): > > checking for g++... g++ > checking whether we are using the GNU C++ compiler... yes > checking whether g++ accepts -g... yes > checking how to run the C++ preprocessor... g++ -E > checking for cin in -lstdc++... no > configure: error: cannot run /bin/sh ./config.sub > make[3]: *** [xapian/php_xapian.la] Error 1 > make[2]: *** [all] Error 2 > make[1]: *** [all-recursive] Error 1 > make: *** [all] Error 2 > > It seems that the ./configure didn't make the file > php4/xapian/config.sub. It isn't there at all.I wouldn't expect configure to make the file. In general, it will be found in the distributed files, or created by an invocation of "automake" (with the -a parameter). In this case the file isn't found in the distribution because the php4/xapian/ directory is created as part of the build process. I believe that the phpize tool is responsible for creating the config.sub file. It could be that you have a buggy version of this tool (or it could be that my understanding is flawed). Firstly, I recommend checking that you've got the latest version of this installed, and check further up your output log to see if it reported any errors. If all else fails, you could simply try copying config.sub from somewhere else (eg, the top source directory of the xapian-bindings tarball) to the appropriate location. config.sub is a generic file - copying it should work (but there may be other missing files). -- Richard