summaryrefslogtreecommitdiff
path: root/Android.mk
AgeCommit message (Collapse)AuthorFilesLines
2020-02-07freedreno: android: fix build failure on android due to python versionMartin Fuzzey1-0/+1
The freedreno gen_header.py script now only works under python3. It contains a "print()" call which prints a blank line under python3 but prints "()" under python2.7. However the Android build currently uses python2. This leads to incorrect code generation and a later build error. .../STATIC_LIBRARIES/libfreedreno_registers_intermediates/registers/adreno_common.xml.h:163:2: error: expected identifier or '(' () Fix this by adding MESA_PYTHON3 and using it for the freedreno scripts. Signed-off-by: Martin Fuzzey <martin.fuzzey@flowbird.group> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3736>
2020-01-24etnaviv: update Android build filesMartin Fuzzey1-0/+1
etnaviv no longer builds on Android, fix this. Signed-off-by: Martin Fuzzey <martin.fuzzey@flowbird.group> Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3447> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3447>
2019-11-12android: mesa: Revert "android: mesa: revert "Enable asm unconditionally""Lepton Wu1-7/+0
Commit 45206d7673adb1484cbdb3eadaf82e0849c9cdcf fixed PIC issue of x86 asm stub. We can enable asm for Android x86 now. This should sightly improve performance. Acked-by: Eric Anholt <eric@anholt.net> Acked-by: Eric Engestrom <eric.engestrom@intel.com> Acked-by: Tapani Pälli <tapani.palli@intel.com> Signed-off-by: Lepton Wu <lepton@chromium.org>
2019-10-31android: Add panfrost support to build scriptsRobert Foss1-2/+3
Currently the Android build system doesn't expose the panfrost driver. This patch enables the panfrost driver to be build on for the Android platform. Signed-off-by: Robert Foss <robert.foss@collabora.com> Reviewed-By: Rohan Garg <rohan.garg@collabora.com> Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
2019-09-13Android.mk: Fix missing \ from recent llvm changeJohn Stultz1-1/+1
Building w/ AOSP, I was hitting the following error: external/mesa3d/src/amd/Android.common.mk:95: error: missing separator. Which was due to the changes to mesa-build-with-llvm missing a line continuation. Fixes: 96b592696f13 Signed-off-by: John Stultz <john.stultz@linaro.org>
2019-09-11gallium: Require LLVM >= 3.9Adam Jackson1-7/+2
To go any further than this would be to break the current version of Android. Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com> Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
2019-09-11gallium: Require LLVM >= 3.8Adam Jackson1-3/+1
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com> Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
2019-09-06meson/scons/android: drop now-unused HAVE_LLVMEric Engestrom1-4/+4
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Acked-by: Michel Dänzer <mdaenzer@redhat.com>
2019-09-06meson/scons/android: add LLVM_AVAILABLE binary flagEric Engestrom1-4/+4
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Acked-by: Michel Dänzer <mdaenzer@redhat.com>
2019-09-06android: mesa: revert "Enable asm unconditionally"Mauro Rossi1-0/+7
This patch partially reverts 20294dc ("mesa: Enable asm unconditionally, ...") Android makefile build logic needs to disable assembler optimization in 32bit builds to avoid text relocations for libglapi.so shared Fixes the following build error with Android x86 32bit target: [ 0% 4/477] target SharedLib: libglapi (out/target/product/x86/obj/SHARED_LIBRARIES/libglapi_intermediates/LINKED/libglapi.so) FAILED: out/target/product/x86/obj/SHARED_LIBRARIES/libglapi_intermediates/LINKED/libglapi.so ... prebuilts/gcc/linux-x86/x86/x86_64-linux-android-4.9/x86_64-linux-android/bin/ld: warning: shared library text segment is not shareable prebuilts/gcc/linux-x86/x86/x86_64-linux-android-4.9/x86_64-linux-android/bin/ld: error: treating warnings as errors clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation) Fixes: 20294dc ("mesa: Enable asm unconditionally, now that gen_matypes is gone.") Signed-off-by: Mauro Rossi <issor.oruam@gmail.com> Acked-by: Eric Engestrom <eric@engestrom.ch>
2019-08-08Add libpanfrost_shared to Android buildRoman Stratiienko1-1/+2
1. Add missing directory to ./Android.mk 2. Fix ./src/panfrost/Android.shared.mk Signed-off-by: Roman Stratiienko <roman.stratiienko@globallogic.com> Reviewed-by: Icenowy Zheng <icenowy@aosc.io> Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com> Acked-by: Qiang Yu <yuq825@gmail.com>
2019-07-01mesa: Enable asm unconditionally, now that gen_matypes is gone.Eric Anholt1-7/+0
Reviewed-by: Eric Engestrom <eric.engestrom@intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com>
2019-05-06mesa: android: freedreno: build libfreedreno_{drm,ir3} static libsAmit Pundir1-0/+1
Add libfreedreno_drm/ir3 to the build Cc: Rob Clark <robdclark@chromium.org> Cc: Emil Velikov <emil.l.velikov@gmail.com> Cc: Amit Pundir <amit.pundir@linaro.org> Cc: Sumit Semwal <sumit.semwal@linaro.org> Cc: Alistair Strachan <astrachan@google.com> Cc: Greg Hartman <ghartman@google.com> Cc: Tapani Pälli <tapani.palli@intel.com> Cc: Jason Ekstrand <jason@jlekstrand.net> Fixes: b4476138d5a ("freedreno: move drm to common location") Fixes: aa0fed10d35 ("freedreno: move ir3 to common location") Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Amit Pundir <amit.pundir@linaro.org> [jstultz: Tweaked to add extra ir3 files from master] Signed-off-by: John Stultz <john.stultz@linaro.org>
2019-04-21lima: add Android buildIcenowy Zheng1-2/+3
Currently only meson build supported is added for lima driver. Add Android build support for lima. Signed-off-by: Icenowy Zheng <icenowy@aosc.io> Acked-by: Qiang Yu <yuq825@gmail.com>
2019-04-13android: fix LLVM version string related building errorsMauro Rossi1-4/+4
Adding \ prior to " in llvm version string fixes the following building errors: external/mesa/src/gallium/drivers/r600/r600_pipe_common.c:1290:14: error: expected ')' ", LLVM " MESA_LLVM_VERSION_STRING ^ <command line>:8:34: note: expanded from here ^ external/mesa/src/gallium/drivers/r600/r600_pipe_common.c:1287:10: note: to match this '(' snprintf(rscreen->renderer_string, sizeof(rscreen->renderer_string), ^ 1 error generated. Fixes: 05b114e ("simplify LLVM version string printing") Signed-off-by: Mauro Rossi <issor.oruam@gmail.com> Reviewed-by: Eric Engestrom <eric@engestrom.ch>
2019-04-04simplify LLVM version string printingEric Engestrom1-4/+4
Figure it out once in the build system, then just use that all over the place. Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2019-02-21iris: add Android buildTapani Pälli1-2/+3
Note that at least following additional libs/components require changes since they refer to BOARD_GPU_DRIVERS variable which is used to select the driver: - mixins - minigbm - libdrm - drm_gralloc v2: (feedback by Gustaw Smolarczyk) Fix trailing \ in a few cases Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
2019-01-28Switch imx to kmsro and remove the imx winsysRob Herring1-3/+2
The kmsro winsys is equivalent to the imx winsys, so we can switch to it and remove the imx one. Signed-off-by: Rob Herring <robh@kernel.org>
2019-01-28pl111: Rename the pl111 driver to "kmsro".Eric Anholt1-2/+2
The vc4 driver can do prime sharing to many different KMS-only devices, such as the various tinydrm drivers for SPI-attached displays. Rename the driver away from "pl111" to represent what it will actually support: various sorts of KMS displays with the renderonly layer used to attach a GPU. Reviewed-by: Eric Engestrom <eric.engestrom@intel.com> Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com> Acked-by: Emil Velikov <emil.velikov@collabora.com>
2017-10-31dri drivers: Always add the sha1 build-idJordan Justen1-0/+1
v4: * Add Android build changes. (Emil) Cc: Dylan Baker <dylanx.c.baker@intel.com> Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Dylan Baker <dylanx.c.baker@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2017-10-12Android: disable i9x5 drivers on non-x86 buildsRob Herring1-0/+4
The i965 driver has become dependent on x86 specific compiler builtin functions, so ensure it's disabled for non-x86 builds. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Signed-off-by: Rob Herring <robh@kernel.org>
2017-09-11Android: Add LLVM support for Android PRob Herring1-0/+2
The Android version in AOSP master has changed now to P, so we need to add LLVM flags for it. Duplicating the lines because I expect the version will get bumped at some point and diverge from O. Cc: Chih-Wei Huang <cwhuang@android-x86.org> Signed-off-by: Rob Herring <robh@kernel.org>
2017-08-24Android: fix Android O version check for LLVMRob Herring1-1/+1
With the release of O, the MESA_ANDROID_MAJOR_VERSION has changed to 8. Change the LLVM check to match. There's no point to continue to support 'O' as no one is going to use an old AOSP master. Presumably, we'll be back here again to fix things again for P (or 9). Reviewed-by: Chih-Wei Huang <cwhuang@linux.org.tw> Signed-off-by: Rob Herring <robh@kernel.org>
2017-08-21Android: Fix LLVM duplicated symbols linking for N and MRob Herring1-8/+4
Both statically linking libLLVMCore and dynamically linking libLLVM causes duplicated symbols in gallium_dri.so and it fails to dlopen. We don't really need to link libLLVMCore, but just need generated headers to be built first. Dynamically linking to libLLVM instead is enough to do that. Thanks to Qiang Yu for finding the root cause. With this change, we can align all versions and just have libLLVM as a shared lib dependency. This also requires changes in the M and N versions of LLVM to export the include paths for libLLVM. AOSP master is okay. Fixes: 26aee6f4d5a ("Android: rework LLVM build support") Reported-by: Mauro Rossi <issor.oruam@gmail.com> Cc: 17.2 <mesa-stable@lists.freedesktop.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Qiang Yu <Qiang.Yu@amd.com> Signed-off-by: Rob Herring <robh@kernel.org>
2017-07-05android: build imx-drm winsysTomeu Vizoso1-2/+3
Add Android.mk for winsys/imx/drm. Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-07-05android: add etnaviv driver build supportRob Herring1-2/+3
Add etnaviv to Android makefiles. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2017-06-30vc4: Introduce XML-based packet header generation like Intel's.Eric Anholt1-0/+1
I really liked this idea, as it should help with management of packet parsing tools like the CL dump. The python script is forked off of theirs because our packets are byte-based instead of dwords, and the changes to do so while avoiding performance regressions due to unaligned accesses were quite invasive. v2: Fix Android.mk paths, drop shebang for python script, fix overlap detection. Acked-by: Jason Ekstrand <jason@jlekstrand.net> Acked-by: Kenneth Graunke <kenneth@whitecape.org> Tested-by: Rob Herring <robh@kernel.org>
2017-06-15gallium: Add renderonly-based support for pl111+vc4.Eric Anholt1-1/+2
This follows the model of imx (display) and etnaviv (render): pl111 is a display-only device, so when asked to do GL for it, we see if we have a vc4 renderer, make the vc4 screen, and have vc4 call back to pl111 to do scanout allocations. The difference from etnaviv is that we share the same BO between vc4 and pl111, rather than having a vc4 bo and a pl11 bo and copies between the two. The only mismatch between their requirements is that vc4 requires 4-pixel (at 32bpp) stride alignment, while pl111 requires that stride match width. The kernel will reject any modesets to an incorrect stride, so the 3D driver doesn't need to worry about that. v2: Rebase on Android rework, drop unused include. v3: Fix another Android bug, from Rob Herring's build-testing. Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
2017-05-25Android: generate an error if building on Android 4.4 or earlierRob Herring1-0/+3
Since commit 7a5b5f52260 ("Android: drop Android 4.4 (KitKat) support"), Android 4.4 or earlier is no longer supported, so exit with an error if we try building on it. Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Rob Herring <robh@kernel.org>
2017-05-11Android: Add LLVM support for Android ORob Herring1-1/+4
Android O moves to LLVM 3.9 and also has some differences in header dependencies as LLVM has moved to blueprint files. It seems libLLVMCore was only needed for header dependencies, so we can drop that for O. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-05-11Android: rework LLVM build supportRob Herring1-0/+13
Currently, building with "mmma external/mesa3d" which builds all targets and dependencies is broken for targets that require LLVM. This is due to the build settings depending on MESA_ENABLE_LLVM. Instead of using a conditional in the global Android.common.mk, make all the components that need LLVM explicitly include the necessary build settings. GALLIVM_CPP_SOURCES doesn't exist anymore, so remove that as well. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-05-11Android: Add driver "all" option to enable all driversRob Herring1-0/+5
Add a driver string "all" so that if BOARD_GPU_DRIVERS is set to "all", all the drivers are enabled in the build. This makes build testing all drivers easier to maintain. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-05-11Android: push driver build details to driver makefilesRob Herring1-24/+26
src/gallium/targets/dri/Android.mk contains lots of conditional for individual drivers. Let's move these details into the individual driver makefiles. In the process, align the make driver conditionals with automake (i.e. HAVE_GALLIUM_*). Signed-off-by: Rob Herring <robh@kernel.org> [Emil Velikov: add the radeon winsys for radeonsi] Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
2017-05-11Android: remove needless conditional including of child makefilesRob Herring1-8/+0
It is not necessary to filter driver and winsys directories based on the list of enabled drivers. Selecting the included driver libraries or not is sufficient to control what is built. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Chih-Wei Huang <cwhuang@linux.org.tw> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-03-22Android: drop Android 4.4 (KitKat) supportRob Herring1-8/+0
Any users of KitKat are likely using an older version of Mesa and KitKat support adds complexity to the make files. Dropping support allows removing the MESA_LOLLIPOP_BUILD make variable in various make files. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-03-22Android: kill off {MESA_}ANDROID_VERSION defines aka Android 4.1 and olderRob Herring1-1/+0
The Android version defines are only needed for versions less than 4.2 which aren't really supported or tested. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2017-02-28android: vulkan: add support for libmesa_vulkan_utilMauro Rossi1-1/+2
The following changes are implemented: Add src/vulkan/Android.mk to build libmesa_vulkan_util Android.mk: add src/vulkan to SUBDIR to build new module intel/vulkan: fix libmesa_vulkan_util,vk_enum_to_str.h dependencies Add -o OUTPUT_PATH option in src/vulkan/util/gen_enum_to_str.py script Use -o OUTPUT_PATH option in automake generation rules for vk_enum_to_str.{c,h} Fixes: e9dcb17 "vulkan/util: Add generator for enum_to_str functions" Fixes: 8e03250 "vulkan: Combine wsi and util makefiles" Reviewed-by: Dylan Baker <dylan@pnwbakers.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> [Emil Velikov] - Move parser within main() - Use --outdir instead of -o Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
2017-02-03ilo: EOL drop unmaintained gallium drv from buildsysEdward O'Callaghan1-2/+2
This is no longer actively maintained and is just accumulating bitrot. Signed-off-by: Edward O'Callaghan <funfunctor@folklore1984.net> Acked-by: Chia-I Wu <olvaffe@gmail.com>
2016-09-13android: add support for libmesa_amdgpu_addrlibMauro Rossi1-0/+1
Android porting of the following commits: f1f1ba3 "radeonsi: move sid.h/r600d_common.h to a common place." 69fca64 "amd/addrlib: move addrlib from amdgpu winsys to common code" This patch fixes android building errors Reviewed-by: Dave Airlie <airlied@redhat.com>
2016-08-29android: intel: Flatten the makefile structureMauro Rossi1-2/+1
Android porting of commit bebc1a1 "intel: Flatten the makefile structure" Automake approach was followed, by moving makefiles a level up, naming them Android.genxml.mk and Android.isl.mk, performing the necessary adjustments to the paths, adding src/intel/Android.mk and fixing mesa top level makefile. Acked-by: Jason Ekstrand <jason@jlekstrand.net>
2016-06-02isl: add support for Android libmesa_isl static libraryMauro Rossi1-0/+2
isl library is needed to build i965, libmesa_isl static library is added to fix related Android building errors. Any attempt to build libmesa_genxml as phony package module failed to deliver gen{7,75,8,9}_pack.h generated headers, needed for libmesa_isl_gen{7,75,8,9} Due to constraints in Android Build System, libmesa_genxml is built as static, at least one source is needed, so dummy.c is autogenerated for this scope, libmesa_genxml dependency is declared using LOCAL_WHOLE_STATIC_LIBRARIES, to avoid building errors due to missing genxml/gen{7,75,8,9}_pack.h headers. Cc: <mesa-stable@lists.freedesktop.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-05-23gbm: Add Android build supportRob Herring1-0/+1
In order to use libgbm for gralloc, add it to the Android build. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Eric Anholt <eric@anholt.net>
2016-05-01Android: fix build ordering of subdirectoriesRob Herring1-2/+4
Different versions of make behave differently in whether $(wildcard) sorts the results or not. The Android build now explicitly sorts all-named-subdir-makefiles which breaks the build because src/gallium must be included after src/mesa/drivers/dri. The Android build system doesn't support doing "include $(call all-named-subdir-makefiles,...)" twice, so rework things by generating the included makefile list and including them in 2 steps. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-04-11glsl: move the android build scripts a level upEmil Velikov1-1/+0
Analogous to previous commit. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Acked-by: Jason Ekstrand <jason@jlekstrand.net>
2016-02-29Android: clean-up and fix DRI module path handlingRob Herring1-0/+4
MESA_DRI_MODULE_PATH is only getting set for classic DRI drivers and may or may not be set correctly for gallium_dri.so depending on the makefile include ordering. For Android 6 and earlier it is fine, but with build system changes in AOSP master, it is not. Move the path variables to a single place at the top level and introduce MESA_DRI_MODULE_REL_PATH for Android 5 and later which require relative paths. With this, there is a single variable to change. Cc: "11.1 11.2" <mesa-stable@lists.freedesktop.org> Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-02-29Android: fix build break from nir/glsl move to compiler/Rob Herring1-1/+1
Commits a39a8fbbaa12 ("nir: move to compiler/") and eb63640c1d38 ("glsl: move to compiler/") broke Android builds. Fix them. There is also a missing dependency between generated NIR headers and several libraries. This isn't a new issue, but seems to have been exposed by the NIR move. Built with i915, i965, freedreno, r300g, r600g, vc4, and virgl enabled. Cc: "11.2" <mesa-stable@lists.freedesktop.org> Cc: Mauro Rossi <issor.oruam@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-01-26nir: move shader_enums.[ch] to compilerEmil Velikov1-0/+1
This way one can reuse it in glsl, nir or other infrastructure without pulling nir as dependency. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Acked-by: Matt Turner <mattst88@gmail.com> Acked-by: Jose Fonseca <jfonseca@vmware.com>
2016-01-23virgl: enable building on AndroidRob Herring1-2/+2
This is just a copy-n-paste and rename of vc4 Android makefiles. Signed-off-by: Rob Herring <robh@kernel.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
2015-07-22egl: android: remove DRM_GRALLOC_TOP hackEmil Velikov1-2/+0
Now that the drm_gralloc module exports the correct includes we can get rid of this hack. Cc: Chih-Wei Huang <cwhuang@android-x86.org> Cc: Eric Anholt <eric@anholt.net> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Tested-by: Varad Gautam <varadgautam@gmail.com>
2015-07-22android: rework the EGL buildEmil Velikov1-2/+1
See previous two commits for details. v2: Don't forget git mv, bring back DRM_GRALLOC_TOP. Spotted by Varad. Cc: Chih-Wei Huang <cwhuang@android-x86.org> Cc: Eric Anholt <eric@anholt.net> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Acked-by: Matt Turner <mattst88@gmail.com> Tested-by: Varad Gautam <varadgautam@gmail.com>