Hello, everyone...it seems that nobody can get this thing to compile, but I've been able to get farther than most I've heard of so far, so I'll try to explain how to get at least to where I am.
Please note I'm doing this on Linux (RedHat 8), but the steps should hopefully help on other OS's as well.
This first thing to do is to extract your blender-source-2.25b.tar.gz file to your home directory:
mv blender-source-2.25b.tar.gz ~
tar xvfz blender-source-2.25b.tar.gz
The next thing to do, as the makefiles default to looking in a ~/develop directory rather than ~/blender, rather than mess with the makefiles as I did, rename the extracted directory to develop:
mv ~/blender ~/develop
Now, if you go into ~/develop/source and type make, you get some errors about guessconfig being denied, so find it and give it executable permissions, and give the config file it writes to write permissions:
chmod +x guessconfig
chmod +w config.guess
Now this takes us a bit further, but we still get errors when we type make. It says that it cannot find 'nan_compile.mk', when it goes into the 'creator' directory. This is a problem with almost all the source dirs, but you already have a copy of these files with you, just not in the right places, so we're going to symlink them to all the other source dirs so they can be accessed (on other OS's, you should be able to just move them), note I'm using bash scripting to accomplish this:
for thesrcdir in `find -type d`; do
ln -sf $PWD/*.mk $thesrcdir/;
Now, some successful compiling can happen...but not a lot.
There is still much to be done, I'm afraid.
If you try to 'make' now, something compiles, but then you get some errors about not being able to find two includes, MEM_guardedalloc.h and render.h.
MEM_guardedalloc.h is being looked for in ~/develop/lib/guardedalloc/include, but it is actually in ~/develop/intern/guardedalloc...this is going to happen a lot to different libraries, so do the following (thanks for everyone for suggestions about the environment vars and libs):
export CFLAGS="-g -Wall -I/usr/include/python2.2 -I/usr/include/mozilla-1.0.1/nspr"
export LDFLAGS="-L/usr/lib/python2.2/config -ldl"
Note at this point I had to manually comment out some lines in the intern/Makefile to have it recognize only Linux...
Note that you may have to change where your OpenGL headers are found, as well as a few others; use your judgement...as you've probably figured out by now, this isn't for the faint of heart. These place the appropriate files in the ~/develop/lib directory, which is a GOOD THING: I'm rewriting pages and pages here, thanks to these tips.
Also, you should hopefully notice that I didn't cover all the intern directories, such as BSP,Decimation,Img, and Python...that's because I couldn't figure them out. If we're lucky, either
A) They'll turn out to be non-crucial (HAH), or
B) I'll come across a solution. Any help would be much appreciated.
Well, now that we have all the libs installed, why don't we give make a try in the source directory?
Could anyone give advice as to how to compile those libraries?
That's all that needs doing, and it should work.
Last edited by erydo on Wed Oct 16, 2002 8:00 am; edited 2 times in total
Thanks for the info. I just installed RedHad 8.0 (first linux ever) and were thinking about compiling Blender. I'll follow this thread and hope someone gives a good walkthrough.
/Darwin, back to blender..
That's about how far I got... well almost... Not a bad job considering that I haven't ever successfully compiled a program from source...
I'm using Mac OS X to use blender, but I don't have the delevopers tools, so I've been using yellow dog linux to try and compile it... But I gave up...
But when someone creates some binaries... then can they send them to me??
Well, I've actually gotten quite a bit further since this post, but I just got a tip that makes most of what I've written since irrelevent (not all, though)...I'll finish it up and then post it for you all
Got the next step, though in an incredibly hacky way.
The problem, at least on my machine, seems to be rooted in the fact that guessconfig isn't working correctly. As in, it's not returning anything. Because of this, CC and CCC aren't getting set. The first symptom is when you're looking at the compile lines (as they flash past), and you see that every one of them is
cc -c -DNDEBUG ...
when it looks from the makefiles like it should be gcc -c -DNDEBUG ...
So, I fixed it by adding these two lines into nan_compile.mk:
Note that I added these *outside* of any if blocks.
After adding this, compile goes on until the software starts complaining about BKE_global.h and BKE_main.h, like this:
raddisplay.c:55: BKE_global.h: No such file or directory
raddisplay.c:56: BKE_main.h: No such file or directory
So, anyway, this gets it a bit farther. Could someone please post a better fix for this one, though?
Ack... and now I check the preview and discover that my post is already obsolete. Oh well. Here it is, just in case.
Well. Using the info from
and some patience I was able to build a non-functional binaries of all importand packages (creator/publisher/player/plugin). All just bus-error/core-dump on startup trying to open initial window. But they go some way along to do it
The actual function is drawobject deep inside of the main initialization block.
I've had to change some minor things and install some additional libraries:
SDL, smpeg, vorbis, vorbisfile, openAL, openSSL, mesa
You have to go to the intern sub-directories and run make install there
to install some libraries in the ~/obj/ tree.
Remember that this is supposed to be run (probably) in the dedicated
account with source tree in ~/develop and target tree in ~/obj . Also all your make commands should include -I~/develop/source/ parameter
to include external *.mk files.
I've also tried to build debugging binary AND IT WORKS !!!!!
I was able to run it and render some image!
I do not think that the binary is of any use for anybody but I'll post it
anyway. I'll also try to post my
tree there but not today. First I've to make a build script for it.
All was done under debian linux sid (devel distribution)
Have fun !
So, do the instructions in the original email still apply, or do these new instructions completely supercede them?
It sounds like you'r well on the way.
When you get it so that it compiles properly, you should post the fixed source so that others can compile it for there OS
As msph pointed out, most problems come from the fact that guessconfig returns nothing (at least for me under linux).`
This is why the variable OS, CC, OPENGL_HEADERS, etc are not defined.
The first priority should be to make guess.config executable and fix guessconfig.
How the heck did NaN compile this??[/list]
I'm working on build script right now. I'll post it as soon as I finish.
I can't wait!!
There shouldn't be any reasons why blender won't compile (with this script) on a ppc version of linux as opposed to x86?
I think that it should be _DOABLE_, but not very easy. There are some
architectural differences, as far as I can tell. But anyway it would be
good starting point.
The build fails here on intern/decimation/intern/LOD_QSDecimator.cpp
LOD_QSDecimator.cpp: In member function `bool LOD_QSDecimator::CollapseEdge()':
LOD_QSDecimator.cpp:186: no matching function for call to `CTR_UHeap<LOD_Edge>::Remove(__gnu_cxx::__normal_iterator<LOD_Edge*, std::vector<LOD_Edge, std::allocator<LOD_Edge> > >, int)'
$HOME/develop/lib/linux-glibc2.2.5-i386/container/include/CTR_UHeap.h:149: candidates are: void CTR_UHeap<HeapType>::Remove(HeapType*, int) [with HeapType = LOD_Edge]
Five errors of the same style.
gcc-3.2 (GCC) 3.2 (Mandrake Linux 9.0 3.2-2mdk)
I was following the howto, but mine fails here... before I even get to the guardedalloc problem.
|****> Make all by @localhost at 21:39:06 15-Oct-2002 on
====> make all in source/creator
make: *** No rule to make target `all'. Stop.
make: *** [all] Error 1
Bah. Iím using Mac OS X 10.1.5, GCC 2.95.2, April 2002 Developer Tools beta