Previous Thread  Next Thread

chat icon Guides for compiling Blender

matt_e

Posted: Thu Mar 20, 2003 3:21 pm
Joined: 14 Oct 2002
Posts: 897
Let's try and consolidate this knowledge somewhat. If you know of any guides that people have written up, please post links to them here! Also, feel free to write up your own guides for various platforms.

Windows

Building Blender on Windows with MSVC (2003/10/11)
http://home.pacbell.net/c_keith/projects/blender/bootstrap.html

Compiling Blender 2.26 on Windows XP with MSVC 6 and Python 2.22
http://www.cise.ufl.edu/~fishwick/blender/make.txt

Help compiling under Windows using Cygwin
http://www.blender.org/modules.php?op=modload&name=phpBB2&file=viewtopic&t=692

Compiling in Windows using free tools (mingw-gcc)
http://projects.blender.org/viewcvs/viewcvs.cgi/blender/doc/README.windows-gcc?cvsroot=bf-blender
(click 'view')


Mac OS X

Compiling using the command line
Download the necessary support packages as outlined in the README file included with the CVS sources. Then follow the instructions in the following link:
http://www.blender.org/modules.php?op=modload&name=phpBB2&file=viewtopic&p=6659#6659


Linux

Easy compiling of tuhopuu under RedHat
http://www.blender.org/modules.php?op=modload&name=phpBB2&file=viewtopic&t=1300

Last edited by matt_e on Sat Oct 11, 2003 6:43 am; edited 6 times in total
Reply with quote


Bischofftep

Posted: Fri Apr 11, 2003 6:08 pm
Joined: 06 Feb 2003
Posts: 37
Hello:

Download the necessary support packages as outlined in the README file included with the CVS sources. Then follow the instructions in the following link to successfully compile using the command line.

http://www.blender.org/modules.php?op=modload&name=phpBB2&file=viewtopic&p=6659#6659

-Bischofftep
Reply with quote


Timothy

Posted: Sun May 11, 2003 5:08 pm
Joined: 29 Sep 2002
Posts: 113
Blender-bf on windows with MSVC 6 and Python 2.22
Hey guys,

I just got the current Blender-bf to compile, by following:
http://www.cise.ufl.edu/~fishwick/blender/make.txt

I still ran into some difficulties though, and the people in #BlenderSauce helped me out with those, anyways here is what I found out today:

- Get Sp5 for visual studio at:
http://msdn.microsoft.com/vstudio/downloads/updates/sp/vs6/sp5/default.asp
or for a direct link to the english version:
http://download.microsoft.com/download/vstudio60ent/SP5/Wideband-Full/WIN98Me/EN-US/vs6sp5.exe

- Don't get the daily-checkout tarballs, instead really pull the modules from the cvs, since somehow the tarballing messes the project files up.

- Be sure to not only checkout the module 'blender' but also check out the module 'lib'

- The following part in the original make.txt can be ignored, that is fixed in the current version:

make.txt wrote:

IMPORTANT: you must now remove a file area and replace it, otherwise the python code will
not build correctly:

4.1: Go to the left window, Press FileView, and locate "BPY_Frozen files". Highlight this
single item, and then Edit->Delete.
4.2: Go to Project->Add to Project->Files and then steer toward the following directory:

C:\blender\source\blender\bpython\frozen, and select all of the C files in that directory


- if you try to compile and get an error that you can't include movies.h download:
ftp://ftp.apple.com/developer/Development_Kits/QT6SDK_Win.hqx
use stuffit to expand it, and place it inthe lib/windows directory.
You will then also need to add the following include and library paths to visual c:
lib\windows\QT6 SDK (Win)\Interfaces & Libraries\QTDevWin\CIncludes
lib\windows\QT6 SDK (Win)\Interfaces & Libraries\QTDevWin\Libraries

- When linking if you get the error:
LINK : fatal error LNK1181: cannot open input file "freetype214ST.lib"
then you need to link with freetype213ST.lib instead:
Project->Settings-> then click on the link tab, find freetype214ST.lib and change it to freetype213ST.lib

- if you get any other strange errors try regetting the modules from the cvs, it may be that someone was just updating them when you were downloading them the first time.

With this blender compiled and linked like a charm and I got myself a nice Blender 2.27 Binary in blender\bin

Greetings,
Timothy

p.s. if you experience any strange errors,.. and end up fixing them,.. be sure to post it here aswell!!!!!
Reply with quote


thornae

Posted: Thu Jul 31, 2003 5:40 am
Joined: 04 Nov 2002
Posts: 44
(Was originally going to post this under a new topic, then saw this sticky. Consolidation is a good thing.)

Introduction: I recently managed (with almost no hiccups) to get the Tuhopuu CVS code compiled and running under FreeBSD 4.8.
Since the Downloads section has the FreeBSD version of Blender 2.8 listed as "Soon", I suspect there's other FreeBSD users out there who might like to try the same thing, but have been put off by the possible complexity of such a task. As I'm something of a neophyte myself, I've decided to write up How To Do It, because it's really not that hard at all. This is therefore mainly aimed at coding novices, so apologies if it's overly simplistic for you.



Preparation: First, of course, you're going to need to grab the Tuhopuu CVS sources. Create and enter the directory you want to work from (in my case, it's ~/Working/Blender/Tuhopuu/), and then follow the instructions for Anonymous CVS Access.
If you get an error about a missing or incorrect .cvspass file, you'll need to create one in your home directory and set the correct permissions.
Since there's only one module in the CVS Repository, the modulename we want is "blender".

So, our steps up to this point will look something like this:
% mkdirhier ~/Working/Blender/Tuhopuu; cd ~/Working/Blender/Tuhopuu
Create and move into directory we'll be working from
% ls ~/.cvspass
ls: /home/me/.cvspass: No such file or directory
% touch ~/.cvspass
% chmod 600 ~/.cvspass

Check for the existence of a .cvspass file - if it's not there, create it and set permissions
% cvs -d:pserver:anonymous@cvs.blender.org:/cvsroot/tuhopuu login
% cvs -z3 -d:pserver:anonymous@cvs.blender.org:/cvsroot/tuhopuu co blender

Checkout the CVS code as per the project page instructions

Well, that's going to take a while (depending on your connection, of course - sodding dialup) .
Whilst it's going, you can spend some profitable time checking to see if you've got all the necessary ports installed- the essential ones are as follows:
graphics/Mesa3
graphics/jpeg
graphics/png
audio/openal
lang/python
print/freetype
security/openssl

To check if you've got these, use pkg_info as follows:
% pkg_info|grep -i mesa
Mesa-3.4.2_2 A graphics library similar to SGI's OpenGL


Since they're all pretty popular as dependancies, you'll probably have most if not all of them already. If you're missing any, I'm assuming you know what to do (aren't ports wonderful?).

Compilation: Now, once the Tuhopuu CVS code has finished downloading, it's time to get it ready to compile. This is really hard - it took me at least a minute. Very Happy
Go into the blender directory, and edit the Makefile there. For simple tasks like this, I tend to use FreeBSD's builtin ee editor.
% pwd
/home/me/Working/Blender/Tuhopuu
% cd blender
% ee Makefile


The first thing we have to change is the assumption that the make on our system is gnumake: Find the line
export GMAKE ?= make
and change it to
export GMAKE ?= gmake

Next, we'll disable the ketsji to speed things up - that's the new game engine, and if you're using this guide, you almost certainly don't want it. A few lines up from the line about GMAKE you'll find
# Not working on the ketsji? Why spend time compiling it?
# export NO_KETSJI=true

Change that second line to
export NO_KETSJI=true

Now, the last thing we need to do is correct the Makefile about where to look for all those include files and such. Most Linux systems have everything directly under /usr, but FreeBSD uses /usr/local. Find the following lines
export NAN_MESA ?= /usr
export NAN_OPENSSL ?= /usr
export NAN_PYTHON_VERSION ?= 2.2
export NAN_PYTHON ?= /usr/
export NAN_OPENAL ?= /usr/
export NAN_JPEG ?= /usr/
export NAN_PNG ?= /usr/
export NAN_ZLIB ?= /usr/
export NAN_FREETYPE ?= /usr/

and add a local to the lines that need it, thus:
export NAN_MESA ?= /usr
export NAN_OPENSSL ?= /usr/local
export NAN_PYTHON_VERSION ?= 2.2
export NAN_PYTHON ?= /usr/local
export NAN_OPENAL ?= /usr/local
export NAN_JPEG ?= /usr/local
export NAN_PNG ?= /usr/local
export NAN_ZLIB ?= /usr/local
export NAN_FREETYPE ?= /usr/local


NAN_MESA shouldn't need to be altered, as Mesa installs in /usr/X11R6, just like on a Linux system.

Save the Makefile, and exit to the command line.
Hopefully, everything should now be ready. Type gmake (not make!) and sit back and wait.

Eventually, if nothing goes wrong, compiling should finish something like this:

...
/bin/rm /usr/home/me/Work/Blender/Tuhopuu/blender/obj//freebsd-4.8-i386/debug/buildinfo.o
****> Build 11:29:51 31-Jul-2003 - 11:31:27 31-Jul-2003
NAN_PYTHON_VERSION=2.2
gmake[2]: Leaving directory `/usr/home/me/Work/Blender/Tuhopuu/blender/source'
gmake[1]: Leaving directory `/usr/home/me/Work/Blender/Tuhopuu/blender/source'
gmake: Leaving directory `/usr/home/me/Work/Blender/Tuhopuu/blender'
%


The compiled executable should be located at blender/obj/freebsd-4.8-i386/debug/blenderdynamic

Launch it with the dot execute shortcut, cross your fingers, and have fun!
% ./blender/obj/freebsd-4.8-i386/debug/blenderdynamic

Well, that's how I got it running. I doubt I'll be able to help much if people run into problems with this, but hopefully someone with a bit more savvy can jump in if needed.
Incidentally, bf-blender is even easier - there's a shellscript in the main directory specifically for FreeBSD compilation.

Good luck, and happy BSD Blending!

лк
Reply with quote


alt

Posted: Sun Aug 03, 2003 10:46 pm
Joined: 17 Dec 2002
Posts: 64
thornae:
Thank you!!
I have been waiting and waiting and still there's no 2.28 for FBSD. Now I can at least compile Tuhopuu when I get desperate enough Smile
Reply with quote


thornae

Posted: Tue Aug 05, 2003 11:01 am
Joined: 04 Nov 2002
Posts: 44
alt wrote:
I have been waiting and waiting and still there's no 2.28 for FBSD. Now I can at least compile Tuhopuu when I get desperate enough


Seriously, grab the CVS for bf-blender (which is Blender 2.28 ). You'll need to checkout both the blender and lib directories, but once you have, there's a shellscript called compileblender_freebsd-4.7-i386.sh in the blender directory (h_xnan, on the off-chance you read this, you rock).
Run that*, and once it's finished, you should have a Blender 2.28 executable located at {whereever_you've_put_the_CVS_stuff}/blender/obj/freebsd-4.8-i386/bin/blender

*Note: I had to copy an include file from one place to another to get it to run, but now I can't remember what it was. If you do get errors you can't figure out, I might be able to help, but I ain't promising nuttin'. Smile

I've been playing with both, but mainly with Tuhopuu, although it crashes somewhat more often than 2.28, as you'd expect.

Good luck!
_________________
...because I can!
Reply with quote


Coz

Posted: Fri Sep 12, 2003 6:35 pm
Joined: 16 Oct 2002
Posts: 46
I think this should be here:
http://www.blender.org/modules/documentation/intro_source.html An intro to the blender source. Written by Kent Mein

I'm trying to compile blender for first time and was the one who helped me the most. Also was the last one I found Sad

EDIT: I followed the file in the cvs for Windows under Cygwin
http://projects.blender.org/viewcvs/viewcvs.cgi/blender/doc/README.windows-gcc?cvsroot=bf-blender
And could compile Blender using Cygwin quite easily.. follow every step carefully because one mistake I did had me crazy for one day...
Reply with quote


hpygocrazy

Posted: Sat Sep 27, 2003 3:03 am
Joined: 01 May 2003
Posts: 9
The link for the tips on compiling with mingw does not work. I would like any info on how to compiler Blender with devc++/mingw. Thanks
Reply with quote


chriskeith

Posted: Sat Oct 11, 2003 4:46 am
Joined: 15 Sep 2003
Posts: 42
Here's my page on building Blender on Windows:

http://home.pacbell.net/c_keith/projects/blender/bootstrap.html

It's got a little more detail about adding paths to VC++.
Reply with quote


infotaku

Posted: Thu Jan 01, 2004 8:05 am
Joined: 31 Dec 2003
Posts: 5
...and here is my post on how to get Blender-cvs to compile on a SUSE9 box

Happy Blending SUSE!! Smile
Reply with quote


ancienthart

Posted: Mon Feb 16, 2004 8:57 am
Joined: 03 Nov 2002
Posts: 6
I've just put up a guide for getting the game engine compiled on a Mandrake 9.2 system. (Using the NVIDIA drivers, but I don't think that matters that much.)

http://www.blender.org/modules.php?op=modload&name=phpBB2&file=viewtopic&t=3002
Reply with quote


brunobrocoli

Posted: Mon Mar 22, 2004 9:26 am
Joined: 23 May 2003
Posts: 31
Is there some help out for BeOs/Zeta as well?
Reply with quote


xanatose

Posted: Tue Jul 13, 2004 10:48 pm
Joined: 01 Jul 2004
Posts: 11
Visual C++ 2003 does not have a iostream.h header, thus
in the files:

source\gameengine\GameLogic\SCA_KeyboardManager.cpp
source\gameengine\GameLogic\SCA_IInputDevice.cpp

change the

Code:

#include <iostream.h>


to

Code:

#if _MSC_VER >= 1300
#include <iostream>
using namespace std;
#else
#include <iostream.h>
#endif
Reply with quote


TheAppleMan

Posted: Sat Jul 31, 2004 3:50 pm
Joined: 17 Jul 2004
Posts: 4
A few days ago I was looking around to find tutorials to build blender. I looked on this thread but it didnt help me much. Whilst chatting on IRC I was told instructions on how to compile blender...and 5 hours later I had my own distro. So I scrounged around my logs and thought to write my own tut.

http://www.theappleman.pwp.blueyonder.co.uk/compiletut.html

The tut is for windows FROM SCRATCH.
Reply with quote


renderedbrian

Posted: Wed Aug 11, 2004 8:13 pm
Joined: 25 May 2003
Posts: 11
TheAppleMan wrote:
A few days ago I was looking around to find tutorials to build blender. I looked on this thread but it didnt help me much. Whilst chatting on IRC I was told instructions on how to compile blender...and 5 hours later I had my own distro. So I scrounged around my logs and thought to write my own tut.

http://www.theappleman.pwp.blueyonder.co.uk/compiletut.html

The tut is for windows FROM SCRATCH.


Thank you!!

Just what I've been looking for!

Very Happy
--
Brian
Reply with quote


Goto page 1, 2, 3, 4, 5, 6, 7  Next
 
Jump to:  
Powered by phpBB © 2001, 2005 phpBB Group