source: orange/INSTALL.txt @ 10998:21975a677988

Revision 10998:21975a677988, 3.1 KB checked in by markotoplak, 18 months ago (diff)

Moved  trac:BuildingFromSource to the repository.

Line 
1== Building From Source ==
2
3=== Prerequisites ===
4
51. C++ tool-chain. Supported compilers are gcc (g++) for Linux and Mac OS X and Microsoft Visual
6C++ on Windows (MinGW is not supported at this time). Clang also works for MAC OS, but see details below.
7[[BR]]
8
9* On Windows install the free [http://www.microsoft.com/express Visual Studio Express]
10* On Linux use the distribution package management tools
11* On Mac OSX install the [http://developer.apple.com/xcode XCode developer tools]
12
13You will also need python and numpy development header files. They are included in python
14and numpy installation on Windows and Mac OSX, but are in separate packages on Linux,
15for instance 'python-dev' and python-numpy-dev' on Debian derived distributions.
16
17=== Obtaining source ===
18
19Either:
20
21* Download the latest nightly packed sources archive and unpack it.
22
23* Clone the Mercurial repository:
24
25    hg clone https://bitbucket.org/biolab/orange
26
27== Build and Install==
28
29=== With setup.py (suggested) ===
30
31The easiest way to build Orange from source is to use the setup.py in the root
32Orange directory (requires administrative privileges). Just run:
33
34python setup.py build
35python setup.py install
36
37Alternatively, you could install Orange into the user specific site-packages
38(see http://docs.python.org/install/index.html#how-installation-works).
39You will need to add the install dir to PYTHONSITEPACKAGES environment variable
40(because Python needs to process Orange's .pth file)
41
42If clang is the default compiler it is necessary to add the `-Wno-address-of-temporary`
43flag to the CPPFLAGS environment variable before running setup.py:
44
45export CPPFLAGS=-Wno-address-of-temporary
46python setup.py build
47
48To install in development mode (http://packages.python.org/distribute/setuptools.html#development-mode)
49run the following command instead of "python setup.py install":
50
51    python setup.py develop
52
53=== Using make ===
54
55This is only useful to developers of the C++ part (this can only build the extensions
56in-place and does not support an install command).
57
58First change the working directory to the 'source' sub-directory then run make:
59
60cd source
61make
62
63this will build the orange core extensions in the root directory (i.e. the one you started in).
64Useful environment variables:
65
66 * PYTHON - names the python executable for which Orange is being build.
67 * CXXFLAGS - flags to pass to C++ compiler
68 * CFLAGS - flags to pass to C compiler
69 * LDFLAGS - flags to pass to the linker
70 * EXCLUDE_ORANGEQT - if set to any value will cause orangeqt to not be build
71
72See source/orangeqt/README.txt for building orangeqt alone.
73
74== Linking to external libraries  ==
75
76The Orange source includes some third party libraries that are statically linked
77into Orange by default:
78
79 * BLAS (a subset)
80 * LIBSVM (v3.2 - v3.* is required)
81 * LIBLINEAR (v1.8)
82 * QHull
83
84To customize the build process to link to the corresponding external library instead, try.
85
86* For the setup.py method modify the setup-site.cfg file.
87
88* For make, pass the library names on the command line or through environment variables (listed
89in source/Makefile). Example:
90
91make BLAS_LIB=atlas
92
Note: See TracBrowser for help on using the repository browser.