labstreaminglayer / pylsl

Python bindings (pylsl) for liblsl
MIT License
136 stars 57 forks source link

LSL binary library file was not found on raspberry pi #68

Closed Boris870315 closed 1 year ago

Boris870315 commented 1 year ago

This is the original issue. LSL binary library file was not found. Please make sure that the binary file can be found in the package lib folder (/home/boris/.local/lib/python3.9/site-packages/pylsl/lib) or the system search path.

standalone_compilation_linux.sh is not working on my pi. thus, i use pip install pylsl. $ mv $SITE_PACKAGES/pylsl/lib $SITE_PACKAGES/pylsl/liblsl.so $ mkdir $SITE_PACKAGES/pylsl/lib $ mv $SITE_PACKAGES/pylsl/liblsl.so $SITE_PACKAGES/pylsl/lib I also tried this three comments on my pi, but also not working.

cboulay commented 1 year ago

standalone_compilation_linux.sh is not working on my pi

Let's fix this. What kind of Raspberry Pi? What OS?

$ mv $SITE_PACKAGES/pylsl/lib $SITE_PACKAGES/pylsl/liblsl.so
$ mkdir $SITE_PACKAGES/pylsl/lib
$ mv $SITE_PACKAGES/pylsl/liblsl.so $SITE_PACKAGES/pylsl/lib

I have no idea what that's doing. It doesn't look right to me. Let's focus on enabling you to build liblsl.so on your pi.

Boris870315 commented 1 year ago

my raspberry pi system is Raspberry os (64bit) and the version is Raspberry Pi 4.

cboulay commented 1 year ago

I have a 4B and I'm using Raspberry Pi OS 64-bit as well and I'm able to build. Can you please provide the error log from a failed attempt to build?

Boris870315 commented 1 year ago

https://drive.google.com/file/d/1dIiRcyaoLjfC6xQq1Qblz_eudV2W6dd_/view?usp=sharing Is this what you want?

cboulay commented 1 year ago

No. Please paste the output of gcc --version. Also please paste the output of bash -e standalone_compilation_linux.sh

Boris870315 commented 1 year ago

boris@raspberrypi:~ $ gcc --version gcc (Debian 10.2.1-6) 10.2.1 20210110 Copyright (C) 2020 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

boris@raspberrypi:~ $ bash -e standalone_compilation_linux.sh bash: standalone_compilation_linux.sh: No such file or directory

cboulay commented 1 year ago
git clone https://github.com/sccn/liblsl.git
cd liblsl
bash -e standalone_compilation_linux.sh
Boris870315 commented 1 year ago

still not working, jupyter is showing the same issue. The gcc version output is gcc (Debian 10.2.1-6) 10.2.1 20210110, and bash: standalone_compilation_linux.sh: No such file or directory.

cboulay commented 1 year ago

Forget the bash -e part. If you cd into the liblsl directory that you just cloned, and then run ./standalone_compilation_linux.sh, what happens?

None of the Python / Jupyter errors matter. All that matters right now is running that script.

Boris870315 commented 1 year ago

it show like this

cboulay commented 1 year ago

That's great, it worked! Copy the generated liblsl.so into $SITE_PACKAGES/pylsl/lib

Boris870315 commented 1 year ago

thanks, it works now