2

I'm trying to install ibm_db in my Ubuntu 14.04 (I did have that package before but I had to format my computer). When:

pip install ibm_db

I get this error looking at "tail -n100 /home/nfs/user/.pip/pip.log"

copying tests/test_220_PersistentConn.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_150_FetchAssocSelect_01.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_041_FetchTupleMany_01.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_060_Tables_01.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_120_FieldName.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_091_ConnmsgWrongUser.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_200_MultipleRsltsetsUniformColDefs.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_024_ForeignKeys.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_155_FetchAssocSelect_05.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_154_AllFetches.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_201_MultipleRsltsetsDiffColDefs.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_003_NumAffectedRows.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_createDropDB.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_045_FetchTupleBinaryData_01.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_260_FetchTupleMany_07.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_recreateDB.py -> build/lib.linux-x86_64-2.7/tests

copying tests/test_6561_InsertNULLValues.py -> build/lib.linux-x86_64-2.7/tests

running egg_info

creating ibm_db.egg-info

writing ibm_db.egg-info/PKG-INFO

writing top-level names to ibm_db.egg-info/top_level.txt

writing dependency_links to ibm_db.egg-info/dependency_links.txt

writing manifest file 'ibm_db.egg-info/SOURCES.txt'

warning: manifest_maker: standard file '-c' not found



reading manifest file 'ibm_db.egg-info/SOURCES.txt'

reading manifest template 'MANIFEST.in'

warning: no files found matching '*' under directory 'clidriver'

warning: no files found matching '*' under directory 'ibm_db_dlls'

writing manifest file 'ibm_db.egg-info/SOURCES.txt'

copying tests/pic1.jpg -> build/lib.linux-x86_64-2.7/tests

copying tests/spook.png -> build/lib.linux-x86_64-2.7/tests

running build_ext

building 'ibm_db' extension

creating build/temp.linux-x86_64-2.7

x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/home/nfs/ruben/Downloads/dsdriver/./include -I/usr/include/python2.7 -c ibm_db.c -o build/temp.linux-x86_64-2.7/ibm_db.o

ibm_db.c:26:20: fatal error: Python.h: No such file or directory

 #include <Python.h>

                    ^

compilation terminated.

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

----------------------------------------
Cleaning up...
  Removing temporary dir /tmp/pip_build_ruben...
Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_ruben/ibm-db/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-RuRqdo-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_ruben/ibm-db
Exception information:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 283, in run
    requirement_set.install(install_options, global_options, root=options.root_path)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1435, in install
    requirement.install(install_options, global_options, *args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 706, in install
    cwd=self.source_dir, filter_stdout=self._filter_install, show_stdout=False)
  File "/usr/lib/python2.7/dist-packages/pip/util.py", line 697, in call_subprocess
    % (command_desc, proc.returncode, cwd))
InstallationError: Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_ruben/ibm-db/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-RuRqdo-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_ruben/ibm-db

What's happening with the package. Is the source link broken?

Regards!

1 Answer 1

4

As far as I see python-dev package is missed on your machine. Try to install it and re-install ibm_db. To install python-dev use following command:

$ sudo apt-get install -y python-dev
Sign up to request clarification or add additional context in comments.

3 Comments

installing ibm_db in a virtualenvironment still shows the error message: UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 99: ordinal not in range(128)
when i do pip freeze, i get the ibm-db==2.0.5.1 inside the list, but still having problems installing it in a virtual env
Look like this issue is connected with locale settings on your machine. Try to set your locale explicitly, for example: export LC_ALL=C and try to re-install ibm_db.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.