summaryrefslogtreecommitdiffstats
path: root/meson.build
Commit message (Collapse)AuthorAgeFilesLines
* meson: fix EGL/X11 build without GLXChia-I Wu2019-01-081-1/+1
| | | | | | | dep_xcb and others were not set under this configuration. Signed-off-by: Chia-I Wu <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: Error out if building nouveau and using LLVM without rttiDylan Baker2019-01-021-0/+3
| | | | | | | | | | | Nouveau requires rtti. Often LLVM is configured without rtti, and code with and without cannot be linked safely. Lets just error out if nouveau is requested and llvm is built without rtti. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109202 Fixes: c5a97d658ec19cc02719d7f86c1b0715e3d9ffc4 ("meson: fix builds against LLVM built without rtti") Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* meson: Override C++ standard to gnu++11 when building with altivec on ppc64Dylan Baker2018-12-281-0/+9
| | | | | | | | | | Otherwise there will be symbol collisions for the vector name. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108943 Distro Bug: https://bugs.gentoo.org/673622 Fixes: 42ea0631f108d82554339530d6c88aa1b448af1e ("meson: build clover") Acked-by: Matt Turner <[email protected]>
* meson: don't require glx/egl/gbm with gallium driversEmil Velikov2018-12-131-3/+3
| | | | | | | | | The gallium drivers do not require a DRI loader. Drop the artificial and unnecessary restriction. Fixes: af9d276134d ("meson: build libmesa_gallium") Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: Fix libsensors detection.Vinson Lee2018-12-181-1/+1
| | | | | | Fixes: 5e71efef44b9 ("meson: Add lmsensors support") Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: Fix typo.Vinson Lee2018-12-181-1/+1
| | | | | | Fixes: 6b4c7047d571 ("meson: build gallium nine state_tracker") Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* meson: add etnaviv to the tools optionChristian Gmeiner2018-12-181-1/+1
| | | | | Signed-off-by: Christian Gmeiner <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: Add toggle for glx-directDylan Baker2018-12-181-3/+1
| | | | | | | | GNU Hurd needs to turn off glx-direct, rather than special case it, we'll just add a toggle. CC: 18.3 <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* meson: Add support for gnu hurdDylan Baker2018-12-181-4/+2
| | | | | CC: 18.3 <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* meson: remove duplicate definitionDylan Baker2018-12-181-2/+0
| | | | Reviewed-by: Eric Engestrom <[email protected]>
* meson: Fix ppc64 little endian detectionDylan Baker2018-12-181-2/+7
| | | | | | | | | | | Old versions of meson returned ppc64le as the cpu_family for little endian power8 cpus, versions >=0.48 don't do this, so the check wouldn't work in that case. This generalizes the check to work for both old and new versions of meson. Fixes: 34bbb24ce7702658cdc4e9d34a650e169716c39e ("meson: Add support for ppc assembly/optimizations") Reviewed-by: Eric Engestrom <[email protected]>
* glx: mandate xf86vidmode only for "drm" dri platformsEmil Velikov2018-12-131-2/+2
| | | | | | | | | | | | | | | Currently we have the three dri "platforms" - drm, apple and windows. Since xf86vidmode is a thing only for the drm one, adjust the preprocessor guards and correctly check for the dependency. v2: terminate the GLX_USE_WINDOWSGL hunk Cc: Jon TURNEY <[email protected]> Fixes: 5bc509363b6 ("glx: make xf86vidmode mandatory for direct rendering") Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> Acked-by: Eric Engestrom <[email protected]>
* meson: link LLVM 'native' component when LLVM is availableNicolai Hähnle2018-12-071-1/+1
| | | | | | | Linking against LLVM built with BUILD_SHARED_LIBS fails otherwise, as the component is required for the draw module. Reviewed-by: Dylan Baker <[email protected]>
* amd: remove support for LLVM 6.0Samuel Pitoiset2018-12-061-1/+1
| | | | | | | User are encouraged to switch to LLVM 7.0 released in September 2018. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* meson: skip asm check when asm is disabledEric Engestrom2018-12-041-1/+1
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* build: stop defining unused VERSIONEric Engestrom2018-11-261-2/+1
| | | | | | | | | | | | | Scons and autotools don't define it, and as of last commit nothing uses it. `VERSION` is also a generic enough name that something somewhere will eventually clash, and we don't want to repeat the LLVM `DEBUG` fiasco. Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* glx: make xf86vidmode mandatory for direct renderingEmil Velikov2018-11-201-4/+2
| | | | | | | | | | | | | | | | | | | Currently we detect the module and if missing, the glXGetMsc* API is effectively a stub, always returning false. This is what effectively has been happening with our meson build :-( Thus users have no chance of using it - they cannot even distinguish if the failure is due to a misconfigured build. There's no reason for keeping xf86vidmode optional - it has been available in all distributions for years. Cc: [email protected] Signed-off-by: Emil Velikov <[email protected]> Acked-by: Dylan Baker <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Fixes: a47c525f3281a2753180e "meson: build glx"
* meson: fix wayland-less buildsEric Engestrom2018-11-131-7/+0
| | | | | | | | | | | | | | | | Those empty variables in the !wayland case are useless and running that meson.build with them breaks the build: [287/850] Generating wayland-drm-client-protocol.h with a custom command. FAILED: src/egl/wayland/wayland-drm/wayland-drm-client-protocol.h client-header ../src/egl/wayland/wayland-drm/wayland-drm.xml src/egl/wayland/wayland-drm/wayland-drm-client-protocol.h /bin/sh: client-header: command not found ninja: build stopped: subcommand failed. Fixes: d1992255bb29054fa5176 "meson: Add build Intel "anv" vulkan driver" Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: fix libatomic testsDylan Baker2018-11-121-1/+2
| | | | | | | | | | | There are two problems: 1) the extra underscore in MISSING_64BIT_ATOMICS 2) we should link with libatomic if the previous test decided we needed it Fixes: d1992255bb29054fa51763376d125183a9f602f3 ("meson: Add build Intel "anv" vulkan driver") Reviewed-and-Tested-by: Matt Turner <[email protected]>
* meson: Don't set -WallDylan Baker2018-11-121-2/+2
| | | | | | | | | meson does this for you with its warn levels, so we don't need to set it ourselves. Fixes: d1992255bb29054fa51763376d125183a9f602f3 ("meson: Add build Intel "anv" vulkan driver") Reviewed-by: Eric Engestrom <[email protected]>
* freedreno: import libdrm_freedreno + redesign submitRob Clark2018-10-261-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the pursuit of lowering driver overhead, it became clear that some amount of redesign of how libdrm_freedreno constructs the submit ioctl would be needed. In particular, as the gallium driver is starting to make heavier use of CP_SET_DRAW_STATE state groups/objects, the over- head of tracking cmd buffers and relocs becomes too much. And for "streaming" state, which isn't ever reused (like uniform uploads) the overhead of allocating/freeing ringbuffer[1] objects is too high. This redesign makes two main changes: 1) Introduces a fd_submit object for tracking bos and cmds table for the submit ioctl, making ringbuffer objects more light- weight. This was previously done in the ringbuffer. But we have many ringbuffer instances involved in a submit (gmem + draw + potentially 1000's of state-group rbs), and only need a single bos and cmds table. (Reloc table is still per-rb) The submit is also a convenient place for a slab allocator for ringbuffer objects. Other options would have required locking because, while we can guarantee allocations will only happen on a single thread, free's could happen either on the application thread or the flush_queue thread. With the slab allocator in the submit object, any frees that happen on the flush_queue thread happen after we know that the application thread is done with the submit. 2) Introduce a new "softpin" msm_ringbuffer_sp implementation that does not use relocs and only has cmds table entries for IB1 (ie. the cmdstream buffers that kernel needs to CP_INDIRECT_BUFFER to from the RB). To do this properly will require some updates on the kernel side, so whether you get the softpin or legacy submit/ringbuffer implementation at runtime depends on your kernel version. To make all these changes in libdrm would basically require adding a libdrm_freedreno2, so this is a good point to just pull the libdrm code into mesa. Plus it allows for using mesa's hashtable, slab allocator, etc. And it lets us have asserts enabled for debug mesa buids but omitted for release builds. And it makes life easier if further API changes become necessary. At this point I haven't tried to pull in the kgsl backend. Although I left the level of vfunc indirection which would make it possible to have other backends. (And this was convenient to keep to allow for the "softpin" ringbuffer to coexist.) NOTE: if bisecting a build error takes you here, try a clean build. There are a bunch of ways things can go wrong if you still have libdrm_freedreno cflags. [1] "ringbuffer" is probably a bad name, the only level of cmdstream buffer that is actually a ring is RB managed by kernel. User- space cmdstream is all IB1/IB2 and state-groups. Reviewed-by: Kristian H. Kristensen <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Signed-off-by: Rob Clark <[email protected]>
* meson: update required amdgpu version to 2.4.95Boyuan Zhang2018-10-231-1/+1
| | | | | | | VCN jpeg requires new hw ip Signed-off-by: Boyuan Zhang <[email protected]> Reviewed-by: Leo Liu <[email protected]>
* meson: don't require libelf for r600 without LLVMDylan Baker2018-10-221-8/+10
| | | | | | | | | | | r600 doesn't have a hard requirement on LLVM, and therefore doesn't have a hard requirement on libelf. Currently the logic doesn't allow that however. Distro-bug: https://bugs.gentoo.org/669058 Fixes: 5060c51b6f4dfb0d5358bde6523285163d3faaad ("meson: build r600 driver") Reviewed-by: Matt Turner <[email protected]>
* meson: Add -Werror=return-type when supported.Kenneth Graunke2018-10-191-2/+4
| | | | | | | | | | | | | | | | | | This warning detects non-void functions with a missing return statement, return statements with a value in void functions, and functions with an bogus return type that ends up defaulting to int. It's already enabled by default with -Wall. Generally, these are fairly serious bugs in the code, which developers would like to notice and fix immediately. This patch promotes it from a warning to an error, to help developers catch such mistakes early. I would not expect this warning to change much based on the compiler version, so hopefully it won't become a problem for packagers/builders. See the GCC documentation or 'man gcc' for more details: https://gcc.gnu.org/onlinedocs/gcc-7.3.0/gcc/Warning-Options.html#index-Wreturn-type Reviewed-by: Eric Engestrom <[email protected]>
* freedreno/a6xx: add infrastructure for CP_DRAW_STATERob Clark2018-10-171-1/+1
| | | | | | | Add helper to add state-groups to emit, and code to emit CP_DRAW_STATE packet if we have any state-groups. Signed-off-by: Rob Clark <[email protected]>
* meson: Don't allow building EGL on Windows or MacOSDylan Baker2018-10-101-1/+6
| | | | | | | | | | | | | | Currently mesa only supports EGL on Unix like systems, cygwin, and haiku. Meson should actually enforce this. This fixes the default build on MacOS. v2: - invert the condition, mark darwin and windows as not supported instead of trying to mark what is supported. v3: - add missing ) v3: - Update comment to reflect condition change in v2 CC: 18.2 <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* meson: remove invalid "opencl" llvm componentEmil Velikov2018-10-031-1/+1
| | | | | | | | | Seeming copy/paste mistake from configure.ac which uses $2 for the component and $3 for the fancy name printing. Cc: Dylan Baker <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson+autotools: get rid of spammy GCC warning -Wformat-truncationEric Engestrom2018-09-251-2/+2
| | | | | | | | | | | | | | | That warning fires every time a string function takes an argument that could possibly be longer than its max output, which triggers all over the place, especially when working with file paths ("what if every file path is MAX_PATH long?" is what GCC is saying, which is really annoying when we *know* that "/dev/dri/cardN" is not gonna be 4096 char long and it's safe to store it in a 32-char array). Anyway, we either add a ton of dead code all over the place to make GCC happy, or we get rid of its spam. I chose the latter. Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* meson: make it trivial to add other -Wno-foo CFLAGSEric Engestrom2018-09-251-3/+6
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: de-duplicate LLVM checkDylan Baker2018-09-241-15/+8
| | | | | | | By adding `_llvm == 'true'` to the required argument we can check the 'auto' and 'true' case in one path. Reviewed-by: Eric Engestrom <[email protected]>
* meson: Don't force libva to required from autoDylan Baker2018-09-211-2/+0
| | | | | | | | | We already correctly handle va being auto, but we force it to being true, which is bad. Fixes 94cf3970925ec87d913a1549a42cdb03713fc4bb ("meson: Fix auto option for va") Reviewed-by: Eric Engestrom <[email protected]>
* meson: add option to statically link llvmChristoph Haag2018-09-201-0/+4
| | | | Reviewed-by: Dylan Baker <[email protected]>
* move pthread_setaffinity_np check to the build systemDylan Baker2018-09-171-0/+7
| | | | | | | | | | | | | | | | | Rather than trying to encode all of the rules in a header, lets just put them in the build system where they belong. This fixes the build on FreeBSD, which does have pthraed_setaffinity_np, but it's in a pthread_np.h, not behind _GNU_SOURCE. FreeBSD also implements cpu_set slightly differently, so additional changes would be required to get it working right there anyway. v2: - fix #define in autotools Fixes: 9f1bbbdbbd77d346c74c7abbb31f399151a85713 ("util: try to fix the Android and MacOS build") Cc: Emil Velikov <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* meson: disable asserts by default on release buildsEric Engestrom2018-09-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | By the time Mesa 18.3 comes out (probably December '18), Meson 0.45 will be 9 months old (March '18), so I think this is reasonable. (btw, the currently-required Meson 0.44.1 was released less than 12 days before 0.45, so we're really not bumping by much.) Currently, the Meson versions in the major distributions are: Arch: ships 0.47.2 CentOS: 7 ships 0.47.1 Debian: stable ships 0.37.1, so it hasn't been usable in a long time. everything more recent ships 0.47.2 Fedora: 28 ships 0.45.1 FreeBSD: ships 0.46.1 (ports) Gentoo: ships 0.46.1 OpenSUSE: 15 ships 0.46 Ubuntu: 18.04 ships 0.45.1 Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: drop unnecessary llvm version hacksEric Engestrom2018-09-061-9/+0
| | | | | | | | | The current minimum meson version supported is 0.44.1, so we have met both the 0.43 and 0.44 requirement to not need these hacks anymore :) Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: Print a message about why a libdrm version was selectedDylan Baker2018-09-051-0/+5
| | | | | | | | | | | | | | | | | We require a single version of libdrm for all of our libdrm dependencies (core and driver), but the way this is structured can make the error message less than helpful, as one driver might be the one setting the libdrm requirement, while another might be the one that generates the version failure. This adds a simple message to the output announcing which libdrm module set the version, which might be more helpful. v2: - Use message suggested by Eric Engstrom Fixes: c445b1d56f47922206de55e557444aadb62e11f6 ("meson: Use the same version for all libdrm checks") Reviewed-by: Eric Engestrom <[email protected]>
* meson: Don't enable any vulkan drivers on arm, aarch64Guido Günther2018-08-271-0/+2
| | | | | | | There's no Vulkan support for arm atm. Signed-off-by: Guido Günther <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: Be a bit more helpful when arch or OS is unknownGuido Günther2018-08-271-7/+14
| | | | | | | V2: Add one missing @0@ Signed-off-by: Guido Günther <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* swr: bump minimum supported LLVM version to 6.0Juan A. Suarez Romero2018-08-201-1/+1
| | | | | | | | | | | | | | | | | RADV now requires LLVM 6.0 or greater, and thus we can't build dist tarball because swr requires LLVM 5.0. Let's bump required LLVM to 6.0 in swr too. v2: bump also in meson.build (Eric) Fixes: fd1121e839 ("amd: remove support for LLVM 5.0") Cc: Tim Rowley <[email protected]> Cc: Emil Velikov <[email protected]> Cc: Dylan Baker <[email protected]> Cc: Eric Engestrom <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Bruce Cherniak <[email protected]>
* freedreno: Add a6xx backendKristian H. Kristensen2018-08-161-1/+1
| | | | | | | | | | This adds a freedreno backend for the a6xx generation GPUs, which at the time of this commit is about 98% GLES2 conformant. Much remains to be done - both performance work and feature work towards more recent GLES versions, but this is a good start. Signed-off-by: Kristian H. Kristensen <[email protected]> Signed-off-by: Rob Clark <[email protected]>
* meson: use python3 module to find python3Dylan Baker2018-08-161-1/+1
| | | | | | | | This handy helper is nice for OSes that are not linux or BSD like (mac and windows) as it knows how to find python3 in odd places. Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>
* meson: Ensure that mako is >= 0.8.0Dylan Baker2018-08-161-2/+8
| | | | | | | | | It's what autotools has required for a long time. v3: - Use distutils.version.StrictVersion instead of comparing strings Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>
* meson: Build with Python 3Mathieu Bridon2018-08-101-3/+3
| | | | | | | | | | | | Now that all the build scripts are compatible with both Python 2 and 3, we can flip the switch and tell Meson to use the latter. Since Meson already depends on Python 3 anyway, this means we don't need two different Python stacks to build Mesa. Signed-off-by: Mathieu Bridon <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* meson: recommend building the surfaceless platformEmil Velikov2018-08-081-1/+1
| | | | | | | | | | It has no special requirements, size and build-time is effectively zero. v2: Rebase Signed-off-by: Emil Velikov <[email protected]> Acked-by: Dylan Baker <[email protected]> Reviewed-by: Adam Jackson <[email protected]>
* meson: stop exporting internal wayland detailsEmil Velikov2018-08-071-0/+6
| | | | | | | | | | | | | | | | | With version v1.15 the "code" option was deprecated in favour of "private-code" or "public-code". Before the interface symbol generated was exported (which is a bad idea since it's internal implementation detail) and others may misuse it. That was the case with libva approx. 1 year ago. Since then libva was fixed, so we can finally hide it by using "private-code" Inspired by similar xserver patch by Adam Jackson. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* meson: use dependency()+find_program() for wayland-scannerEmil Velikov2018-08-071-1/+2
| | | | | | | | | Helps when the native wayland-scanner is located outside of PATH. Inspired by the xserver code ;-) Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* amd: remove support for LLVM 5.0Marek Olšák2018-08-031-1/+3
| | | | | | Users are encouraged to switch to LLVM 6.0 released in March 2018. Reviewed-by: Timothy Arceri <[email protected]>
* winsys/amdgpu: pass the BO list via the CS ioctl on DRM >= 3.27.0Marek Olšák2018-08-031-1/+1
|
* meson: use correct keyword to fix a meson warningJon Turney2018-08-021-1/+1
| | | | | | | | | | | | | With a sufficently recent meson, the following warning is produced: WARNING: Passed invalid keyword argument "extra_args". WARNING: This will become a hard error in the future. It seems that compiler.links(args:) is meant here. Signed-off-by: Jon Turney <[email protected]> Reviewed-and-Tested-by: Eric Engestrom <[email protected]> Reviewed-by: Dylan Baker <[email protected]>
* util/disk_cache: Fix disk_cache_get_function_timestamp with disabled cache.Bas Nieuwenhuizen2018-07-201-1/+1
| | | | | | | | | | radv always needs it, so just check the header instead. Also do not declare the function if the variable is not set, so we get a nice compile error instead of failing to open a device at runtime. Fixes: b87ef9e606a "util: fix MSVC build issue in disk_cache.h" Reviewed-by: Timothy Arceri <[email protected]>