Skip to content

Instantly share code, notes, and snippets.

@tejasvi
Last active March 26, 2019 13:33
Show Gist options
  • Save tejasvi/9f36e2cc371b9331ff2b3eec279f1212 to your computer and use it in GitHub Desktop.
Save tejasvi/9f36e2cc371b9331ff2b3eec279f1212 to your computer and use it in GitHub Desktop.
PYTHONPATH=/home/tejasvi/xapian/build/xapian-bindings/python/ python2 code/python/script.py data.csv db
_____________________________________________________
# script output
_____________________________________________________
Traceback (most recent call last):
File "code/python/index1.py", line 6, in <module>
import xapian
File "/home/tejasvi/xapian/build/xapian-bindings/python/xapian/__init__.py", line 29, in <module>
from . import _xapian
ImportError: cannot import name _xapian
_____________________________________________________
#Also while building bindings, trailing output:
_____________________________________________________
`cp `test -f xapian.py || echo '/home/tejasvi/xapian/xapian-bindings/python/'`xapian.py xapian/__init__.py
/bin/mkdir -p xapian
/bin/bash ../libtool --config > libtoolconfig.tmp
. ./libtoolconfig.tmp; cp $objdir/_xapian xapian
rm -f libtoolconfig.tmp
/usr/bin/python2 -c 'import os;os.chdir("xapian");import _xapian'
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named _xapian
make[1]: *** [Makefile:1291: xapian/__init__.pyc] Error 1
make[1]: Leaving directory '/home/tejasvi/xapian/build/xapian-bindings/python'
make: *** [Makefile:681: all] Error 2
`
_____________________________________________________
Full output:
_____________________________________________________
`make
/usr/bin/python2 /home/tejasvi/xapian/xapian-bindings/python/doxy2swig.py ../doxygen-xml/index.xml doccomments.i
parsing file: ../doxygen-xml/classXapian_1_1AssertionError.xml
parsing file: ../doxygen-xml/classXapian_1_1BB2Weight.xml
parsing file: ../doxygen-xml/classXapian_1_1BM25PlusWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1BM25Weight.xml
parsing file: ../doxygen-xml/classXapian_1_1BoolWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1Centroid.xml
parsing file: ../doxygen-xml/classXapian_1_1Cluster.xml
parsing file: ../doxygen-xml/classXapian_1_1Clusterer.xml
parsing file: ../doxygen-xml/classXapian_1_1ClusterSet.xml
parsing file: ../doxygen-xml/classXapian_1_1Compactor.xml
parsing file: ../doxygen-xml/structXapian_1_1Internal_1_1constinfo.xml
parsing file: ../doxygen-xml/classXapian_1_1CoordWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1CosineDistance.xml
parsing file: ../doxygen-xml/classXapian_1_1Database.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseClosedError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseCorruptError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseCreateError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseLockError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseModifiedError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseNotFoundError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseOpeningError.xml
parsing file: ../doxygen-xml/classXapian_1_1DatabaseVersionError.xml
parsing file: ../doxygen-xml/classXapian_1_1DateRangeProcessor.xml
parsing file: ../doxygen-xml/classXapian_1_1DecreasingValueWeightPostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1DiceCoeffWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1Diversify.xml
parsing file: ../doxygen-xml/classXapian_1_1DLHWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1DocNotFoundError.xml
parsing file: ../doxygen-xml/classXapian_1_1Document.xml
parsing file: ../doxygen-xml/classXapian_1_1DocumentSet.xml
parsing file: ../doxygen-xml/classXapian_1_1DPHWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1DummyFreqSource.xml
parsing file: ../doxygen-xml/classXapian_1_1Enquire.xml
parsing file: ../doxygen-xml/classXapian_1_1Error.xml
parsing file: ../doxygen-xml/classXapian_1_1ESet.xml
parsing file: ../doxygen-xml/classXapian_1_1ESetIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1ExpandDecider.xml
parsing file: ../doxygen-xml/classXapian_1_1ExpandDeciderAnd.xml
parsing file: ../doxygen-xml/classXapian_1_1ExpandDeciderFilterPrefix.xml
parsing file: ../doxygen-xml/classXapian_1_1ExpandDeciderFilterTerms.xml
parsing file: ../doxygen-xml/classXapian_1_1FeatureUnavailableError.xml
parsing file: ../doxygen-xml/classXapian_1_1FieldProcessor.xml
parsing file: ../doxygen-xml/classXapian_1_1FixedWeightPostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1FreqSource.xml
parsing file: ../doxygen-xml/classXapian_1_1GreatCircleMetric.xml
parsing file: ../doxygen-xml/classXapian_1_1IfB2Weight.xml
parsing file: ../doxygen-xml/classXapian_1_1IneB2Weight.xml
parsing file: ../doxygen-xml/classXapian_1_1InL2Weight.xml
parsing file: ../doxygen-xml/structXapian_1_1ValueCountMatchSpy_1_1Internal.xml
parsing file: ../doxygen-xml/classXapian_1_1Query_1_1Internal.xml
parsing file: ../doxygen-xml/classXapian_1_1InternalError.xml
parsing file: ../doxygen-xml/classXapian_1_1InvalidArgumentError.xml
parsing file: ../doxygen-xml/classXapian_1_1InvalidOperationError.xml
parsing file: ../doxygen-xml/classXapian_1_1InvertedQuery__.xml
parsing file: ../doxygen-xml/classXapian_1_1KeyMaker.xml
parsing file: ../doxygen-xml/structXapian_1_1MultiValueKeyMaker_1_1KeySpec.xml
parsing file: ../doxygen-xml/classXapian_1_1KMeans.xml
parsing file: ../doxygen-xml/structXapian_1_1LatLongCoord.xml
parsing file: ../doxygen-xml/classXapian_1_1LatLongCoords.xml
parsing file: ../doxygen-xml/classXapian_1_1LatLongCoordsIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1LatLongDistanceKeyMaker.xml
parsing file: ../doxygen-xml/classXapian_1_1LatLongDistancePostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1LatLongMetric.xml
parsing file: ../doxygen-xml/classXapian_1_1LCDClusterer.xml
parsing file: ../doxygen-xml/classXapian_1_1LMWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1LogicError.xml
parsing file: ../doxygen-xml/classXapian_1_1MatchDecider.xml
parsing file: ../doxygen-xml/classXapian_1_1MatchSpy.xml
parsing file: ../doxygen-xml/classXapian_1_1MSet.xml
parsing file: ../doxygen-xml/classXapian_1_1MSetIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1MultiValueKeyMaker.xml
parsing file: ../doxygen-xml/classXapian_1_1NetworkError.xml
parsing file: ../doxygen-xml/classXapian_1_1NetworkTimeoutError.xml
parsing file: ../doxygen-xml/classXapian_1_1NumberRangeProcessor.xml
parsing file: ../doxygen-xml/classXapian_1_1PL2PlusWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1PL2Weight.xml
parsing file: ../doxygen-xml/classXapian_1_1Point.xml
parsing file: ../doxygen-xml/classXapian_1_1PointType.xml
parsing file: ../doxygen-xml/classXapian_1_1PositionIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1PostingIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1PostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1Query.xml
parsing file: ../doxygen-xml/classXapian_1_1QueryParser.xml
parsing file: ../doxygen-xml/classXapian_1_1QueryParserError.xml
parsing file: ../doxygen-xml/classXapian_1_1RangeError.xml
parsing file: ../doxygen-xml/classXapian_1_1RangeProcessor.xml
parsing file: ../doxygen-xml/classXapian_1_1Registry.xml
parsing file: ../doxygen-xml/classXapian_1_1RSet.xml
parsing file: ../doxygen-xml/classXapian_1_1RuntimeError.xml
parsing file: ../doxygen-xml/classXapian_1_1SerialisationError.xml
parsing file: ../doxygen-xml/classXapian_1_1Similarity.xml
parsing file: ../doxygen-xml/classXapian_1_1SimpleStopper.xml
parsing file: ../doxygen-xml/classXapian_1_1Stem.xml
parsing file: ../doxygen-xml/classXapian_1_1StemImplementation.xml
parsing file: ../doxygen-xml/classXapian_1_1StemStopper.xml
parsing file: ../doxygen-xml/classXapian_1_1Stopper.xml
parsing file: ../doxygen-xml/classXapian_1_1TermGenerator.xml
parsing file: ../doxygen-xml/classXapian_1_1TermIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1TermListGroup.xml
parsing file: ../doxygen-xml/classXapian_1_1TfIdfWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1TradWeight.xml
parsing file: ../doxygen-xml/classXapian_1_1UnimplementedError.xml
parsing file: ../doxygen-xml/classXapian_1_1UnitRangeProcessor.xml
parsing file: ../doxygen-xml/classXapian_1_1Utf8Iterator.xml
parsing file: ../doxygen-xml/classXapian_1_1ValueCountMatchSpy.xml
parsing file: ../doxygen-xml/classXapian_1_1ValueIterator.xml
parsing file: ../doxygen-xml/classXapian_1_1ValueMapPostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1ValuePostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1ValueSetMatchDecider.xml
parsing file: ../doxygen-xml/classXapian_1_1ValueWeightPostingSource.xml
parsing file: ../doxygen-xml/classXapian_1_1Weight.xml
parsing file: ../doxygen-xml/classXapian_1_1WildcardError.xml
parsing file: ../doxygen-xml/classXapian_1_1WritableDatabase.xml
parsing file: ../doxygen-xml/namespacestd.xml
parsing file: ../doxygen-xml/namespaceXapian.xml
parsing file: ../doxygen-xml/namespaceXapian_1_1Internal.xml
parsing file: ../doxygen-xml/namespaceXapian_1_1Remote.xml
parsing file: ../doxygen-xml/namespaceXapian_1_1Unicode.xml
parsing file: ../doxygen-xml/namespaceXapian_1_1Unicode_1_1Internal.xml
parsing file: ../doxygen-xml/error_8h.xml
parsing file: ../doxygen-xml/version_8h.xml
parsing file: ../doxygen-xml/xapian_8h.xml
parsing file: ../doxygen-xml/attributes_8h.xml
parsing file: ../doxygen-xml/cluster_8h.xml
parsing file: ../doxygen-xml/compactor_8h.xml
parsing file: ../doxygen-xml/constants_8h.xml
parsing file: ../doxygen-xml/constinfo_8h.xml
parsing file: ../doxygen-xml/database_8h.xml
parsing file: ../doxygen-xml/dbfactory_8h.xml
parsing file: ../doxygen-xml/diversify_8h.xml
parsing file: ../doxygen-xml/document_8h.xml
parsing file: ../doxygen-xml/enquire_8h.xml
parsing file: ../doxygen-xml/eset_8h.xml
parsing file: ../doxygen-xml/expanddecider_8h.xml
parsing file: ../doxygen-xml/geospatial_8h.xml
parsing file: ../doxygen-xml/iterator_8h.xml
parsing file: ../doxygen-xml/keymaker_8h.xml
parsing file: ../doxygen-xml/matchdecider_8h.xml
parsing file: ../doxygen-xml/matchspy_8h.xml
parsing file: ../doxygen-xml/mset_8h.xml
parsing file: ../doxygen-xml/positioniterator_8h.xml
parsing file: ../doxygen-xml/postingiterator_8h.xml
parsing file: ../doxygen-xml/postingsource_8h.xml
parsing file: ../doxygen-xml/query_8h.xml
parsing file: ../doxygen-xml/queryparser_8h.xml
parsing file: ../doxygen-xml/registry_8h.xml
parsing file: ../doxygen-xml/rset_8h.xml
parsing file: ../doxygen-xml/stem_8h.xml
parsing file: ../doxygen-xml/termgenerator_8h.xml
parsing file: ../doxygen-xml/termiterator_8h.xml
parsing file: ../doxygen-xml/types_8h.xml
parsing file: ../doxygen-xml/unicode_8h.xml
parsing file: ../doxygen-xml/valueiterator_8h.xml
parsing file: ../doxygen-xml/valuesetmatchdecider_8h.xml
parsing file: ../doxygen-xml/weight_8h.xml
parsing file: ../doxygen-xml/dir_3c504f51550cb9fcc49223adf2dc9606.xml
parsing file: ../doxygen-xml/dir_f563c3c8c706a178a41c222d59605302.xml
stamp='xapian_wrap.stamp' /usr/bin/perl '/home/tejasvi/xapian/xapian-bindings'/swig-depcomp /home/tejasvi/xapian/build/swig/preinst-swig -Werror -I. -I'/home/tejasvi/xapian/xapian-bindings/python' -I/home/tejasvi/xapian/build/xapian-core/include -I/home/tejasvi/xapian/xapian-core/include -DSWIG_PYTHON_LEGACY_BOOL -c++ \
-python -threads -shadow -O \
-o xapian_wrap.cc '/home/tejasvi/xapian/xapian-bindings/python/'python.i
/usr/bin/perl -i /home/tejasvi/xapian/xapian-bindings/python/fixup-swig-py2-wrapper xapian.py
make all-am
make[1]: Entering directory '/home/tejasvi/xapian/build/xapian-bindings/python'
depbase=`echo xapian_wrap.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I/home/tejasvi/xapian/xapian-bindings/python -I.. -I/usr/include/python2.7 -fno-strict-aliasing -Wall -Wno-unused -Wno-uninitialized -fvisibility=hidden -I/home/tejasvi/xapian/build/xapian-core/include -I/home/tejasvi/xapian/xapian-core/include -g -O2 -MT xapian_wrap.lo -MD -MP -MF $depbase.Tpo -c -o xapian_wrap.lo xapian_wrap.cc &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile: g++ -DHAVE_CONFIG_H -I. -I/home/tejasvi/xapian/xapian-bindings/python -I.. -I/usr/include/python2.7 -fno-strict-aliasing -Wall -Wno-unused -Wno-uninitialized -fvisibility=hidden -I/home/tejasvi/xapian/build/xapian-core/include -I/home/tejasvi/xapian/xapian-core/include -g -O2 -MT xapian_wrap.lo -MD -MP -MF .deps/xapian_wrap.Tpo -c xapian_wrap.cc -fPIC -DPIC -o .libs/xapian_wrap.o
/bin/bash ../libtool --tag=CXX --mode=link g++ -fno-strict-aliasing -Wall -Wno-unused -Wno-uninitialized -fvisibility=hidden -I/home/tejasvi/xapian/build/xapian-core/include -I/home/tejasvi/xapian/xapian-core/include -g -O2 -avoid-version -module -shrext "" -o _xapian.la -rpath /xapian xapian_wrap.lo /home/tejasvi/xapian/build/xapian-core/libxapian-1.5.la -lstdc++
libtool: link: g++ -fPIC -DPIC -shared -nostdlib /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/crti.o /usr/lib/gcc/x86_64-linux-gnu/8/crtbeginS.o .libs/xapian_wrap.o -Wl,-rpath -Wl,/home/tejasvi/xapian/build/xapian-core/.libs /home/tejasvi/xapian/build/xapian-core/.libs/libxapian-1.5.so -lrt -lz -luuid -L/usr/lib/gcc/x86_64-linux-gnu/8 -L/usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu -L/usr/lib/gcc/x86_64-linux-gnu/8/../../../../lib -L/lib/x86_64-linux-gnu -L/lib/../lib -L/usr/lib/x86_64-linux-gnu -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/8/../../.. -lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-linux-gnu/8/crtendS.o /usr/lib/gcc/x86_64-linux-gnu/8/../../../x86_64-linux-gnu/crtn.o -g -O2 -Wl,-soname -Wl,_xapian -o .libs/_xapian
libtool: link: ( cd ".libs" && rm -f "_xapian.la" && ln -s "../_xapian.la" "_xapian.la" )
/bin/mkdir -p xapian
cp `test -f xapian.py || echo '/home/tejasvi/xapian/xapian-bindings/python/'`xapian.py xapian/__init__.py
/bin/mkdir -p xapian
/bin/bash ../libtool --config > libtoolconfig.tmp
. ./libtoolconfig.tmp; cp $objdir/_xapian xapian
rm -f libtoolconfig.tmp
/usr/bin/python2 -c 'import os;os.chdir("xapian");import _xapian'
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named _xapian
make[1]: *** [Makefile:1291: xapian/__init__.pyc] Error 1
make[1]: Leaving directory '/home/tejasvi/xapian/build/xapian-bindings/python'
make: *** [Makefile:681: all] Error 2
`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment