Skip to content
This repository has been archived by the owner on Jul 24, 2023. It is now read-only.

undefined reference #77

Open
wzhdigimax opened this issue Jan 11, 2019 · 4 comments
Open

undefined reference #77

wzhdigimax opened this issue Jan 11, 2019 · 4 comments

Comments

@wzhdigimax
Copy link

Hi,

When i tried make, i got many python errors. I confirmed the python is correctly installed....any idea on this? Thanks a lot!

gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=$WORK/b001=/tmp/go-build -gno-record-gcc-switches -o $WORK/b001/cgo.o $WORK/b001/_cgo_main.o $WORK/b001/_x001.o $WORK/b001/_x002.o $WORK/b001/_x003.o $WORK/b001/_x004.o $WORK/b001/_x005.o $WORK/b001/_x006.o $WORK/b001/_x007.o $WORK/b001/_x008.o $WORK/b001/_x009.o $WORK/b001/_x010.o $WORK/b001/_x011.o $WORK/b001/_x012.o $WORK/b001/_x013.o $WORK/b001/_x014.o $WORK/b001/_x015.o $WORK/b001/_x016.o $WORK/b001/_x017.o $WORK/b001/_x018.o $WORK/b001/_x019.o $WORK/b001/_x020.o $WORK/b001/_x021.o -g -O2 -L/usr/local/lib -lpython2.7

go-python-master

/usr/local/lib/libpython2.7.a(complexobject.o): In function _Py_c_abs': /usr/src/Python-2.7.15/Objects/complexobject.c:214: undefined reference to hypot'
/usr/local/lib/libpython2.7.a(complexobject.o): In function complex_remainder': /usr/src/Python-2.7.15/Objects/complexobject.c:616: undefined reference to floor'
/usr/local/lib/libpython2.7.a(complexobject.o): In function complex_divmod': /usr/src/Python-2.7.15/Objects/complexobject.c:642: undefined reference to floor'
/usr/local/lib/libpython2.7.a(complexobject.o): In function _Py_c_pow': /usr/src/Python-2.7.15/Objects/complexobject.c:143: undefined reference to hypot'
/usr/src/Python-2.7.15/Objects/complexobject.c:144: undefined reference to pow' /usr/src/Python-2.7.15/Objects/complexobject.c:145: undefined reference to atan2'
/usr/src/Python-2.7.15/Objects/complexobject.c:147: undefined reference to sincos' /usr/src/Python-2.7.15/Objects/complexobject.c:148: undefined reference to exp'
/usr/src/Python-2.7.15/Objects/complexobject.c:149: undefined reference to log' /usr/src/Python-2.7.15/Objects/complexobject.c:143: undefined reference to hypot'
/usr/src/Python-2.7.15/Objects/complexobject.c:144: undefined reference to pow' /usr/src/Python-2.7.15/Objects/complexobject.c:145: undefined reference to atan2'
/usr/src/Python-2.7.15/Objects/complexobject.c:146: undefined reference to sincos' /usr/local/lib/libpython2.7.a(complexobject.o): In function _Py_c_abs':
/usr/src/Python-2.7.15/Objects/complexobject.c:214: undefined reference to hypot' /usr/local/lib/libpython2.7.a(floatobject.o): In function float_is_integer':
/usr/src/Python-2.7.15/Objects/floatobject.c:995: undefined reference to `floor'

@wzhdigimax
Copy link
Author

BTW, i mean the make of go-python-master for installation

@sbinet
Copy link
Owner

sbinet commented Jan 31, 2019

it seems the compilation is missing a link to libm.
are you sure pkg-config knows about Python?

@xhaoxiong
Copy link

are you resolve it ?

@popeye8777
Copy link

Not sure I'm going to give a shot

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants