Hi Team,
I am facing issue while building the nano blockchain.
Steps: What I did?
$sudo sh bootstrap_boost.sh`In file included from libs/python/src/list.cpp:5:
In file included from ./boost/python/list.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/long.cpp:5:
In file included from ./boost/python/long.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/dict.cpp:4:
In file included from ./boost/python/dict.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/tuple.cpp:5:
In file included from ./boost/python/tuple.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/str.cpp:4:
In file included from ./boost/python/str.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/slice.cpp:1:
In file included from ./boost/python/slice.hpp:9:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/converter/from_python.cpp:6:
In file included from ./boost/python/converter/from_python.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
1 error generated.
In file included from libs/python/src/converter/registry.cpp:5:
In file included from ./boost/python/converter/registry.hpp:7:
In file included from ./boost/python/type_id.hpp:8:
In file included from ./boost/python/detail/prefix.hpp:13:
./boost/python/detail/wrap_python.hpp:50:11: fatal error: 'pyconfig.h' file not found
include
^
`
I checked this command in my terminal to solve this issue as $export CPLUS_INCLUDE_PATH="$CPLUS_INCLUDE_PATH:/usr/include/python2.7/"
I also added the file path in my bash_profile
export CPLUS_INCLUDE_PATH="$CPLUS_INCLUDE_PATH:/usr/include/python2.7/
And python 2.7 lib path to check whether file 'pyconfig.h' is present and it is present.
/usr/include/python2.7
fileobject.h pycapsule.h unicodeobject.h
floatobject.h pyconfig.h warnings.h
frameobject.h pyctype.h
Current python version
$ python --version
Python 3.7.0
Please help me to solve this error thank you
Hi @zhyatt
Can you please help me to find out the solution of above Query
Hi @argakiig
I think you didn't answer that, dont make this in the loop. I check the issue there in #1519 which make me again redirect to #1505.
Please solve the issue atleast at one position
@prateektiwari7 There is an issue with your python setup preventing boost from identifying the correct location. I would double-check your path includes proper location (you indicate two different versions of python in your issue), source the file in your terminal and try again.
This looks related to boost python and/or your python environment. I did a search and other people have had this issue on other projects. One place is here. https://github.com/boostorg/python/issues/187
Hi @zhyatt
Yes. I also tried for 3.7 with reference as export CPLUS_INCLUDE_PATH="$CPLUS_INCLUDE_PATH:path to python 3.7"
same issue :)
Since this is a boost/python related issue you'll get better assistance with them since we've never run in to this problem internally.
Closing out as external issue with https://github.com/boostorg/boost/issues and python
Hi @zhyatt
I solved this issue by finding my pyconfig.h from the command
$python3.7-config --includes --libs
Than export the python lib in ~/.bashrc_profile
nano ~/.bashrc_profile
CPLUS_INCLUDE_PATH="$CPLUS_INCLUDE_PATH:/Users/yudiz/anaconda3/include/python3.7m"
After this source ~/.bashrc_profile
After this the Error solved :)
Most helpful comment
Hi @zhyatt
I solved this issue by finding my pyconfig.h from the command
$python3.7-config --includes --libsThan export the python lib in
~/.bashrc_profilenano ~/.bashrc_profileAfter this source ~/.bashrc_profile
After this the Error solved :)