question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

There is an error when I try to install magenta but I have no idea how to solve this problem

See original GitHub issue

Hello I have a question.

When I try to install magenta pip install magenta-gpu

But I got error

Failed building wheel for python-rtmidi

and

Command “/home/jinsol/anaconda2/bin/python2.7 -u -c “import setuptools, tokenize;file=‘/tmp/pip-build-GPLeG_/python-rtmidi/setup.py’;f=getattr(tokenize, ‘open’, open)(file);code=f.read().replace(‘\r\n’, ‘\n’);f.close();exec(compile(code, file, ‘exec’))” install --record /tmp/pip-XEAotx-record/install-record.txt --single-version-externally-managed --compile” failed with error code 1 in /tmp/pip-build-GPLeG_/python-rtmidi/

And I also try to install development environment. python setup.py develop

But I got error again

src/RtMidi.cpp:1101:10: fatal error: alsa/asoundlib.h: No such file or directory #include <alsa/asoundlib.h> ^~~~~~~~~~~~~~~~~~ compilation terminated. error: Setup script exited with error: command ‘/home/jinsol/anaconda2/bin/x86_64-conda_cos6-linux-gnu-cc’ failed with exit status 1


I installed python-rtmidi package and there is ‘alsa/asoundlib.h’ in /usr/include/ directory. I tried a lot of things but I have no idea how to solve this problem. Anybody help me?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
adarobcommented, Jan 7, 2019

Can you try running this command before installing:

sudo apt-get -y install build-essential libasound2-dev libjack-dev libav-tools

1reaction
KinWaiCheukcommented, Jan 19, 2019

I have also solved it. For my case, my gcc version was 4.3 which is too old for the python-rtmidi library. So I need to install gcc 6.3. After installing, you need to run the following line to check what is the name for the gcc that you install dpkg -l | grep gcc | awk '{print $2}' And it output the followings

gcc gcc-5 gcc-5-base:amd64 gcc-6 gcc-6-base:amd64 gcc-7-base:amd64 gcc-8-base:amd64 libcaca0:amd64 libgcc-5-dev:amd64 libgcc-6-dev:amd64 libgcc1:amd64

So, even I have installed gcc 6.3, the package name is actually gcc-6, then I run the following line to switch my default gcc to 6 (The last word in the following line is the version you want to change to).

ls -la /usr/bin/ | grep -oP "[\S]*(gcc|g\+\+)(-[a-z]+)*[\s]" | xargs bash -c 'for link in ${@:1}; do sudo ln -s -f "/usr/bin/${link}-${0}" "/usr/bin/${link}"; done' 6

I found most of my answer in this stack post https://askubuntu.com/questions/26498/how-to-choose-the-default-gcc-and-g-version

Read more comments on GitHub >

github_iconTop Results From Across the Web

There is an error when I try to install magenta but I have no ...
Hello I have a question. When I try to install magenta pip install magenta-gpu. But I got error. Failed building wheel for python-rtmidi....
Read more >
Magenta installation using "pip install magenta" having errors ...
If you have no GPU on your machine, ignore the error. If you do have one, install CUDA, which provides that missing library....
Read more >
magenta setting up problems - Google Groups
Recently I set up a platform of Magenta in tensorflow, but I had a problem ... not the problem of lacking something, but...
Read more >
Orbi Router Solid Magenta No Internet - Monia B
First, we need to know the meaning of the lights and then we discuss these errors and solve them with easy steps. Search:...
Read more >
Apple eSIM troubleshooting | T-Mobile Support
If you're not using your physical SIM card, remove it from the device. Choose your activation method and follow steps for any errors...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found