Commit Graph

3709 Commits

Author SHA1 Message Date
Campbell Barton 4a50f1d4ee Build: unbreak building flex on Rock8 Linux from aclocal-1.16
Flex's bundled configure depended on aclocal-1.15 which has been
updated to 1.16.

Resolve by regenerating configure files on Linux which in turn adds a
new dependency on texinfo.
2024-02-08 11:10:07 +11:00
Campbell Barton 412b279629 Build: unbreak building flex on Rock8 Linux from aclocal-1.16
Flex's bundled configure depended on aclocal-1.15 which has been
updated to 1.16.

Resolve by regenerating configure files on Linux which in turn adds a
new dependency on texinfo.
2024-02-08 10:12:22 +11:00
Thomas Dinges fb0f06a2ac Revert "Release cycle: 4.1, Bcon3"
This reverts commit 4db1426818.
2024-02-07 12:53:08 +01:00
Thomas Dinges 4db1426818 Release cycle: 4.1, Bcon3 2024-02-07 12:49:52 +01:00
Ray Molenkamp ea7c0a4a46 deps_builder: Fix broken hash for sqlite
hash update was missed in ec4b074506
2024-02-06 17:25:18 -07:00
Ray Molenkamp 28208cfddb deps_builder: update ffmpeg diff
did not apply anymore
2024-02-06 14:17:42 -07:00
Ray Molenkamp dfb3482946 deps_builder/win: update perl to 5.38.0.1
5.22.1.3 was incompatible with the latest openssl update.
2024-02-06 14:16:55 -07:00
Ray Molenkamp 0d8710aa2e deps_builder: Update oidn diff
did not apply any more on windows
2024-02-06 14:14:03 -07:00
Stefan Werner 31d55e87f9 Cycles: Metal support for OpenImageDenoise
This is supported on Apple Silicon GPUs and macOS 13.0+.

Co-authored-by: Stefan Werner <stefan.werner@intel.com>
Co-authored-by: Attila Afra <attila.t.afra@intel.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/116124
2024-02-06 21:13:23 +01:00
Xavier Hallade acdc3deaea Build: upgrade OIDN to 2.2-rc2
Minor update over OpenImageDenoise 2.2-rc, fixing the runtime issues on
macOS Ventura. For other platforms the code is identical.

Pull Request: https://projects.blender.org/blender/blender/pulls/117902
2024-02-06 17:43:55 +01:00
Brecht Van Lommel ec4b074506 Build: Update 4.1 libraries to fix CVEs
Pull Request: https://projects.blender.org/blender/blender/pulls/117866
2024-02-06 13:56:16 +01:00
Bastien Montagne a48e825c1e install_linux_packages: Updated OIdenoise, level zero and OCIO versions.
Ref. #113157
2024-02-05 17:45:53 +01:00
Bastien Montagne ec5594ec7f install_linux_packages: update OIIO, OSL, LLVM and USD library versions.
NOTE: Blender does not seem to build with older OpenImageIO versions
(2.4.x and before) anymore. Since this library is now mandatory, it
means that Blender cannot be built without using the pre-compiled libs
on most Debian system, currently.

Ref. #113157.
2024-02-05 16:47:08 +01:00
Nikita Sirgienko 6827400305 Build: Cycles: Backport a DPC++ fix for caching of GPU binaries
Since the addition of Meteor Lake binaries, prebuilt GPU binaries
are now stored as fatbinaries. When running on a platform for which
prebuilt binaries are lacking or considered incompatible, the DPC++
SYCL runtime caching logic failed storing the (re)compiled
compatible version. This patch to DPC++ SYCL runtime fixes it.

Pull Request: https://projects.blender.org/blender/blender/pulls/117844
2024-02-05 13:55:40 +01:00
Xavier Hallade b91ebfb866 Build: upgrade OIDN to 2.2-rc
It includes support for Meteor Lake, the CUDA driver API, and Metal (to
be enabled by https://projects.blender.org/blender/blender/pulls/116124)

Pull Request: https://projects.blender.org/blender/blender/pulls/117752
2024-02-02 18:31:14 +01:00
Xavier Hallade cb643f8e44 Build: upgrade Level Zero to 1.15.8
OpenImageDenoise 2.2 requires at least 1.9.4 and 1.8.8 was used, so we
upgrade to latest version.
2024-02-02 18:31:12 +01:00
Brecht Van Lommel 25acfc7497 Fix: OpenColorIO deps build not finding pystring header 2024-02-02 17:23:05 +01:00
Brecht Van Lommel deb4273565 Build: Bump OpenColorIO to 2.3.2
To fix issues with detection of AVX instruction support.

Ref #113157, #117435
2024-02-02 16:37:30 +01:00
Jeroen Bakker 324ef0cbf4 RenderTest: GPU Render Tests Pass Silently
Add silently fail option to GPU based render tests. This is a pre-requisite to enable
render tests on the buildbot. By default these render tests will pass silently.

* Test will pass when using the `--pass-silently` arguments.
* Only crashes will be reported as failed tests.
* To find out failing test, review the test reports.

`WITH_GPU_RENDER_TESTS_SILENT` compile option can be used to let tests pass (default)
or fail (default for developers).

Although some tests fail, they still passed. In the generated render report,
the silently passed failures are correctly reported to be failures.

Pull Request: https://projects.blender.org/blender/blender/pulls/117629
2024-01-29 15:39:14 +01:00
Sergey Sharybin f11292104d Render Tests: Separate difference of Color and Alpha
This change fixes confusion situation when the render output
is an RGBA image: the difference in color was not visible in
the report because alpha channel was all zeros. This is due
to idiff performing per-channel difference.

The solution to this problem is to have separate images for
color and alpha difference, which makes it clear where the
difference actually is coming from.
2024-01-25 10:04:16 +01:00
Campbell Barton e89fdadf8e CPPCheck: exclude large lookup table in checks 2024-01-25 10:09:00 +11:00
Ray Molenkamp 52152aac90 deps_builder: include all oiio tools for windows
oiiotool is required for PR117481
2024-01-24 08:47:30 -07:00
Stefan Werner d16d2bbd3a Cycles: Adding OIDN support for CUDA and OptiX devices
Small changes to turn on support and to build OIDN with the CUDA backend.

Co-authored-by: Werner, Stefan <stefan.werner@intel.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/115828
2024-01-24 08:19:39 +01:00
Brecht Van Lommel 440b1d9179 Cleanup: cmake warning in make deps 2024-01-23 20:29:07 +01:00
Campbell Barton dd8c42bfaf CMake: mark freetype & tiff directories as advanced
It's not clear what these are used for as they seem like recent
additions and are set to "NOT-FOUND" even when tiff/freetype are found.

Marking as advanced instead of removing so as not to interfere with
freetype/tiff finding logic.
2024-01-23 20:45:19 +11:00
Thomas Dinges 64fc6d7890 Docs: Replace most wiki links with links to new developer docs
Exceptions:
* Links to personal wiki pages
* Pages that are not in the new developer docs yet (like Human Interface Guidelines)
* tools\check_wiki\check_wiki_file_structure.py needs a refactor
2024-01-18 16:49:38 +01:00
Brecht Van Lommel aefa1cd723 Build: bump sse2neon version to latest hash
This includes an additional fix for precision of some operations that affect
Blender tests.
2024-01-16 14:18:33 +01:00
Campbell Barton 6e9e1557bb Cleanup: tabs to spaces 2024-01-14 11:37:04 +11:00
Campbell Barton 95c0968246 Cleanup: quiet mypy warning 2024-01-11 16:29:19 +11:00
Bastien Montagne f23ee504d0 Tests: Improve the sanitizer options handling.
Previous code was using the 'nuclear' SAN weapon `exitcode=0`, which
essentially makes testing ignore all sanitizer errors.

This commit removes this option, and instead uses the suppression
list from Blender source repository (`tools/config/analysis/lsan.supp`)
for the leak sanitizer.

It also enables the `allocator_may_return_null` for the address sanitizer.
This should only be needed for one test (the `guardedalloc` one), but for
now it is simpler to define it for all tests. This can be refined at a
later time.

Pull Request: https://projects.blender.org/blender/blender/pulls/116635
2024-01-09 14:26:36 +01:00
Campbell Barton 5afd33d129 PyAPI: drop support for Python 3.10
All platforms have been updated to support 3.11
so supporting 3.10 is no longer needed.
2024-01-09 22:23:41 +11:00
Campbell Barton cff7415040 Build: bump OpenAL-soft from 1.21.1 to 1.23.1
Along with regular fixes and improvements,
this removes a warning on startup for Linux, see:
https://github.com/kcat/openal-soft/issues/554

Some deprecated CMake variables were removed and needed to be renamed.

Note that the previous URL from http://openal-soft.org/
is no longer responsive, using the GITHUB URL instead.

Ref !116877
2024-01-09 21:29:05 +11:00
Campbell Barton c6485d5947 CMake: quiet undefined variable warnings 2024-01-09 12:38:42 +11:00
Brecht Van Lommel df43c8e7ef Fix macOS not auto updating cmake cache for Python 3.11 2024-01-08 13:14:34 +01:00
Brecht Van Lommel 0e4da8d55f Fix macOS ARM build failing with make lite
OpenImageIO headers have a dependency on Imath headers when not on x86_64.
2024-01-08 13:14:34 +01:00
Campbell Barton 5dd91346e1 Cleanup: remove unused imports 2024-01-08 11:40:53 +11:00
Campbell Barton 2783af45ee Cleanup: trailing newlines 2024-01-08 11:31:43 +11:00
Hans Goudey e90d844dd7 Cleanup: Grammar in comments
"it's own" -> "its own" again. Start new sentences properly.
2024-01-06 09:02:56 -05:00
Bastien Montagne 3e744db9fe Tests: Refactor handling of environment variables when invoking tests.
The current handling had a fairly bad issue: multiple calls to
`set_tests_properties` to set envvars of a same test.

This does not work, only the last call is effective, all previous
ones have absolutely no effect.

This has been addressed by moving all 'set envvar for test' logic into a
single CMake function, `blender_test_set_envvars`.

This function takes optional extra envvars if needed, and define a set
of default ones (currently, `PATH` from `PLATFORM_ENV_INSTALL` if
defined, and the 'nuke' `exitcode=0` `LSAN_OPTIONS` if relevant).

NOTE: The way `blender_test_set_envvars` handles extra envvars passed to
it as parameter is fairly basic and unsafe, in that there is no check
whether a same envvar is defined more than once. Think for now this is
an acceptable limitation.

NOTE: Although this commit _should_ be a non-functional change one, the
unification of the handling of all envvars makes it hard to ensure there is no
side effects.
The `PATH` envvar e.g. was set to either `PLATFORM_ENV_INSTALL` if defined,
or a copy of that variable's definition, but only in Windows case. So technically,
the behavior for this envvar is changed.
2024-01-05 21:13:54 +01:00
Bastien Montagne 95b30b3516 Build: Ninja: Move 'Unity builds' to heavy pooljobs.
This commit adds a new helper to define expected properties when a
target needs to use the unity build feature.

That new helper does what was already done for existing cases, and in
addition add the target to the Ninja 'heavy' pooljobs if relevant.

Pull Request: https://projects.blender.org/blender/blender/pulls/116791
2024-01-05 18:35:48 +01:00
Brecht Van Lommel 8131a636fb Build: bump supported Python version to 3.11 on macOS
Now that the precompiled libraries have been updated.
2024-01-04 02:51:44 +01:00
Brecht Van Lommel 364beee159 Tests: add option to build one binary per GTest file
Bundling many tests in a single binary reduces build time and disk space
usage, but is less convenient for running individual tests command line
as filter flags need to be used.

This adds WITH_TESTS_SINGLE_BINARY to generate one executable file per
source file. Note that enabling this option requires a significant amount
of disk space.

Due to refactoring, the resulting ctest names are a bit different than
before. The number of tests is also a bit different depending if this
option is used, as one uses gtests discovery and the other is organized
purely by filename, which isn't always 1:1.

Co-authored-by: Sergey Sharybin <sergey@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/114604
2024-01-03 18:35:50 +01:00
Brecht Van Lommel f63accd3b6 Cleanup: move CMake test utility functions into testing.cmake
Combining functions from macros.cmake and Modules/GTestTesting.cmake.
It was unusual to have Blender specific code in the Modules folder.

Pull Request: https://projects.blender.org/blender/blender/pulls/116719
2024-01-03 14:49:11 +01:00
Sergey Sharybin b66dec58ed macOS: Silence noisy linker warning about duplicate libraries
The warning was introduced with XCode 15 and conflicted with some
assumptions in the CMake. Even without actual cyclic dependency
between targets CMake might decide to pass library multiple times
to the linker, to ensure all its users find symbols from it.

This behavior is expected to be tweaked in the upcoming CMake
version, but until it is released and became widely used by all
Blender macOS developers silence the warning.

Pull Request: https://projects.blender.org/blender/blender/pulls/116718
2024-01-03 09:24:36 +01:00
Brecht Van Lommel 4ce14a639f Revert "Cleanup: move CMake test utility functions into testing.cmake"
This breaks execution of some Windows tests.

This reverts commit 4190a61020.
2024-01-02 19:06:39 +01:00
Brecht Van Lommel a815594394 Build: bump sse2neon to latest main
The 1.7.0 version introduced compiler wanings on clang, use a
newer revision with a fix.
2024-01-02 17:29:46 +01:00
Brecht Van Lommel 1f3ce2a311 Build: changes to macOS build flags to fix linker warnings
* Different fix for Mantaflow linker warnings that works with new OpenVDB.
* Use new linker for arm64 as it no longer produces warnings with latest
  Xcode. Still use the old one for x86_64 as some warnings remain.
* Fix wrong x86_64 build target in deps builder.

For the upcoming 4.1 libraries.

Ref #113157

Pull Request: https://projects.blender.org/blender/blender/pulls/116708
2024-01-02 16:22:48 +01:00
Brecht Van Lommel 4190a61020 Cleanup: move CMake test utility functions into testing.cmake
Combining functions from macros.cmake and Modules/GTestTesting.cmake.
It was unusual to have Blender specific code in the Modules folder.
2024-01-02 15:34:52 +01:00
Brecht Van Lommel e016c1d6c3 Build: bump sse2neon to version 1.7.0
Stable release instead of git hash.

Ref #113157
2024-01-02 14:40:47 +01:00
Ray Molenkamp fcbb94ed1e deps_builder: include OIIO PR #4062
OIIO was including imaths half.h when it did not
need to, leading to build errors in lite builds.
This issue had been fixed already upstream but
was not yet included in the version we use.
2023-12-26 12:50:10 -07:00
Ray Molenkamp c6ae08b06b deps_builder: build fixes for oidn
- OIDN doesn't need to be build for debug builds on windows, while
it's mostly C++ code its public API is C
- Python was not found by the HIP build
- Level Zero was downloaded during the build.
2023-12-23 11:45:11 -07:00
Campbell Barton e18e4a1acf CMake: default to Python 3.10 for macOS
The recent bump to 3.11 should have only changed Linux as updated macOS
libraries have not yet been committed.
2023-12-23 16:19:09 +11:00
Campbell Barton 526019b559 CMake: default to Python 3.11, auto-update existing variables 2023-12-23 14:39:55 +11:00
Campbell Barton 248d7d8340 Fix use of undefined IMATH_INCLUDE_DIRS
New include directory variable from [0] was only set for WIN32,
causing openimageio to fail to build with libraries updated for 4.1.

[0]: 802ac5ba5a
2023-12-22 21:27:51 +11:00
Brecht Van Lommel 802ac5ba5a Build: Library updates for 4.1
Update libraries to match VFX platform 2024, and a few other upgrades to
latest versions.

boost 1.82.0
deflate 1.18 (new)
ffi 3.4.4
freeglut (deleted)
ispc 1.12.1
llvm 17.0.6
materialx 1.38.8
mesa 23.3.0
numpy 1.24.3
opencolorio 2.3.0
openexr 3.2.1
openimageio 2.5.6.0
opensubdiv 3.6.0
openvdb 11.0.0
osl 1.13.5.0 (now dynamic)
python 3.11.6
sqlite 3.42.0
sse2neon 0d6e9b3dd4
usd 23.11
vulkan 1.3.270
xm2 2.12.3

This only updates the build scripts, the precompiled libraries for each
platform will land over the coming weeks.

Ref #113157

Co-authored-by: Ray Molenkamp <github@lazydodo.com>
Co-authored-by: Campbell Barton <campbell@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/116420
2023-12-21 19:16:11 +01:00
Brecht Van Lommel 7df6d9eb52 Build: update Windows ocloc to store binaries per generation
Same as #115750 for Linux, to gain space and compile time.

Pull Request: https://projects.blender.org/blender/blender/pulls/116159
2023-12-14 11:25:23 +01:00
Stefan Werner fd8bb41224 Cycles: Enable HIP devices for OpenImageDenoise
This enables the HIP backend of OpenImageDenoise on supported devices.

Co-authored-by: Werner, Stefan <stefan.werner@intel.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/115854
2023-12-13 21:38:19 +01:00
Xavier Hallade 9d5164d472 Build: Linux: patch ocloc to store binaries per-generation
When storing multiple binaries in a fatbinary, ocloc stores Intel
Graphics binaries for specific devices and these don't get found when
the device doesn't match fully.

Blender compiles one binary per generation rather than per device, to
gain space and compile time.

We introduce a patch at ocloc level to work around this behavior that
otherwise leads to binaries not being found and recompilation being
attempted.

Pull Request: https://projects.blender.org/blender/blender/pulls/115750
2023-12-12 18:24:27 +01:00
Jeroen Bakker c11004579e GPU: Remove the Word OpenGL from Build Scripts
The build scripts are still referring to gpu tests as being opengl.
Although they can also use Metal or Vulkan. This PR only replaces
the work `opengl` with `gpu` for build options.

Special note is that the windows argument `with_opengl_tests` is
also replaced with `with_gpu_tests` for consistency.

Pull Request: https://projects.blender.org/blender/blender/pulls/116030
2023-12-12 16:02:29 +01:00
Brecht Van Lommel 6cdb43195e Refactor: replace NanoVDB kernel side implementation by own code
The NanoVDB headers are not compatible with Metal due to missing address
space qualifiers. We currently have a big patch for NanoVDB header
files, which is difficult to update for OpenVDB 11. Instead extract a
few hundred lines of code from NanoVDB to do just what we need.

Pull Request: https://projects.blender.org/blender/blender/pulls/115992
2023-12-10 19:37:36 +01:00
Campbell Barton 0e64c959be Fix "project_source_info" use with clang
Simple string replacement failed when one compiler was the exact
prefix of another (`clang` & `clang++` in this case),
resolve by performing string replacement on the list items.
2023-12-10 17:35:18 +11:00
Campbell Barton ecd307041e CMake: suppress warning in flag removing macros
Without quotes, empty flags would warn that string(..) was called
without enough arguments.
2023-12-08 13:13:38 +11:00
Ray Molenkamp 7e916474db CMake/MSVC: Remove stale OIIO sse flag
We disabled SSE for OIIO headers in the days we still supported
32 bit builds, as it was giving build errors there. OIIO handles
this internally now so we no longer need to explicitly disable it,
also we stopped shipping 32 bit quite a while ago
2023-12-07 09:02:52 -07:00
Ray Molenkamp 44ac2e8a8d CMake: Allow asserts to be enabled for release builds.
Asserts historically only have been on in debug builds, however
running the tests in a debug configuration takes a while especially
if Cycles is enabled.

This adds WITH_ASSERT_RELEASE to enable asserts in release
configurations. It is enabled for "make developer" , and will also
be used for CI.

Co-authored-by: Brecht Van Lommel <brecht@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/115071
2023-12-06 23:49:42 +01:00
Campbell Barton 7aa3d967ba Build: update wayland protocols to 1.32
Adds cursor-shape-v1 which simplifies setting cursors.
2023-12-02 15:42:21 +11:00
Ray Molenkamp f644c936b6 shader_builder: Fix startup error on windows
needed shaderc_shared.dll to be available in the path
2023-11-27 08:35:37 -07:00
Iyad Ahmed 631f1ad133 Build: update rocky8 setup script to install the Jack audio library
Ref: !115256
2023-11-27 11:24:52 +11:00
Campbell Barton c7ead98d4e License headers: add SPDX copyright entries 2023-11-27 09:27:52 +11:00
Ray Molenkamp 23430f4db8 CMake: Disable vcpkg for msbuild based builds
vcpkg somewhat forcefully injects itself into the build system
causing some work stations to use the vcpkg headers/libs rather than
the headers from our lib folder,we added some mitigation against this
in 34b3a9583a but still the occasional
user with build issues showed up, this should nip that in the bud once
and for all.
2023-11-23 17:19:06 -07:00
Harley Acheson 6ae5e1ade8 Core: Allow Optional Use of Harfbuzz and FriBiDi
Harfbuzz and FriBiDi are included in our external libraries for all
platforms. This PR adds the glue to make them available as optional
build components (off by default).

Pull Request: https://projects.blender.org/blender/blender/pulls/114947
2023-11-23 23:35:03 +01:00
Bastien Montagne dfc00e8a18 `install_linux_packages`: Add libdeflate library.
Re. #113157
2023-11-22 15:32:39 +01:00
Bastien Montagne 90f83f71f2 `install_linux_packages`: update for 4.1 libraries, and some fixes.
Fixes:
  - Debian `libfreetype` package has been renamed from `libfreetype6` to
    `libfreetype`.
  - Increased MEX version of python-certifi to 2025, since most distros
    are shipping a '2023' version now.

Updates (following #113157):
  - NumPy: 1.24.3
  - Python: 3.11.6
  - Boost: 1.82.0
  - OpenColorIO: 2.3.0
  - OpenEXR & IMath: 3.2.1
  - OpenSubDiv: 3.6.0
  - OpenVDB: 11.0.0
  - MaterialX: 1.38.8
  - OpenImageDenoiser: 2.1.0
2023-11-22 15:24:40 +01:00
Brecht Van Lommel cb9b7eaa34 Build: fix macOS OpenImageDenoise 2.1 library not loading correctly
Version symlinks are not used on macOS due to notarization issues.
2023-11-16 19:21:30 +01:00
Brecht Van Lommel fa3c283780 Build: fix ffmpeg dependency build failing with new texinfo
There is an incompatibility in the latest texinfo that makes our current
ffmpeg version fail to build. Disable unnecessary ffmpeg docs building.
2023-11-15 17:40:05 +01:00
Brecht Van Lommel 25cfd64afa Build: remove outdated bf-committers email from bpy package
Mailing lists are no longer active.
2023-11-15 17:40:05 +01:00
Sebastian Parborg eaef914487 CMake: Allow building with system Vulkan and ShaderC
Previously the cmake code would try to run the LIBDIR specific "findX.cmake" files for both vulkan and shaderc.

However these would pick up system headers and libraries when LIBDIR were not present. This would lead to compilation errors as the system library configurations were not taken into account or queried.

This changes it so that if LIBDIR is not present, the proper pkgconfig files will be used instead.

Pull Request: https://projects.blender.org/blender/blender/pulls/114639
2023-11-10 18:10:41 +01:00
Campbell Barton 4e6bca79cd Cleanup: quiet unused variable warnings in CMake
OpenMP_LIBRARIES was used when it wasn't defined.
2023-11-10 09:15:49 +11:00
Brecht Van Lommel ffd701ab58 Build: auto update CMake config for shared library OpenImageDenoise 2023-11-09 18:23:52 +01:00
Campbell Barton 5ebaf8af59 Build: correct package name & code-comment for WESTON in lib/ 2023-11-09 14:57:09 +11:00
Werner, Stefan b414187efb Build: Update OpenImageDenoise to 2.1.0
Major new feature in v2 is GPU support. This is not enabled yet,
this commit only changes the library version without enabling new
functionality.

Pull Request: https://projects.blender.org/blender/blender/pulls/112143
2023-11-08 10:12:05 +01:00
Campbell Barton 9550fba6df Merge branch 'blender-v4.0-release' 2023-11-07 23:25:58 +11:00
Campbell Barton 5c6c71e6e8 Build: prevent OpenSSL using /etc/ssl on macOS & Linux
Using /etc/ssl only makes sense when the versions of SSL on the system
is compatible with the version Blender uses.

Failure to load the configuration for e.g. causes SSL to fail entirely
(causing downloading over HTTPS to fail).

Recently [0] de facto standard directory `/etc/ssl` was used however we
can't guarantee files in this path are compatible with Blender's SSL.

Use a known invalid path to resolve #114452.

Ref !114569

[0]: 60a8ae7830
2023-11-07 23:21:16 +11:00
Campbell Barton b771ce8ce4 Build: disable some unnecessary tools & options for WESTON 2023-11-07 14:14:54 +11:00
Campbell Barton 865944734f Build: add the WESTON compositor for Linux
WESTON is used when WITH_UI_TESTS is enabled.

Note that the system WESTON installation can be used by setting
WESTON_BIN to a path on the users system.

Ref !114164.
2023-11-07 12:57:45 +11:00
Campbell Barton 944905c394 CMake: mark X11 & openpgl variables as advanced 2023-11-04 16:41:26 +11:00
Campbell Barton 637fd13957 CMake: mark FFTW3_LIBRARY_{F,D} as advanced, update doc-string
Missed from [0].

[0]: 1015bed2fd
2023-11-04 16:41:24 +11:00
Campbell Barton 1a82019ba2 CMake: mark internal SSL deps variable as internal
_PYTHON_SSL_CERT_FILE_DEPS was showing up in CMake's options
when it's intended only as internal cache to track changes.
2023-11-04 16:41:22 +11:00
Campbell Barton 5d3f735fea CMake: remove "_" prefixed "LEVEL_ZERO_" variables
These look as if they were meant to be internal but they showed up in
configuration were the only way to configure level zero libraries.
2023-11-04 16:41:20 +11:00
Campbell Barton efef0bac5f CMake: remove redundant white-space as part of multi-line strings 2023-11-04 16:41:19 +11:00
Campbell Barton 2b508f7ae3 Cleanup: cmake indentation 2023-11-04 16:41:18 +11:00
Xavier Hallade 1161455084 Build: upgrade Intel Graphics Compiler on Linux
In order to speedup compilation, we upgrade IGC to 1.0.14828.26 along
with ocloc and the associated dependencies.
We also bump min-driver version accordingly to 26918.

Ref !114341
2023-11-02 22:27:38 +11:00
Campbell Barton 67b078aa6f Merge branch 'blender-v4.0-release' 2023-10-31 10:45:28 +11:00
Campbell Barton b27ff093ca Build: resolve error configuring FFMPEG on Linux
Configure failed to find vorbis & vorbisenc on Linux with the errors:

ERROR: vorbis not found using pkg-config
ERROR: vorbisenc not found using pkg-config

the issue was caused by configures test program failing to link the test
code against the static library because functions in libm weren't found.

Resolve by adding `$libm_extralibs` to libvorbis.

Note that it's strange this issue didn't come up before,
since it occurs on a clean build it seems necessary.
2023-10-31 10:38:49 +11:00
Brecht Van Lommel 39107b3133 Revert changes from main commits that were merged into blender-v4.0-release
The last good commit was 8474716abb.

After this commits from main were pushed to blender-v4.0-release. These are
being reverted.

Commits a4880576dc from to b26f176d1a that happend afterwards were meant for
4.0, and their contents is preserved.
2023-10-30 21:40:35 +01:00
Campbell Barton 14e92decd0 Merge branch 'blender-v4.0-release' 2023-10-25 15:43:24 +11:00
Campbell Barton 60a8ae7830 Build: use /etc/ssl for OPENSSLDIR on Linux & macOS
Define the OPENSSLDIR so the local build paths from the build systems
aren't being searched on users systems.
2023-10-25 11:05:34 +11:00
Brecht Van Lommel 68e06704a6 Merge branch 'blender-v4.0-release' into main 2023-10-23 19:09:12 +02:00
Brecht Van Lommel 3a483004c8 Fix SSL cert file path not working on second cmake configure
Always create the non-cached relatve from the cached absolute path.

Ref #102300
2023-10-23 19:06:47 +02:00
Campbell Barton 6b0769c448 Merge branch 'blender-v4.0-release' 2023-10-17 20:01:00 +11:00
Campbell Barton e21dfb4c42 Correct comment in 5ac392ca40 2023-10-17 19:59:58 +11:00
Campbell Barton 5ac392ca40 Fix #102300: SSL/HTTPS Request Unable to Get Local Issuer Certificate
Resolve an error with SSL using a hard coded path to certificates on
Linux causing HTTPS access to fail.
request.urlopen(..) couldn't access any HTTPS URL's.
2023-10-17 19:58:34 +11:00
Brecht Van Lommel 4fe903bef7 Merge branch 'blender-v4.0-release' into main 2023-10-16 20:10:09 +02:00
Brecht Van Lommel 0c958129a3 Fix deps build issues with Ogg/Vorbis on new Xcode, switch to CMake
These were already building with CMake on Windows, do the same for
Linux on macOS.
2023-10-16 20:09:41 +02:00
Brecht Van Lommel 4a376326c9 Fix OpenImageIO wrong dependency builder hash after repository moved
And update to new URL.
2023-10-16 20:09:41 +02:00
Xavier Hallade ef80392721 Cycles: oneAPI: update windows ocloc to 101.4723
The first public Windows driver version with a higher number is
101.4824, so we bump the min-required driver version on Windows to this
one to ensure compatibility.
2023-10-11 14:47:48 +02:00
Campbell Barton b0a6c6c1de Merge branch 'blender-v4.0-release' 2023-10-11 10:44:23 +11:00
Campbell Barton 58442a420e Cleanup: comment for release configuration, quote-style & remove parens 2023-10-11 10:41:16 +11:00
Brecht Van Lommel 03b2523df8 Merge branch 'blender-v4.0-release' into main 2023-10-09 16:14:39 +02:00
Brecht Van Lommel c3c631ebcf Build: make Linux cmake release config consistent with buildbot
Enable dynamic sound library loading so that "make release" produces
binaries that are as portable as buildbot builds.

Remove unnecessary linker flags that are already set by default, and
don't specifiy explicit lib directoy since it is also found by default.

Pull Request: https://projects.blender.org/blender/blender/pulls/113360
2023-10-09 14:41:34 +02:00
Campbell Barton 0c91466785 GHOST/Wayland: remove WITH_GHOST_WAYLAND_DBUS
This was only used for accessing cursor themes which only worked
with gnome and wasn't used in official releases.
Use the default theme or the theme defined by XCURSOR_THEME.

Eventually wp_cursor_shape_manager_v1 can be supported which avoids
having to access the theme.
2023-10-07 21:31:15 +11:00
Campbell Barton f482e5979d CMake: set_and_warn_incompatible now warns if arguments are undefined
Previously this caused an error which can happen on other platforms that
don't define the features being checked.
2023-10-07 21:22:13 +11:00
Campbell Barton 1dafc2786f CMake: fix building on macOS 2023-10-07 20:21:52 +11:00
Campbell Barton 149d80946e Cleanup: CMake formatting 2023-10-07 19:46:38 +11:00
Campbell Barton 833eddafa3 CMake: add set_and_warn_incompatible macro, use for HEADLESS & GHOST_SDL
When WITH_GHOST_SDL or WITH_HEADLESS were used, the message didn't make
much sense, especially since the features warned about weren't
necessarily enabled or even supported by the platform.

Replace with a `set_and_warn_incompatible` macro which only reports
configuration changes based on incompatible features.
2023-10-07 19:11:51 +11:00
Campbell Barton b434d40dbf CMake: quiet noisy messages on every run
Printing that a library is found every time CMake runs isn't helpful.
Restrict these messages for the first execution so messages are limited
to information developers may need to know such as features being
disabled because of incompatible configurations.
2023-10-07 18:20:30 +11:00
Jeroen Bakker 1aca58cf16 Vulkan: Enable as Experimental Option
This PR enables vulkan backend as experimental option.
It will only be available in alpha builds on Linux and Windows.

This option is highly experimental and enabled to get some insight
on supported platforms. Don't expect a fully working Blender
yet. Also don't expect it to have usable performance.

**What is known to not work?**

* OCIO textures are not supported on Intel and AMD GPUs. sRGB/Standard is supported
  on those platforms.
* AMD Polaris based GPUs on Linux will generate a crash when drawing the 3d cursor as it
  doesn't support the needed vertex format. Comment out `DRW_draw_cursor` in `DRW_draw_region_info`.
* The colors in the node editor and sequencer are of as sRGB viewports aren't detected correctly.
* The image / UV editor isn't working as many texture formats haven't been tested yet. Some
  tweaks are also needed to do correct depth testing.
* 3D Viewport is known to be flickering. Sometimes workbench doesn't display anything.
* 3D Viewport wireframe will crash as it uses a framebuffer with gaps between color attachments,
  which isn't supported yet. (#113141)
* Rotate the view widget is partially drawn due to incompatible depth clipping.
* GPU Selection isn't working. It is expected to be solved when Overlay-Next will become the
  default engine. For now disable GPU depth picking in the preferences.
* Cycles/EEVEE are known to not work with Vulkan yet. Cycles requires Vulkan Pixel Buffer.
   Cuda <-> Vulkan interop might require a different approach than OpenGL as Vulkan doesn't allow
  importing memory from a Cuda context. EEVEE uses features that aren't available yet in the backend
* Workbench is working, except Workbench shadows.
* EEVEE-Next basics are working. Shadows, lights are known to be not working. Materials/Shading
  works in simple scenes. Changes are expected in EEVEE-Next that will break Vulkan compatibility
  in the near future.
* Systems with multiple GPUs is not expected to work.
* Wayland support is in development and requires some iterations. You can start Blender, but
  the protocols are not aligned yet.
* OpenXR hasn't been modified and is expected to fail.
* The backend is very strict when mis-using the GPU module. In debug builds it may crash
  on asserts.
* Older drivers/GPUs might not have all the features that we require. The workarounds
  for the missing features still need to be implemented.

**A word about performance**

In the project planning we focus first on stability and platform support. The performance of Vulkan is
around 20% of what we want to achieve. The reason is that each command sent to the
GPU is done one at a time. The implementation even waits until we have feedback that the GPU
is idle again.

Geometry is currently stored in System RAM. The GPU will read and cache the data when
accessing geometry. This slows down when using objects with much geometry.
Some performance features like MDI (Multi-Draw-Indirect) hasn't been implemented and
falls back to Single Draw Indirect.

**Why enable it is an experimental option?**

* Ensures that new features are being tested with Vulkan
* Ensure that building with Vulkan is possible on supported platforms
* Get feedback from developers if Vulkan can run on their system or that
  there are special cases that we are not aware of. Main development
  environment has been Linux/X11 with occasionally testing using Windows.
* Validate Add-ons that use the `gpu` module.
* Possible to enable GLSL validation on the buildbot. (Needs more work).
* Does it compile on all machines or does it require more changes to cmake
  config. We expect it to be able to compile without installing the Vulkan SDK.
  The Vulkan SDK is a very powerful tool, but only when actually doing GPU
  development. Otherwise it is an overhead which slows down other
  activities.

**How can the backend be enabled?**

Currently the Vulkan backend can be enabled per Blender session by starting
using the command line argument `--gpu-backend vulkan`. In the future, when
the backend is more mature, we will add a user preference to switch between
OpenGL and Vulkan.

Pull Request: https://projects.blender.org/blender/blender/pulls/113057
2023-10-06 15:24:21 +02:00
Campbell Barton c5d01df691 Merge branch 'blender-v4.0-release' 2023-10-06 21:48:34 +11:00
Campbell Barton 8974ca8f24 Tools: set the number of jobs to the CPU count for various utilities
Previously this was the double the CPU count because:

- Modern CPU's from AMD & Intel support SMT/hyper-threading which
  present twice as many cores, doubling again has little to no benefit.
- Using 2x or 4x the number of physical cores number can use a lot of
  memory on systems with many cores which are becoming more common.
2023-10-06 21:47:03 +11:00
Campbell Barton 273af6855a CMake: cache the HAVE_BROTLI result
Avoid detecting HAVE_BROTLI every time CMake runs,
only re-detect if the freetype includes change.
2023-10-06 17:58:26 +11:00
Campbell Barton a03b1e5df5 Merge branch 'blender-v4.0-release' 2023-10-05 10:51:48 +11:00
Campbell Barton 2f71d9f807 Build: quiet GCC warning for extern/fmtlib 2023-10-05 10:50:58 +11:00
Ray Molenkamp 384d9c9a07 Merge remote-tracking branch 'origin/blender-v4.0-release' 2023-09-27 18:03:38 -06:00
Ray Molenkamp 751c9ef620 CMake/MSVC: Fix build error for RelWithDebInfo configuration
CMake decided to link the Debug libs for MaterialX because no specific
RelWithDebInfo configuration was provided, strange default imho but
not difficult to fix.
2023-09-27 18:03:16 -06:00
Hans Goudey afaa30b1eb Merge branch 'blender-v4.0-release' 2023-09-27 18:22:16 -04:00
Hans Goudey 1badb464b0 Fix: Compile error from unused module requested in CMake
The `clangSupport` module isn't provided in the precompiled
libraries anymore, and Blender compiles without it.

Pull Request: https://projects.blender.org/blender/blender/pulls/112981
2023-09-27 23:58:03 +02:00
Thomas Dinges ab26ddc455 Revert "Release cycle: Bcon3 for Blender 4.0"
This reverts commit 8c25952886.
2023-09-27 12:53:52 +02:00
Thomas Dinges 8c25952886 Release cycle: Bcon3 for Blender 4.0 2023-09-27 12:52:04 +02:00
Brecht Van Lommel 2ed8df333b Fix Hydra not being disabled when USD library not found on Linux 2023-09-26 18:53:05 +02:00
Ray Molenkamp 974bb38c51 CMake: Update platform_win32.cmake with webp 1.3 support
WebP 1.3 changed the library filenames to include a lib prefix and
added an additional library.
2023-09-22 08:59:03 -06:00
Ray Molenkamp 3735a4d104 deps_builder: Fix missing Webp support in OIIO build on windows
webp 1.3 changed the filenames on windows to include a `lib` prefix
(ie libwebp.lib rather than webp.lib) now this is a common thing
on linux and cmake has a `CMAKE_FIND_LIBRARY_PREFIXES` variable that
has a list of prefixes to look for during a `find_library` call.

`CMAKE_FIND_LIBRARY_PREFIXES` gets set during the call to the
`project` method in the main CMakeLists of a project. Now for windows
`lib` is *not* a common prefix by CMake, and it doesn't add "lib" to
CMAKE_FIND_LIBRARY_PREFIXES during that call.

so find library doesn't look for it, the libs are not found and an
unhappy time is had by all. Now the most obvious solution would be to
pass `-DCMAKE_FIND_LIBRARY_PREFIXES=lib` to CMake to sidestep this
however, the `project` call will set the variable overwriting
anything you passed through the CLI.

So the fix here is to have `find_library` counter-intuitively look
for both `libwebp` and `webp`
2023-09-22 08:47:23 -06:00
Ray Molenkamp af9523d7c2 deps_builder: OIIO validate deps at configure time
The last webp update changed the filenames of the webp libraries
on windows causing oiio not to find them and oiio silently build
without webp support, which only came to light after all of
blender was build and a test failed.

This change makes the OIIO validate and error out if certain
dependencies are not found at configure time so these mistakes
are caught early.
2023-09-22 08:32:26 -06:00
Brecht Van Lommel 3d15a07bde Revert "install_linux_packages: Raise LLVM default version to 15.0.7."
This reverts commit 607adbca47.

The LLVM upgrade is being postponed to 4.1.

Ref #109244
2023-09-21 18:46:30 +02:00
Brecht Van Lommel f0840cee2a Build: update 4.0 libraries to address CVEs and bugs
And ignore a few CVEs that do not affect Blender.

openimageio 2.4.15
openssl 3.1.2
python 3.10.13
sndfile 1.2.2
webp 1.3.2

Ref #109244

Pull Request: https://projects.blender.org/blender/blender/pulls/112529
2023-09-21 17:02:46 +02:00
Brecht Van Lommel d387ef224f macOS: upgrade to Xcode 15
For Blender 4.0 only, 3.3 and 3.6 keep using the older Xcode version.

The new linker in Xcode 15 gives many warnings due to duplicated
libraries, generated by CMake to resolve circular dependencies. For now
use the old linker to silence these warnings.

Remove legacy flags for libc++, this is the default for a long time and
generates warnings with the new linker.

Reason for upgrade is to take advantage of MetalRT curve support.

Pull Request: https://projects.blender.org/blender/blender/pulls/110243
2023-09-20 16:25:14 +02:00
Ray Molenkamp bf9b699089 Fix: make.bat showhash
This broke when we moved the submodules around and no one ever noticed

This will now list:
-The current branch
-The current branch hash
-Addons branch
-Addons branch hash
-Libs url
-Libs revision
-Libs last-changed-date

So it'll be a little easier to diagnose what exactly the state of
things are when someone asks for help building.
2023-09-16 10:32:30 -06:00
Ray Molenkamp cf973a2d16 deps_builder: Fix zlib URI
zlib's uri is a bit unstable as when they release a new version they
move the last release "elsewhere"

This change switches the upstream URI over to github, which should be
a bit more reliable.
2023-09-12 10:23:03 -06:00
bsavery 281fbf72f0 Cycles: support building with Windows ROCm 5.5 SDK
The official SDK was released, add correct paths for that version. The
old paths can be removed once the buildbot uses this SDK.

The SDK installer sets a HIP_PATH environment variable. This is used to
automatically detect the location when HIP_ROOT_DIR is not manually
specified.

Co-authored-by: Brecht Van Lommel <brecht@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/110519
2023-09-07 17:22:18 +02:00
Brecht Van Lommel 526f935981 Fix broken OPTIX_ROOT_DIR environment variable for setting up build
Changes in 42713bf made it ignore the environment variable if there is a
defined but empty CMake variable. Also make similar changes for other
GPU compute APIs, to guard against future problems like this.

Pull Request: https://projects.blender.org/blender/blender/pulls/111928
2023-09-04 17:28:00 +02:00
Brecht Van Lommel 19da2fba83 Fix macOS Arm build of OSL library dependency
This patch is already in upstream, so this is temporary until we upgrade
to the latest OSL version.

Ref #110708
2023-09-04 15:08:02 +02:00
Xavier Hallade 400f7c22bc Cycles: update ocloc to 101.4369 on Windows
As discussed on #108314, oidn 2.0 needs an updated version of ocloc.
No need to bump the min required driver version as it's already
high enough on Windows (101.4644).

Pull Request: https://projects.blender.org/blender/blender/pulls/111729
2023-09-01 15:21:54 +02:00
Marcos Perez 1015bed2fd VSE: Sound equalizer modifier
The sound equalizer is using the Audaspace FFT Convolver.
The blender part creates an array of descriptions of power per "band"
and orders the creation of Equalizer (ISound) in the Audaspace.

Modifier can be created on sound strips. It lets you define
amplification or attenuation over frequency range from 30Hz to 20 kHz.
The power is limited to -30 db - 30 db. This is done using curve
mapping widget.

Co-authored-by: menda <alguien@aqui.es>
Co-authored-by: Richard Antalik <richardantalik@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/105613
2023-08-30 22:36:36 +02:00
Brecht Van Lommel 62c898f2e0 Fix (DY)LD_LIBRARY_PATH ignored for oslc and shader builder in build
Accidentally used CMake instead of environment variable.

Pull Request: https://projects.blender.org/blender/blender/pulls/111234
2023-08-30 17:00:02 +02:00
Campbell Barton 46edf61180 CMake: adjust the error message when a non-default version wasn't found
The error message was written assuming the default version was set,
making the error confusing.
Adjust the error message when the non-default version is missing.
2023-08-30 15:20:50 +10:00
Campbell Barton 3de8900ed6 Cleanup: spelling in comments 2023-08-25 09:40:42 +10:00
Bastien Montagne 607adbca47 install_linux_packages: Raise LLVM default version to 15.0.7.
Following specs from #109244 for Blender 4.0.
2023-08-24 22:55:56 +02:00
Campbell Barton b8054b0cb2 Cleanup: white-space for UNIX platform error messages 2023-08-24 10:37:52 +10:00
Campbell Barton 20b4a77872 datatoc: exclude the initial C-style comment from GLSL/MSL/Cuda files
Add optional argument `STRIP_LEADING_C_COMMENTS` to CMake macros:
data_to_c_simple & data_to_c.

Strip leading C-style comments that don't bloat binary size.
Comments are replaced with blank lines so line numbers in error messages
match. Reduces Blender's binary size by ~70kb.
2023-08-19 17:57:12 +10:00
Ray Molenkamp e7c94b35b8 Fix: Missing PDB on windows
Missed one cmake check in 0df3aedfa8
2023-08-19 00:09:19 -06:00
Ray Molenkamp e2af12d368 Cleanup: Update copyright to the new format
Had put my name here since the choice was between the foundation
and me personally, with the blender authors file now being in
place this can be cleaned up.
2023-08-18 11:58:37 -06:00
Ray Molenkamp d5e50460e7 CMake/MSVC: Use /debug:fastlink for debug builds
This changes the default linker options for debug builds to use
fastlinking, this causes the PDB only to be usable on the machine
it is being created on, however since debug builds cannot be
distributed to end users (wont run due to missing debug CRT on
their system) this isn't a problem.

This halves the time required for an incremental link on my system
from 7->3.5 seconds
2023-08-18 10:47:47 -06:00