unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Ben Sturmfels via Guix-patches via <guix-patches@gnu.org>
To: "Nicolò Balzarotti" <anothersms@gmail.com>
Cc: 47181@debbugs.gnu.org
Subject: [bug#47181] Packaging python-soundfile for use in MediaGoblin
Date: Tue, 16 Mar 2021 22:47:42 +1100	[thread overview]
Message-ID: <87ft0v1fs1.fsf@sturm.com.au> (raw)
In-Reply-To: <87eegfiljl.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me>

Thanks Nicolò,

On Tue, 16 Mar 2021, Nicolò Balzarotti wrote:

>>   OSError: cannot load library 'libsndfile.so.1': libsndfile.so.1:
>>   cannot open shared object file: No such file or directory
>>
> You can patch the sounfile.py file, setting the correct library path.
>
> Many other python packages do this, like python-file, python-libarchive-c, python-pyzbar
>
> It should look something like (untested):
>
> #+begin_src scheme
> (arguments
>      `(#:phases
>        (modify-phases %standard-phases
>          (add-before 'build 'set-library-file-name
>            (lambda* (#:key inputs #:allow-other-keys)
>              (let ((libsndfile (assoc-ref inputs "libsndfile")))
>                (substitute* "soundfile.py"
>                  (("find_library\\('sndfile'\\)")
>                   (string-append "'" libsndfile "/lib/libsndfile.so.0'")))
>                #t))))))
> #+end_src

Thanks, that solves my problem. One follow-up question - is it better to
use the ".so" link or the specific "so.0"?

I've now discovered a subsequent issue with libsndfile that I'll need to
put a patch in for first though. Progress!

Regards,
Ben




  reply	other threads:[~2021-03-16 11:48 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-16  3:50 [bug#47181] Packaging python-soundfile for use in MediaGoblin Ben Sturmfels via Guix-patches via
2021-03-16  7:51 ` Nicolò Balzarotti
2021-03-16 11:47   ` Ben Sturmfels via Guix-patches via [this message]
2021-03-16 12:44     ` Nicolò Balzarotti
2021-03-16 12:49     ` Léo Le Bouter via Guix-patches via
2021-03-16 13:09       ` Efraim Flashner
2021-03-30  6:20         ` Ben Sturmfels via Guix-patches via
2021-09-12  2:14           ` bug#47181: " Ben Sturmfels via Guix-patches via

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ft0v1fs1.fsf@sturm.com.au \
    --to=guix-patches@gnu.org \
    --cc=47181@debbugs.gnu.org \
    --cc=anothersms@gmail.com \
    --cc=ben@sturm.com.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).