--- mesa-11.1.2.orig/.dir-locals.el +++ mesa-11.1.2/.dir-locals.el @@ -0,0 +1,12 @@ +((prog-mode + (indent-tabs-mode . nil) + (tab-width . 8) + (c-basic-offset . 3) + (c-file-style . "stroustrup") + (fill-column . 78) + (eval . (progn + (c-set-offset 'innamespace '0) + (c-set-offset 'inline-open '0))) + ) + (makefile-mode (indent-tabs-mode . t)) + ) --- mesa-11.1.2.orig/Android.common.mk +++ mesa-11.1.2/Android.common.mk @@ -0,0 +1,90 @@ +# Mesa 3-D graphics library +# +# Copyright (C) 2010-2011 Chia-I Wu +# Copyright (C) 2010-2011 LunarG Inc. +# +# Permission is hereby granted, free of charge, to any person obtaining a +# copy of this software and associated documentation files (the "Software"), +# to deal in the Software without restriction, including without limitation +# the rights to use, copy, modify, merge, publish, distribute, sublicense, +# and/or sell copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included +# in all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +# DEALINGS IN THE SOFTWARE. + +# use c99 compiler by default +ifeq ($(LOCAL_CC),) +ifeq ($(LOCAL_IS_HOST_MODULE),true) +LOCAL_CC := $(HOST_CC) -std=c99 -D_GNU_SOURCE +else +LOCAL_CC := $(TARGET_CC) -std=c99 +endif +endif + +LOCAL_C_INCLUDES += \ + $(MESA_TOP)/src \ + $(MESA_TOP)/include + +MESA_VERSION := $(shell cat $(MESA_TOP)/VERSION) +# define ANDROID_VERSION (e.g., 4.0.x => 0x0400) +LOCAL_CFLAGS += \ + -DPACKAGE_VERSION=\"$(MESA_VERSION)\" \ + -DPACKAGE_BUGREPORT=\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\" \ + -DANDROID_VERSION=0x0$(MESA_ANDROID_MAJOR_VERSION)0$(MESA_ANDROID_MINOR_VERSION) + +LOCAL_CFLAGS += \ + -D__STDC_LIMIT_MACROS \ + -DHAVE___BUILTIN_EXPECT \ + -DHAVE___BUILTIN_FFS \ + -DHAVE___BUILTIN_FFSLL \ + -DHAVE_FUNC_ATTRIBUTE_FLATTEN \ + -DHAVE_FUNC_ATTRIBUTE_UNUSED \ + -DHAVE_FUNC_ATTRIBUTE_FORMAT \ + -DHAVE_FUNC_ATTRIBUTE_PACKED \ + -DHAVE___BUILTIN_CTZ \ + -DHAVE___BUILTIN_POPCOUNT \ + -DHAVE___BUILTIN_POPCOUNTLL \ + -DHAVE___BUILTIN_CLZ \ + -DHAVE___BUILTIN_CLZLL \ + -DHAVE___BUILTIN_UNREACHABLE \ + -DHAVE_PTHREAD=1 \ + -fvisibility=hidden \ + -Wno-sign-compare + +ifeq ($(strip $(MESA_ENABLE_ASM)),true) +ifeq ($(TARGET_ARCH),x86) +LOCAL_CFLAGS += \ + -DUSE_X86_ASM \ + -DHAVE_DLOPEN \ + +endif +endif + +ifeq ($(MESA_ENABLE_LLVM),true) +LOCAL_CFLAGS += \ + -DHAVE_LLVM=0x0305 -DMESA_LLVM_VERSION_PATCH=2 \ + -D__STDC_CONSTANT_MACROS \ + -D__STDC_FORMAT_MACROS \ + -D__STDC_LIMIT_MACROS +endif + +LOCAL_CPPFLAGS += \ + $(if $(filter true,$(MESA_LOLLIPOP_BUILD)),-D_USING_LIBCXX) \ + -Wno-error=non-virtual-dtor \ + -Wno-non-virtual-dtor + +# uncomment to keep the debug symbols +#LOCAL_STRIP_MODULE := false + +ifeq ($(strip $(LOCAL_MODULE_TAGS)),) +LOCAL_MODULE_TAGS := optional +endif --- mesa-11.1.2.orig/Android.mk +++ mesa-11.1.2/Android.mk @@ -0,0 +1,101 @@ +# Mesa 3-D graphics library +# +# Copyright (C) 2010-2011 Chia-I Wu +# Copyright (C) 2010-2011 LunarG Inc. +# +# Permission is hereby granted, free of charge, to any person obtaining a +# copy of this software and associated documentation files (the "Software"), +# to deal in the Software without restriction, including without limitation +# the rights to use, copy, modify, merge, publish, distribute, sublicense, +# and/or sell copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included +# in all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +# DEALINGS IN THE SOFTWARE. + +# BOARD_GPU_DRIVERS should be defined. The valid values are +# +# classic drivers: i915 i965 +# gallium drivers: swrast freedreno i915g ilo nouveau r300g r600g radeonsi vc4 vmwgfx +# +# The main target is libGLES_mesa. For each classic driver enabled, a DRI +# module will also be built. DRI modules will be loaded by libGLES_mesa. + +MESA_TOP := $(call my-dir) + +MESA_ANDROID_MAJOR_VERSION := $(word 1, $(subst ., , $(PLATFORM_VERSION))) +MESA_ANDROID_MINOR_VERSION := $(word 2, $(subst ., , $(PLATFORM_VERSION))) +MESA_ANDROID_VERSION := $(MESA_ANDROID_MAJOR_VERSION).$(MESA_ANDROID_MINOR_VERSION) +ifeq ($(filter 1 2 3 4,$(MESA_ANDROID_MAJOR_VERSION)),) +MESA_LOLLIPOP_BUILD := true +else +define local-generated-sources-dir +$(call local-intermediates-dir) +endef +endif + +MESA_COMMON_MK := $(MESA_TOP)/Android.common.mk +MESA_PYTHON2 := python + +classic_drivers := i915 i965 +gallium_drivers := swrast freedreno i915g ilo nouveau r300g r600g radeonsi vmwgfx vc4 + +MESA_GPU_DRIVERS := $(strip $(BOARD_GPU_DRIVERS)) + +# warn about invalid drivers +invalid_drivers := $(filter-out \ + $(classic_drivers) $(gallium_drivers), $(MESA_GPU_DRIVERS)) +ifneq ($(invalid_drivers),) +$(warning invalid GPU drivers: $(invalid_drivers)) +# tidy up +MESA_GPU_DRIVERS := $(filter-out $(invalid_drivers), $(MESA_GPU_DRIVERS)) +endif + +# host and target must be the same arch to generate matypes.h +ifeq ($(TARGET_ARCH),$(HOST_ARCH)) +MESA_ENABLE_ASM := true +else +MESA_ENABLE_ASM := false +endif + +ifneq ($(filter $(classic_drivers), $(MESA_GPU_DRIVERS)),) +MESA_BUILD_CLASSIC := true +else +MESA_BUILD_CLASSIC := false +endif + +ifneq ($(filter $(gallium_drivers), $(MESA_GPU_DRIVERS)),) +MESA_BUILD_GALLIUM := true +else +MESA_BUILD_GALLIUM := false +endif + +MESA_ENABLE_LLVM := $(if $(filter radeonsi,$(MESA_GPU_DRIVERS)),true,false) + +# add subdirectories +ifneq ($(strip $(MESA_GPU_DRIVERS)),) + +SUBDIRS := \ + src/loader \ + src/mapi \ + src/glsl \ + src/mesa \ + src/util \ + src/egl \ + src/mesa/drivers/dri + +ifeq ($(strip $(MESA_BUILD_GALLIUM)),true) +SUBDIRS += src/gallium +endif + +include $(call all-named-subdir-makefiles,$(SUBDIRS)) + +endif --- mesa-11.1.2.orig/CleanSpec.mk +++ mesa-11.1.2/CleanSpec.mk @@ -0,0 +1,16 @@ +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/STATIC_LIBRARIES/libmesa_*_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/i9*5_dri_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libglapi_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libGLES_mesa_intermediates) +$(call add-clean-step, rm -rf $(OUT_DIR)/host/$(HOST_OS)-$(HOST_ARCH)/obj/EXECUTABLES/mesa_*_intermediates) +$(call add-clean-step, rm -rf $(OUT_DIR)/host/$(HOST_OS)-$(HOST_ARCH)/obj/EXECUTABLES/glsl_compiler_intermediates) +$(call add-clean-step, rm -rf $(OUT_DIR)/host/$(HOST_OS)-$(HOST_ARCH)/obj/STATIC_LIBRARIES/libmesa_glsl_utils_intermediates) + +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/*/STATIC_LIBRARIES/libmesa_*_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/*/SHARED_LIBRARIES/i9?5_dri_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/*/SHARED_LIBRARIES/libglapi_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/*/SHARED_LIBRARIES/libGLES_mesa_intermediates) +$(call add-clean-step, rm -rf $(HOST_OUT_release)/*/EXECUTABLES/mesa_*_intermediates) +$(call add-clean-step, rm -rf $(HOST_OUT_release)/*/EXECUTABLES/glsl_compiler_intermediates) +$(call add-clean-step, rm -rf $(HOST_OUT_release)/*/STATIC_LIBRARIES/libmesa_*_intermediates) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/*/SHARED_LIBRARIES/*_dri_intermediates) --- mesa-11.1.2.orig/bin/.cherry-ignore +++ mesa-11.1.2/bin/.cherry-ignore @@ -0,0 +1,9 @@ +# As per Marek http://lists.freedesktop.org/archives/mesa-stable/2015-December/003600.html +37208c4fd7b1ec679d10992b42a2811cab8245a5 Revert "radeonsi: disable DCC on Stoney" + +# causes regression in xwayland, kde/plasma, mpv, steam ... fdo#92759 +839793680f99b8387bee9489733d5071c10f3ace i965: Use MESA_FORMAT_B8G8R8X8_SRGB for RGB visuals + +# .num_slices isn't available in 11.1 +f2c891353609b48459f27f205407d42823dd7d03 Add missing platform information for KBL + --- mesa-11.1.2.orig/bin/bugzilla_mesa.sh +++ mesa-11.1.2/bin/bugzilla_mesa.sh @@ -0,0 +1,49 @@ +#!/bin/bash + +# This script is used to generate the list of fixed bugs that +# appears in the release notes files, with HTML formatting. +# +# Note: This script could take a while until all details have +# been fetched from bugzilla. +# +# Usage examples: +# +# $ bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 +# $ bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 > bugfixes +# $ bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 | tee bugfixes +# $ DRYRUN=yes bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 +# $ DRYRUN=yes bin/bugzilla_mesa.sh mesa-9.0.2..mesa-9.0.3 | wc -l + + +# regex pattern: trim before bug number +trim_before='s/.*show_bug.cgi?id=\([0-9]*\).*/\1/' + +# regex pattern: reconstruct the url +use_after='s,^,https://bugs.freedesktop.org/show_bug.cgi?id=,' + +# extract fdo urls from commit log +urls=$(git log $* | grep 'bugs.freedesktop.org/show_bug' | sed -e $trim_before | sort -n -u | sed -e $use_after) + +# if DRYRUN is set to "yes", simply print the URLs and don't fetch the +# details from fdo bugzilla. +#DRYRUN=yes + +if [ "x$DRYRUN" = xyes ]; then + for i in $urls + do + echo $i + done +else + echo "