Commit Graph

282 Commits

Author SHA1 Message Date
Nathan Letwory
71cb745941 Commit to cope with API changes in OpenCOLLADA (latest for Windows right now r827). 2011-01-27 19:39:06 +00:00
Campbell Barton
1bd0db59f4 use cmake defined names for jpeg, png, zlib and python libs, building on *nix with non-standard libjpeg/png/zlib locations was broken.
in the case of python this makes it easier to move to find_package(PythonLibs) when 3.x is supported.
2011-01-25 14:43:13 +00:00
Campbell Barton
8a3beb0012 import/export automated testing using CMake's CTest
Will need to write full docs on this on the wiki.
basic info.
- 21 tests, OBJ/3DS/X3D/FBX, 3 tests per format import export. STL, PLY, BVH are TODO.
- uses files in ../lib/tests (checkout separate)
- run with CMake Makefiles "make test" or "ctest"
- currently checks against basic MD5 hash on scene import and file MD5 hash on export (realize this wont work predictably on binary formats *TODO*).
- currently uses a generic script for all tests with arguments to specify command to run, expected output, testing method, files to check against etc.

Has already proved useful, found a number of bugs in import export and some in blender too.
2011-01-21 00:06:30 +00:00
Campbell Barton
00b8c9e7ea rename BKE_assert() --> BLI_assert(). 2011-01-09 15:12:08 +00:00
Campbell Barton
54ceccd0ee - cmake use execute_process, exec_program is deprecated.
- game engine builds without python again.
2011-01-07 08:43:29 +00:00
Mitchell Stokes
f6a034a481 CMake fix so MSVC works again. Fix suggested by Tamito Kajiyama. 2011-01-02 10:21:03 +00:00
Campbell Barton
6fdfa97edb CMake: use blender_include_dirs("${OPENGL_INCLUDE_DIR}") rather then blender_include_dirs(${OPENGL_INCLUDE_DIR})
Apparently this is needed for MSVC in some cases, reported by Tamito Kajiyama r33895.
2010-12-31 04:29:11 +00:00
Nathan Letwory
71eb4a2312 Work around cmake error on Windows. 2010-12-27 09:33:32 +00:00
Guillermo S. Romero
29799bf09c Compact -I paths in makefiles for more readble files/output.
Also some white space cleaning and removal of redundant parameter.
2010-12-22 22:15:20 +00:00
Campbell Barton
0d9ead00f8 fix for cmake flag detection, was not caching the resulting variable so the test ran each time.
also cache SSE, SSE2 checks.
2010-12-21 03:32:51 +00:00
Campbell Barton
566bda734a last commit to fix warnings didnt set them at all, not it works as it should.
also made cmakes output a lot quieter, messages can be uncommented for debugging or added back if other devs need this for some reason.
2010-12-16 12:48:30 +00:00
Campbell Barton
ed4e7271f1 CMake now tests warnings are supported, GCC 4.0 wasn't working because of unsupported warnings.
this can work for other compilers too, currently intel and gcc use this.
2010-12-16 09:55:35 +00:00
Campbell Barton
35fa581403 BKE_assert(), only prints the error unless cmake define WITH_ASSERT_ABORT is enabled and it will call abort().
made this option advanced so people don't enable along with other features.
2010-12-15 10:22:26 +00:00
Campbell Barton
1622385445 pedantic word ordering change.
- wm.add_modal_handler -> modal_handler_add
- wm.add_fileselect -> fileselect_add
- ob.add_shape_key -> shape_key_add
- VIEW3D_OT_add_background_image -> VIEW3D_OT_background_image_add (same for remove)

Also made 2 internal cmake vars hidden.
2010-12-08 11:42:11 +00:00
Campbell Barton
cea760ac5a this change broke building. 2010-12-08 09:50:49 +00:00
Campbell Barton
eb26103822 cmake - mark vars as advanced so they dont show up by default when configuring. 2010-12-08 09:02:08 +00:00
Campbell Barton
afacd18498 use lowercase for cmake builtin names and macros, remove contents in else() and endif() which is no longer needed. 2010-12-08 08:43:06 +00:00
Campbell Barton
d64f46e0bb CMake: use a global list to store libraries built rather then cmake_blender_libs.txt file. 2010-12-06 10:56:37 +00:00
Campbell Barton
263830f000 Enabled GCC -Wwrite-strings warning for CMake and replaced many 'char's for 'const char's,.
Only one functional change where Transform orientations passed "" to BIF_createTransformOrientation() which could then have the value written into.
2010-12-03 17:05:21 +00:00
Campbell Barton
cd97253502 - added GCC warning -Wstrict-prototypes
- fixed bug in paste material, exposed by stricter warnings.
- removed/renamed various shadowed vars.
- removed BGE lamp.colour, only allow lamp.color attribute.
2010-12-03 12:30:59 +00:00
Campbell Barton
3e173f4d21 disable redcode support for cmake & scons-freebsd 2010-12-01 07:25:59 +00:00
Campbell Barton
42d6603cae Add option for CMake to build libredcode, also use CODEC prefix for ffmpeg, quicktime & sndfile options. 2010-11-30 18:52:39 +00:00
Nathan Letwory
a5cecd8284 Remove library specification. 2010-11-24 09:13:59 +00:00
Campbell Barton
5a37554b1e disallow disabling WITH_SAMPLERATE if any audio outputs are enabled. 2010-11-21 16:32:11 +00:00
Campbell Barton
c85c2746df WITH_SAMPLERATE option for cmake, without this playback wont behave right so this is mainly intended for developers who build without audio enabled. 2010-11-21 14:32:55 +00:00
Campbell Barton
39b7bfe6bd - check IF WIN32 AND NOT UNIX (for cygwin)
- patch from Mike S to enable OpenMP and xcode
2010-11-21 13:41:43 +00:00
Campbell Barton
cd2ab75b73 - include pthreads for win32 globally (as with opengl).
- MSVC CFLAGS were being set by only checking WIN32, (breaking non-msvc win32 builds)
2010-11-21 09:10:50 +00:00
Campbell Barton
a04bbb2374 use CMake's OpenMP built in detection rather then defining flags ourselves. 2010-11-19 11:33:12 +00:00
Campbell Barton
8fee983619 patch from Dan Eicher to support intel C++ compiler for CMake on *nix. 2010-11-15 05:32:49 +00:00
Andrea Weikert
dcda17b3b3 == filebrowser ==
Bringing back missing feature: Create new directory by typing a not existing name into the directory button.

Note: Small issue still with autocomplete -> if typing the new directory directly after autocomplete, it doesn't execute the operator yet.

Also fixed some minor compile/cleanup issues with warning about signed/unsigned comparison and missing header.
2010-11-06 16:09:12 +00:00
Campbell Barton
66b274766a minor c90 compat edits. (no functional changes). 2010-11-05 13:37:18 +00:00
Sergey Sharybin
228ed6f086 Global definition of _LARGEFILE_SOURCE, _FILE_OFFSET_BITS and _LARGEFILE64_SOURCE at linux and win32/mingw platforms
Needed to work properly with large files at 32bit system (display correct size in file browser, i.e.)

This will also fix compilation with zlib 1.2.5
2010-11-04 17:02:25 +00:00
Campbell Barton
dba1904f65 bugfix [#24518] Blender wont compile with -Wall -Werror and COLLADA support
fix included in report from Martijn Berger (mberger)
made some small changes.

- use ints rather then unsigned long for printing, values are not likely to be very large.
- CMake remove strict flags from collada build dir since I had warnings in the collada headers.
- added xml2 to collada libraries else I couldnt get collada building.
2010-11-03 22:44:39 +00:00
Campbell Barton
6b677a2616 own recent commit broke this python import:
from mathutils.geometry import PolyFill

I couldn't find a way for python's inittab to do this so just inserting mathutils.geometry into sys.modules manually.
2010-10-31 13:17:39 +00:00
Campbell Barton
05b297c52f CMake options to disable Decimate and Boolean Modifiers: WITH_MOD_BOOLEAN, WITH_MOD_DECIMATE, renamed WITH_FLUID to WITH_MOD_FLUID 2010-10-23 15:40:13 +00:00
Nathan Letwory
c4ad3cb5c4 Same warning suppression as with SCons 2010-10-21 07:48:51 +00:00
Nathan Letwory
db74070778 Make C4013 throw a warning
-> 'function' undefined; assuming extern returning int
2010-10-19 05:42:31 +00:00
Campbell Barton
799fc68234 cflags, cxxflags & linkflags in buildinfo. 2010-10-18 12:56:14 +00:00
Campbell Barton
6d0d688943 define NDEBUG for release builds so assert() is disabled. 2010-10-18 12:35:40 +00:00
Campbell Barton
58683fa993 enable DEBUG define in CMake and scons, also change booleans debug option to BOP_DEBUG, which was used inconsistently, and had to add a define for superlu. 2010-10-18 11:21:22 +00:00
Campbell Barton
c7c128f03b remove LCMS option from cmake, this is only testing code. developers who want to work on it can uncomment. 2010-10-17 23:32:48 +00:00
Campbell Barton
952b728578 Test stricter GCC compiler settings, these warnings will now give errors.
- implicit function declaration.
- no return type set for a function.
- declaration after statement.

This may be too strict but in general I prefer we don't allow commits with these warnings.
Applies to cmake/gcc and scons/linux.
2010-10-17 08:04:28 +00:00
Campbell Barton
30b79ddcc6 - fixed remaining unused warnings.
- omit render code from this warning (cmake only), until render branch is merged.
- moved -Wunused-parameter warning to apply to all C code in blender (not just ./source/blender), (cmake only).
2010-10-17 06:38:56 +00:00
Campbell Barton
271bbf4a0d fix for own recent unused commit that broke with OpenMP enabled.
also build ./source/ first with cmake since testing new changes are most likely to be made here.
2010-10-15 07:26:26 +00:00
Campbell Barton
f0fcf140f8 enable warning for unused args with gcc: -Wunused-parameter
- for cmake only apply this to source/blender, will apply globally later.
- ./extern/ ./source/blender/makesrna/intern/ ignore this.
2010-10-15 02:24:48 +00:00
Luca Bonavita
9f05cc59fa == docs ==
- moved files in proper directories and adapted paths where needed
- deleted doc/oldbugs.txt (asked confirmation to jesterking a week ago in irc)
- still working on doxygen files, for now I'll leave them in doc/
- NOTE: while checking if other files were referring to these files, I noted that
  "GPL-license.txt" is also used in the files below:
    - release/windows/installer/00.sconsblender.nsi
    - release/windows/specific.sh
  but these files should't be affected by this commit, but please check :)
2010-10-13 14:44:22 +00:00
Campbell Barton
9347dd04a3 bugfix [#24231] outliner not refreshed correctly
also made world changes only redraw the 3d view if 'Render Only' option is set.
2010-10-13 01:10:56 +00:00
Campbell Barton
f49fc58df6 enable building the game engine without bullet for scons & cmake 2010-10-10 07:01:56 +00:00
Nathan Letwory
fdadab1006 COLLADA exporter: split camera and light export into own files. 2010-10-06 07:13:42 +00:00
Nathan Letwory
31ff2a6da2 Enable lcms support on Windows. 2010-10-05 13:39:45 +00:00
Campbell Barton
e568ea668e revert r32284, turns out OpenSuse needs this for forkpty(), also fixed missing import with 3ds export. 2010-10-04 11:42:39 +00:00
Campbell Barton
11acab00b0 cmake/mingw was missing defines. 2010-10-03 23:27:33 +00:00
Campbell Barton
3e3e10668e linking libutil isnt needed on my system, possibly this is deprecated?,
testing this on other linux systems isnt so easy but will hear about it if this breaks.
2010-10-03 18:45:27 +00:00
Campbell Barton
19704f74b1 recent fixes for mingw + cmake broke msvc 2010-09-16 07:26:06 +00:00
Campbell Barton
9b518710c6 update for MingW/CMake
- ignore MSVC warnings when FREE_WINDOWS is defined to quiet warnings.
- the CMake flags were not being set correctly making blender have weirdo colors (no -funsigned-char).
2010-09-15 16:13:32 +00:00
Campbell Barton
d5ee95644d win32 mingw works again with cmake 2010-09-15 14:36:32 +00:00
Campbell Barton
74059891e9 option to disable ITASC IK solver, (will be enabled by default ofcourse)
- option only available to cmake, scons and make have this enabled always.
- without this clang/llvm can compile blender
- this was the second biggest internal lib, 192mb -> 172mb for all blenders libs (with debug flags), so gives some speedup to linking.
2010-09-12 12:27:12 +00:00
Campbell Barton
2406ebe1a4 - added back zlib include (needed for win32).
- use list append in more places.
- remove non existing include dir.
2010-09-07 01:13:10 +00:00
Campbell Barton
04b0dcd9e5 - use list append in more places (preferred method since its faster)
- remove some unused include paths
- remove unused linux path define
2010-09-06 10:15:41 +00:00
Nathan Letwory
3de9aa38cd * Don't use /ZI when 64bit building on Windows. Use /Zi instead.
* Copy files to ${BLENDER_VERSION} instead of .blender/
* Don't try to copy iconv.dll when 64bit building on Windows - it is static for 64bit.
2010-09-01 05:39:26 +00:00
Campbell Barton
6464718083 rename some cmake build targets 2010-08-24 04:29:23 +00:00
Campbell Barton
51c0e9b87c cmake patch from lux-integ. 2010-08-23 01:17:14 +00:00
Campbell Barton
e588e8e741 bugfix [#23257] cmake tests for SSE, but SSE2 gets enabled
patch from Vinay Pawar, some minor changes by me.
2010-08-11 08:23:48 +00:00
Campbell Barton
8902a4b2f1 [#23162] GCC 4.2 and prior support broken in CMakeLists.txt as of r30985
revert warning changes from r30985, broke with older GCC
2010-08-04 00:18:05 +00:00
Campbell Barton
957976882d build options to disable image formats WITH_CINEON, WITH_HDR.
- updated cmake, make & scons.
- renamed CMake build options WITH_TIFF -> WITH_IMAGE_TIFF, same for DDS, OPENJPEG etc.
2010-08-03 11:25:34 +00:00
Campbell Barton
7bd687ea58 cmake
- more strict warnings for gcc/unix, still <50 for a clean build.
- install files to /usr/local/share/blender/2.53 rather then /usr/local/share/blender/.blender
2010-08-02 16:23:58 +00:00
Campbell Barton
00149cfb9d patch [#23041] CMake WITH_PYTHON_INSTALL option
from Dan Eicher (dna)

--- snip ---
Adds the option to not copy python into the .blender/python directory.

Also fixes the problem of deleting the blender installed python where the blender runtime only looks for the copied python and not the system one but not entirely sure why, something to do with CMake hardcoding the PYTHONPATH and PYTHONHOME vars I suppose.

This patch only applies to the 'UNIX AND NOT APPLE' platforms but, then again, those are the only ones anyone really
cares about...or at least the only ones where using the system python is really viable.
2010-07-26 23:16:21 +00:00
Campbell Barton
1bb789956d CMake patch from Ralf Hölzemer (cheleb)
[#22849] Fix cmake install target on linux
--- from the tracker ---
This patch fixes the install target for the linux platform. Since the new configuration path changes are in effect, files have to be installed in the correct places instead of just copying the local installation to $PREFIX/share/blender.

It also provides a new macro to determine the correct blender version values.

Changes in this patch include:

- the .desktop menu file is installed in $PREFIX/share/applications and points to the svg icon instead of a png one, which is also installed in $PREFIX/share/pixmaps
- docs are installed in $PREFIX/share/doc/blender
- scripts are installed in in $PREFIX/share/blender/x.xx/
- locales are installed in in $PREFIX/share/blender/x.xx/datafiles
- a new cmake macro determines and sets the correct values for BLENDER_VERSION_MAJOR, BLENDER_VERSION_MINOR, BLENDER_SUBVERSION, BLENDER_VERSION, BLENDER_MINVERSION_MAJOR, BLENDER_MINVERSION_MINOR, BLENDER_MINSUBVERSION and BLENDER_MINVERSION by parsing source/blender/blenkernel/BKE_blender.h and calculating major/minor values. This replaces the hardcoded value in the top CMakeLists file and is used by all platforms.
2010-07-14 20:26:46 +00:00
Campbell Barton
d4b04fac04 partial fix [#22846] GCC 4.4.1 support in Windows
Still getting error:
 Warning: .drectve `/DEFAULTLIB:"LIBCMT" /DEFAULTLIB:"OLDNAMES" ' unrecognized
2010-07-14 18:22:39 +00:00
Campbell Barton
d80d6e2812 re-arrange build files so scons "config" dir isnt confused with ~/.blender/2.52/config 2010-07-12 18:26:35 +00:00
Campbell Barton
0a11d4c81d [#22817] Beta patch for cmake-MinGW compilation no 2
ommit FORCE CFlags, else users cant change their cflags.
2010-07-12 09:55:41 +00:00
Brecht Van Lommel
efb58cdab9 Fix #22219: compile error with videotexture/libavutil and recent gcc,
need __STDC_CONSTANT_MACROS defined.
2010-07-07 15:24:06 +00:00
Brecht Van Lommel
6c0f3d052e Detect SSE building support with cmake, and moved setting the defines
out of the render mode cmake file into the main one. Should fix PPC
compile, and hopefully not break others.
2010-07-04 18:40:59 +00:00
Campbell Barton
37b4e2af77 cmake: disable openexr if its not found (rather then throwing an error) 2010-07-03 15:03:13 +00:00
Damien Plisson
ec770b7538 OSX: CMake and scons default settings updated to allow build with LCMS lib 2010-07-03 10:01:41 +00:00
Campbell Barton
0fa0d12ff0 fix for building with WITH_RAYOPTIMIZATION 2010-07-01 13:21:40 +00:00
Brecht Van Lommel
93238c3a3d Runtime detection of SSE support for raytracing. Also enabled rayoptimization
by default now on all platforms since it shouldn't crash anymore if SSE is
not there. If this breaks compilation on some platforms, please let me know.
2010-06-24 15:54:01 +00:00
Campbell Barton
d36da839b1 reverting own recent change to switch off RULE_MESSAGES since you cant see which files are rebuilding. 2010-06-09 06:21:07 +00:00
Campbell Barton
ab0d12a3b6 minor changes to cmake, main noticable change is to disable RULE_MESSAGES which gives less output with makefiles (easier to spot warnings). 2010-06-07 14:28:37 +00:00
Campbell Barton
d153c765bc CMake:
- WITH_LCMS added option, was supported in scons.
- commented web plugin option since its not maintained.
- some formatting changes and removed includes that are not needed for source/creator/CMakeLists.txt.
2010-06-06 13:32:58 +00:00
Nathan Letwory
a6d5f43ac8 * update CMake and SCons for the OpenCollada update (to r746).
- DocumentExporter changed due to function name change in API
  - no more UTF lib
  - enabled by default for win32

Note: debug libs will be added later, as well as 64bit windows libs.

For other platforms, get r746 of OpenCollada and build against that.
2010-06-06 00:33:59 +00:00
Campbell Barton
a836aad094 mingw/cmake ffmpeg works now, update for new openexr libs which removed IlmThread. 2010-05-30 15:55:16 +00:00
Dalai Felinto
c6bec43330 reverting previous commit from Mitchell. His commit went to the trunk instead of the branch :)
svn merge -r 29067:29066 https://svn.blender.org/svnroot/bf-blender/trunk/blender
2010-05-29 21:31:57 +00:00
Mitchell Stokes
9d3157eed0 Reversing the last merge because I botched it. 2010-05-29 21:22:24 +00:00
Sergey Sharybin
28d3a17cf4 Updated openexr for MinGW 2010-05-29 18:28:01 +00:00
Campbell Barton
d86ad8e671 disable forcing mingw compiler flags (means you couldnt change them) 2010-05-29 11:36:33 +00:00
Campbell Barton
5aa1d2bb25 removed WIN32 definition for msvc last commit (to get mingw working)
added back definition as well as checking if some options need to be set.
2010-05-29 07:31:40 +00:00
Campbell Barton
40d7eac69e [#21842] Beta patch to restore cmake MinGW compilation
from Riakiotakis Antonis (psy-fi) 

with modifications.

notes:
- needed to remove quotes around filepaths for copying.
- WITH_JACK, doesnt link
- WITH_FFMPEG, doesnt build
- WITH_RAYOPTIMIZATION, gave an error for me. (no mmx support)
2010-05-28 21:25:23 +00:00
Andrea Weikert
1ba9766ab5 == CMake ==
* updated for new libtiff
* also disabled opencollada for now as it caused errors

Note:
* WITH_INTERNATIONAL is enabled although this setting crashes Blender when compiling the Debug target - seems to work for other people though? If you encounter problems, try disabling this.
2010-05-27 18:22:50 +00:00
Campbell Barton
bd3bd5dea5 if libtiff not found disable on unix. 2010-05-21 04:40:04 +00:00
Campbell Barton
418f1fcba8 libtiff working on linux & cmake again. 2010-05-21 04:23:33 +00:00
Matt Ebb
2be851c966 Blender TIFF support
* Removed dynamic linking libTIFF code and change it to static linking 
(built into the blender executable). Dynamic linking made things a 
fair bit more complicated and wasn't working at all before on OS X - 
the dylib didn't exist and wasn't being copied. Since TIFF is more heavily
depended upon now in Blender, it makes sense to make it less 'optional'
and more in line with other libraries.

I've updated both CMake and scons, and CMake on OS X/64bit works fine.
It's now up to other platform/build system maintainers to enable this for 
their respective platforms (Campbell will check it for linux). For windows,
and non-64bit osx, we need static libtiff libraries in /lib.

I've added options WITH_TIFF for CMake and WITH_BF_TIFF for scons,
so if blender won't build because of this, you should be able to disable 
these options until your build system has been updated.

* Bonus feature: while doing this, I added support for loading 16bit and 32bit 
per channel TIFFs - they get converted to Blender's float buffers. Handy for 
zbrush displacement maps!
2010-05-21 03:25:38 +00:00
Campbell Barton
46a40c9905 minor cmake changes
- only give quicktime option for apple and windows
- disable collada by default on non-apple-unix since its not in debian repo
2010-05-09 14:43:31 +00:00
Campbell Barton
ed4377faa7 replace referenecs to python 2.x 2010-04-20 15:46:28 +00:00
Campbell Barton
4d2bc9f907 mindrones reports cmake 2.4 doesnt work anymore, since 2.8 is current, bumping the minimum version requiired 2010-04-11 12:20:30 +00:00
Damien Plisson
939a83e347 OSX: CMake & scons update for Ogg/Vorbis/FLAC added support to lib SNDFILE
Note that you need to svn up the precompiled lib folder (darwin-*) too to be able to build with SNDFILE
2010-04-03 09:54:38 +00:00
Campbell Barton
391cc2d004 merge own commits into render branch into trunk since 27560
27562, 27570, 27571, 27574, 27576, 27577, 27579, 27590, 27591, 27594, 27595, 27596, 27599, 27605, 27611, 27612, 27613, 27614, 27623
2010-03-20 16:41:01 +00:00
Brecht Van Lommel
148985edf0 CMake: FFMPEG directory and libraries are now configurable. 2010-03-18 10:16:04 +00:00
Daniel Genrich
01939f8472 Win64: Enable OpenAL for cmake + win64 2010-02-22 23:34:45 +00:00
Damien Plisson
7777957521 OSX buildscripts update following ffmpeg precompiled libs update 2010-02-22 16:34:27 +00:00