Skip to content

Build shared version of igraph library #1151

Merged
merged 2 commits into from
Jun 28, 2019

Conversation

pmenzel
Copy link
Collaborator

@pmenzel pmenzel commented Jun 28, 2019

Tested on godsavethequeen with pip install --user python-igraph (0.7.1.0) and import igraph in Python.

This reverts commit 4b1d6dd.

Installing the Python package [python-igraph][1] importing it fails
with the error below.

    $ pip install --user leidenalg
    DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
    Collecting leidenalg
      Downloading https://files.pythonhosted.org/packages/b6/cc/d76baf78a3924ba6093a3ce8d14e2289f1d718bd3bcbb8252bb131d12daa/leidenalg-0.7.0.tar.gz (92kB)
         |████████████████████████████████| 102kB 3.3MB/s
    Collecting python-igraph>=0.7.1.0 (from leidenalg)
      Downloading https://files.pythonhosted.org/packages/0f/a0/4e7134f803737aa6eebb4e5250565ace0e2599659e22be7f7eba520ff017/python-igraph-0.7.1.post6.tar.gz (377kB)
         |████████████████████████████████| 378kB 7.5MB/s
    Building wheels for collected packages: leidenalg, python-igraph
      Building wheel for leidenalg (setup.py) ... done
      Stored in directory: /scratch/local/pmenzel/.cache/pip/wheels/29/55/48/5a04693a10f50297bcda23819ca23ab3470a61dd911851c8bd
      Building wheel for python-igraph (setup.py) ... done
      Stored in directory: /scratch/local/pmenzel/.cache/pip/wheels/41/d6/02/34eebae97e25f5b87d60f4c0687e00523e3f244fa41bc3f4a7
    Successfully built leidenalg python-igraph
    Installing collected packages: python-igraph, leidenalg
    Successfully installed leidenalg-0.7.0 python-igraph-0.7.1.post6
    pmenzel@godsavethequeen:~> python
    Python 2.7.16 (default, May 15 2019, 14:45:23)
    [GCC 7.3.0] on linux2
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import igraph as ig
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/home/pmenzel/.local/lib/python2.7/site-packages/igraph/__init__.py", line 34, in <module>
        from igraph._igraph import *
    ImportError: /home/pmenzel/.local/lib/python2.7/site-packages/igraph/_igraph.so: undefined symbol: _ZTVN10__cxxabiv117__class_type_infoE

Somehow it’s not linked against stdc++ correctly? [Missing stdc++ in during
linking?*][2] might be a similar issue.

Anyway, having the shared library for igraph around, python-igraph builds fine
and can be imported too. So add it back again.

[1]: https://github.com/igraph/python-igraph/
[2]: https://github.com/sensational/sassphp/issues/4
@thomas
Copy link
Collaborator

thomas commented Jun 28, 2019

It makes no sense to have a so lying around that is used by a tobe build so (say py_igraph.so). If some upstream module can't link against a static library, then it's the error of the module and should be fixed accordingly.

@pmenzel
Copy link
Collaborator Author

pmenzel commented Jun 28, 2019 via email

@pmenzel pmenzel merged commit 93347bc into master Jun 28, 2019
@donald
Copy link
Collaborator

donald commented Jun 29, 2019

Whats is a "tobe" build?

@thomas
Copy link
Collaborator

thomas commented Jun 29, 2019

a tobe build -- a build that might happen in some unforseable future.

@thomas
Copy link
Collaborator

thomas commented Jun 29, 2019

Wow, just noted that my mobe can't edit github comments.
I liked to add a question about the optional usage of german language :)

Sign in to join this conversation on GitHub.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants