ta-lib-python icon indicating copy to clipboard operation
ta-lib-python copied to clipboard

installation: "ta-lib/ta_defs.h: No such file or directory..."

Open SerzhYu opened this issue 13 years ago • 23 comments

I've installed lib from list: ta-lib-0.4.0-src.tar.gz, but I get na error as well like this: "...ta-lib/ta_defs.h: No such file or directory...":

root@serzh-desktop:/usr/local/include/ta-lib-master# python setup.py install

setup.py:49: UserWarning: Cannot find ta-lib library, installation may fail. warnings.warn('Cannot find ta-lib library, installation may fail.') running install running build running build_py running build_ext skipping 'talib/common.c' Cython extension (up-to-date) building 'talib.common' extension x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/lib/python2.7/dist-packages/numpy/core/include -I/usr/include -I/usr/local/include -I/opt/include -I/opt/local/include -I/usr/include/python2.7 -c talib/common.c -o build/temp.linux-x86_64-2.7/talib/common.o talib/common.c:314:28: фатальная ошибка: ta-lib/ta_defs.h: No such file or directory. компиляция прервана. error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

I have got OS Ubuntu 13.04 x64.

Thanks forward.

SerzhYu avatar Oct 22 '13 15:10 SerzhYu

This still fails in fresh install of Ubuntu 22.04, amazing python ecosystem, a more helpful error message is surely welcome. As this issue is # 1 on google, here's the solution: https://cloudstrata.io/install-ta-lib-on-ubuntu-server/

wget http://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz
tar -xzf ta-lib-0.4.0-src.tar.gz
cd ta-lib/
sudo ./configure
sudo make
sudo make install
pip install ta-lib

Thanks ,Bro, it works for me.

lenhill avatar Jan 28 '23 23:01 lenhill

Does nobody read READMEs anymore?

Sure, it might be nice to package the library, but it’s not like using a previously installed shared library is unusual.

I wouldn’t blame the python ecosystem.

On Sat, Jan 28, 2023 at 3:57 PM lenhill @.***> wrote:

This still fails in fresh install of Ubuntu 22.04, amazing python ecosystem, a more helpful error message is surely welcome. As this issue is

1 on google, here's the solution:

https://cloudstrata.io/install-ta-lib-on-ubuntu-server/

wget http://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz tar -xzf ta-lib-0.4.0-src.tar.gz cd ta-lib/ sudo ./configure sudo make sudo make install pip install ta-lib

Thanks ,Bro, it works for me.

— Reply to this email directly, view it on GitHub https://github.com/TA-Lib/ta-lib-python/issues/46#issuecomment-1407514956, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAF5A27J65JKFVF4IQ3RADWUWW7TANCNFSM4AI7PGQA . You are receiving this because you modified the open/close state.Message ID: @.***>

mrjbq7 avatar Jan 28 '23 23:01 mrjbq7

For those who use conda and python >=3.11, this worked for me:

conda install -c conda-forge libta-lib
pip install git+https://github.com/TA-Lib/ta-lib-python   

If you use python 3.10, then this could suffice I guess: conda install -c conda-forge ta-lib however, it doesn't work with python 3.11

pseudomo avatar Mar 16 '24 15:03 pseudomo