Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #15332

Re: Recommended way of installing system-wide python application and libraries

From Scott Talbert <swt@techie.net>
Newsgroups linux.debian.maint.python
Subject Re: Recommended way of installing system-wide python application and libraries
Date 2023-12-08 01:30 +0100
Message-ID <HIwUG-c3pc-3@gated-at.bofh.it> (permalink)
References <HHAH0-bmY5-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On Tue, 5 Dec 2023, Ivan Perez wrote:

> Hi everyone!
> 
> I'm currently trying to bring a tool we have at NASA Ames up to speed:
> https://github.com/NASA-SW-VnV/ikos
> 
> IKOS is a static analyzer for C. I'm really hoping that IKOS can be included
> in Debian in the near future.
> 
> IKOS is implemented as a  C++ library, and a number of python
> tools/wrappers. The tools call mains in modules defined in a python library
> `ikos`.
> 
> As of right now, our CMakeFiles attempt to install everything (by default)
> under /opt/ikos/.
> 
> I'm having lots of issues getting the python portions installed system-wide.
> I initially upgraded distutils to setuptools, but a recent update is now
> asking that I use a venv. More details and a link to a dockerfile can be
> found here: https://github.com/NASA-SW-VnV/ikos/discussions/241.
> 
> While I can hack a solution that "works" (either by making a venv under the
> target dir or by means of break-system-packages), I'd prefer to use
> recommended practices, and also conform to the way that things are done in
> Debian/Ubuntu.
> 
> What would be the recommended way of installing IKOS system-wide in Debian?

Hello again Ivan (different neighborhood :)),

The "modern" way of building Python libraries/applications seems to be to 
use a pyproject.toml.  The pyproject.toml specifies a backend build system 
that knows how to build the library/application and produce a wheel.

As far as how to do this within an existing cmake project, unfortunately, 
there doesn't seem to be a clear/easy way.  The only cmake example I can 
think off of the top of my head is cvc5.  It still uses setup.py though, 
so not a great future-looking example (and I had to patch it to build the 
Python bindings in Debian): 
https://github.com/cvc5/cvc5/blob/main/src/api/python/CMakeLists.txt

If you're open to other options for building python libraries, meson might 
be something to look into.  I haven't used it extensively, though.  It 
does seem to have better support for building Python though.

Regards,
Scott

Back to linux.debian.maint.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Recommended way of installing system-wide python application and libraries Ivan Perez <ivanperezdominguez@gmail.com> - 2023-12-05 11:20 +0100
  Re: Recommended way of installing system-wide python application and  libraries Andrey Rakhmatullin <wrar@wrar.name> - 2023-12-05 11:30 +0100
  Re: Recommended way of installing system-wide python application  and libraries c.buhtz@posteo.jp - 2023-12-05 13:30 +0100
    Re: Recommended way of installing system-wide python application and  libraries Salvo Tomaselli <tiposchi@tiscali.it> - 2023-12-05 17:50 +0100
  Re: Recommended way of installing system-wide python application  and libraries Scott Talbert <swt@techie.net> - 2023-12-08 01:30 +0100
    Re: Recommended way of installing system-wide python application and libraries Ivan Perez <ivanperezdominguez@gmail.com> - 2023-12-18 00:30 +0100

csiph-web