-
-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Linux: Support platforms #1
Comments
I've tried to build it on Arch Linux but without success so far. Log attched The link to build instructions does not work, btw. |
Just tried manual build steps on Ubuntu server Linux, got the following result: Click to expand
|
I am building now on Ubuntu Server with the script shown here Support for Ubuntu wheels are in the works. |
under debian 10 I have to add
I am not worried about the segfault as this is "normal" on blender exit on my system (regardless of linux distro/version) otherwise the importing bpy will fail with
hope this helps, even as a work around, with making the script compatible with more systems and an automated installation. |
@Kuro-Maii Do you know a good way to detect linux distributions? What does distro.linux_distribution(full_distribution_name=False) report for you? (Note, requires installing python distro module) |
Is the CMake option `-DWITH_PYTHON' necessary? |
I am also failing with this error. All other steps look really great and thanks by the way. How did you end up resolving these ld.gold errors? @TylerGubala |
@zehao-sean-huang you should check out this Blender dev talk post that's related but essentially the ld.gold linker errors went completely away by performing install_deps.sh If you are using my script in the wiki exactly, especially on Ubuntu 18.4 LTS then you should try building both master and the 2.80 branches. I can check when I get home but 2.80 was the latest that would build on my system when I last tried. |
@zehao-sean-huang the ld.gold errors usually result from cloning from SVN in my experience. The updated setup.py script should avoid errors with this. Wheels for Linux will come out once pypi updates the file size limit for |
Building on Debian should be better for you now @Kuro-Maii ; if you get around to it try building from the repo with the prerequisites installed. |
Sorry for the very late reply, I was severely distracted with a few other projects...
Python 3.7.3 (default, Dec 20 2019, 18:57:59)
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import distro
>>> distro.linux_distribution(full_distribution_name=False)
('debian', '10', 'buster')
>>> I am reading thru the other comments and going to test the the rest. |
I tried to run the command
Click to expand full log
|
installing with the script found here I am coming to the same conclusion as my earlier comment from december |
I just found an interesting error after running the script again for as the test then fails with
doing a find reuslts in the following:
this was not a problem before master was used as the branch to compile |
Hi @Kuro-Maii , I apologize for the confusion, but I believe that this is not necessarily an issue with the I think that if you
You will be able to build using the build script again. What I believe happened was that you built from the build script, and the Then, if you built from After you built the first time with the build bash script it created the files and folders; I think that is what is preventing you from building a second time. I have gotten similar errors when trying to build twice in a row from the bash script so I would suggest you perform the following step:
|
Hi, I am tempting an install on Ubuntu. Sorry if the question seems silly but why Edit: also Edit 2: to get up to date cmake on Ubuntu:
Edit 3: what is the state of the limit issue? pypi/support#362 Edit 4: I haven't managed to build at this point, having a message:
(but also maybe errors higher up? it's not clear what is failing) |
My apologies but
The parameter that should be used is For example:
The upload limit issue is resolved; I have the wheels built and placed on pypi for Windows and MacOS. I can't do the same for linux as it's not as completely straightforward due to limitations on how you can upload Until then, I have a place on my Google Drive containing some So as far as installation from pypi... Not until I figure out what
I can see in the log something of interest:
Which would imply that you are using an outdated version of
When installing from |
Sadly I have the right version of Cmake (3.17). However I installed it through snap, as it's a bit difficult to get a version to cmake upper to 3.10 on Ubuntu, which may explain the issue. I had similar troubles with Chromium installed as snap unable to find Thanks a lot for the wheels on Google Driver in the meantime, you are awesome! I'll try to spend some time on the Docker thing, though on my side it's been a very long time since I tried to build smth myself from sources... |
I have the same error At the line Here are my specs :
Edit: I got the same result under ubuntu 16.04. |
Are you able to do
sudo apt install libjemalloc-dev
And see if that resolves it?
…On Tue, Jun 30, 2020, 10:17 AM Apollinaire Lecocq ***@***.***> wrote:
I have the same error
ImportError: libjemalloc.so.1: cannot open shared object file: No such
file or directory
At the line import bpy. I installed bpy via the wheel provided in your
Gdrive : bpy-2.82-cp37-cp37m-linux_x86_64.whl and then ran bpy_post_install.
Here are my specs :
$ python --version
Python 3.7.8
>>> distro.linux_distribution()
('Ubuntu', '20.04', 'focal')
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFLEYRZM6YHGHX2CFW4V2RLRZHXW3ANCNFSM4E5OMKZA>
.
|
Same error after installing lijemalloc-dev. |
That is very bizarre. I will have to look into it over the weekend and get
back to you, maybe that is coming from `install_deps.sh` or something and I
have it and don't get the error because I have already run that...? I'm not
sure.
…On Wed, Jul 1, 2020, 5:32 AM Apollinaire Lecocq ***@***.***> wrote:
Same error after installing lijemalloc-dev.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFLEYR7E7JOWB6CI2KE7UJDRZL7DHANCNFSM4E5OMKZA>
.
|
Hi, progressing a bit! So, it seems that the "libjemalloc.so.1" thing is only solvable using Ubuntu 18.04 as the base image. Other distros (debian etc.), or later versions (eg 19) won't have "libjemalloc1" package and will fail.
Now I have this error:
But at least no jemalloc stuff. Edit: solved after installing Second edit: "libosdgpu3.4.0", "libosdcpu3.4.0", "libosd-dev" seems to exist on Ubuntu 20, not 18... so I don't get why it works on my machine in the first place (Ubuntu 18, I do have those libosdGPU.so.3.4.0 on my machine), and I still can't run in a Docker. Edit 2: we can install Edit 3: gave up at Edit again: it seems that I need to run Blender's "install_deps.sh", even with the wheel, because there is a ton of shared libraries to have installed in the first place. The wheel simply allows me to skip the build (or at least that's what I understand) |
Some devs are working on Docker images:
|
CI / Docker is in development on the |
@TylerGubala Hopeful I am! By development you mean you run the image or you are creating it? Btw I've managed to have an image that does build. It weights no less than 9.1 gb (!), takes 2 hours to build, buuuut... it goes as far as installing deps.
Mostly taken from https://github.com/egidijus/blender-compile (you need to follow the doc to have the correct folder structure), just fixed a dep and the cmake install. It lacks some reproducbility as it clones the latest blender. Cmake build is extremely slow, being able to use a snap or prebuilt version would allow to gain a few dozen minutes. Working commit of Blender is "2de5de57c58521862e0fecc95fc474ea347b7468" |
What's it matter? Maybe you can answer that question for yourself based on what I am doing:
That is a major pain point with this whole process, yeah.
If you have any recommendations feel free to submit a PR; any gains or speedups to be had with this process would be tremendous. |
Honestly I do not think that I will be able to create a |
Do you think it would be doable to have at least a slightly better support of other major linux distros? Debian likes, latest Ubuntu, Fedora etc.? Can we help by running some specific code on our machines? |
I'm pretty sure that's the exact problem that will be solved by the I just pushed up a commit to add the Dockerfile that I am currently working on, the one in the I think that if you can get Blender building following the manual instructions then those instructions can be automated. That is essentially the process I have followed to get to this point.
Have you tried asking for help on Blender's Dev Talk Forum? If you have issues building Blender itself if you post the issue you are having and the operating system you are on there you should find some good help. |
Thanks for sharing the Dockerfile, that's a great basis. Maybe it could be reused on specific systems by changing the "FROM" to another distro (+ tweaking the syntax a bit). Yeah I've tried the Dev Talk Forum, on post related to Docker, but everybody is acting like Blender build perfectly all the time on their machine. But Blender build is really hard to reproduce depending on certain machine, or within a Dockerfile, a lot of underlying dependencies seems to miss in the list they publish on Blender documentation. Every Dockerfiles I've found are not reproducible, outdated or never actually worked in the first place. |
Note that there are much more recent manylinux specifications than |
@jamadden it has gotten a lot better after attempting to use the @eric-burel I know that it can be a bit painful to go into the Blender Dev Talk forum but by BF's own admission it is the best resource for getting advice on building Blender in any environment. Also some progress has been made in the Docker department, I have made some VS Code tasks to automate the build of those environments as well. If you have insight into Docker (I am still very much a noobie at it) could you clone my repo, download VS Code and go:
And let me know what you think? PRs also welcomed and appreciated; this is a lot to track down admittedly, especially for multi platform. |
The VS code tasks are a nice addition, thank you. Click to expand
[here I got multiple times the same error message]
|
When compiling the Python module, they don't link correctly to OpenMP I
think.
That could be solved by patching CMakeLists.txt as suggested below and
following up to make sure the build still works.
https://devtalk.blender.org/t/centos-7-manylinux-build-difficulties/15007/6
…On Wed, Aug 26, 2020, 3:29 AM Eric Burel ***@***.***> wrote:
The VS code tasks are a nice addition, thank you.
Here is what I get for "Build Ubuntu Manual":
Scanning dependencies of target cycles_bvh
[100%] Building CXX object intern/cycles/bvh/CMakeFiles/cycles_bvh.dir/bvh.cpp.o
...
[100%] Linking CXX static library ../../../lib/libcycles_bvh.a
[100%] Built target cycles_bvh
Scanning dependencies of target blender
[100%] Building C object source/creator/CMakeFiles/blender.dir/creator.c.o
[100%] Building C object source/creator/CMakeFiles/blender.dir/creator_signals.c.o
[100%] Building C object source/creator/CMakeFiles/blender.dir/creator_args.c.o
[100%] Building C object source/creator/CMakeFiles/blender.dir/buildinfo.c.o
[100%] Linking CXX shared module ../../bin/bpy.so
[100%] Linking CXX shared module ../../bin/bpy.so
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(team.o): unsupported reloc 23 against global symbol gomp_tls_data
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(team.o): unsupported reloc 23 against global symbol gomp_tls_data
[here I got multiple times the same error message]
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(affinity.o): requires dynamic R_X86_64_PC32 reloc against 'stderr' which may overflow at runtime; recompile with -fPIC
[here I got multiple times the same error message]
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(oacc-init.o): unsupported reloc 23 against global symbol goacc_tls_data
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(affinity-fmt.o): requires dynamic R_X86_64_PC32 reloc against 'stderr' which may overflow at runtime; recompile with -fPIC
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(oacc-profiling.o): requires dynamic R_X86_64_PC32 reloc against 'acc_prof_lookup' which may overflow at runtime; recompile with -fPIC
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(env.o): requires dynamic R_X86_64_PC32 reloc against 'stderr' which may overflow at runtime; recompile with -fPIC
/usr/bin/ld.gold: error: /usr/lib/gcc/x86_64-linux-gnu/10/libgomp.a(error.o): requires dynamic R_X86_64_PC32 reloc against 'stderr' which may overflow at runtime; recompile with -fPIC
collect2: error: ld returned 1 exit status
make[3]: *** [source/creator/CMakeFiles/blender.dir/build.make:414: bin/bpy.so] Error 1
make[2]: *** [CMakeFiles/Makefile2:6419: source/creator/CMakeFiles/blender.dir/all] Error 2
make[1]: *** [Makefile:163: all] Error 2
make: *** [GNUmakefile:313: all] Error 2
The command '/bin/sh -c cd blender && make bpy' returned a non-zero code: 2
The terminal process "/bin/bash '-c', 'docker build -t blenderpy/ubuntu-manual -f .docker/ubuntu-manual/Dockerfile .'" terminated with exit code: 2.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFLEYR6HWWYXOLDPELQK5VLSCS2U5ANCNFSM4E5OMKZA>
.
|
@eric-burel It should be working now. |
I agree it worked on Ubuntu 20.04 on the HEAD of master, I had to specify cmake option |
I finally have Hopefully I will be able to add these to PYPI soon, the built files are quite large (184Mb) See also (I got issue number 666 just in time for halloween) |
For linux installs please use the If you continue to have issues post the error in a new issue. Thanks. |
My project using Blenderpy is sadly not active anymore, but thanks a lot for all your work, I am looking forward for using it in the future! |
Currently the setup script has only been tested under Windows
The current build script may work for Ubuntu though, or may be close per this:
https://wiki.blender.org/wiki/Building_Blender/Linux/Ubuntu#Installing_CMake
More testing and more support is needed for Fedora, Gentoo, Arch, and OpenSUSE.
Build instructions can be found here:
https://wiki.blender.org/wiki/Building_Blender/Linux
To do:
The text was updated successfully, but these errors were encountered: