summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorHubert Jarosz2016-08-08 14:41:37 +0200
committerHubert Jarosz2016-08-08 14:41:37 +0200
commit1611b0c6724b1971b1bf967e44fa4869e8559f8a (patch)
tree1993841cc637ca5839f3649f05957a2bf563d7d0
parent843fd9686f596b9e2cc3f5d3b837b3ce160c7fef (diff)
downloadaur-1611b0c6724b1971b1bf967e44fa4869e8559f8a.tar.gz
apply patches for g++ and make it default
-rw-r--r--.SRCINFO7
-rw-r--r--.gitignore9
-rw-r--r--PKGBUILD16
-rw-r--r--patch.diff67
4 files changed, 87 insertions, 12 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 5c1741fe7f2..5412c6ae28e 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,14 +1,13 @@
# Generated by mksrcinfo v8
-# Thu Aug 4 10:11:31 UTC 2016
+# Mon Aug 8 12:37:30 UTC 2016
pkgbase = renderdoc
pkgdesc = OpenGL and Vulkan debugging tool
pkgver = 0.30
- pkgrel = 2
+ pkgrel = 3
url = https://github.com/baldurk/renderdoc
arch = i686
arch = x86_64
license = MIT
- makedepends = clang
makedepends = cmake
makedepends = vim
depends = qt5-x11extras
@@ -20,8 +19,10 @@ pkgbase = renderdoc
depends = qt5-base
source = https://github.com/baldurk/renderdoc/archive/v0.30.tar.gz
source = renderdoc.desktop
+ source = patch.diff
sha384sums = c852283b5124ca53193f898fde5b4089db745231fae4a7ebed824e84f34aa659d3508b8074f99ac7db1e3587c3fbbba3
sha384sums = 965214960726d34efd08d82a879c75e20e49769e5d7c7d996b570f2754f4688a7331267e0a0e2c54dea1eea3c1ad9e38
+ sha384sums = d1bbd8906e0a1c458e4d8a3efb393f2a12854ebb7f5d31e72e2307586efb2628b61a06e66dd3016e7e683f83e9452e60
pkgname = renderdoc
diff --git a/.gitignore b/.gitignore
index 25cca9a92b3..5d3e58af0d3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,5 @@
-pkg/
-src/
-*.gz
-*.xz
+/pkg/
+/src/
+/*\.gz
+/*\.xz
+/renderdoc*\.log
diff --git a/PKGBUILD b/PKGBUILD
index 8d7347c1d08..a59f1a883b0 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,21 +2,27 @@
pkgname=renderdoc
pkgver=0.30
-pkgrel=2
+pkgrel=3
pkgdesc="OpenGL and Vulkan debugging tool"
arch=(i686 x86_64)
url="https://github.com/baldurk/renderdoc"
license=("MIT")
-makedepends=("clang" "cmake" "vim")
+makedepends=("cmake" "vim")
depends=("qt5-x11extras" "libx11" "libxcb" "xcb-util-keysyms" "mesa" "mesa-libgl" "qt5-base")
source=("https://github.com/baldurk/renderdoc/archive/v$pkgver.tar.gz"
- "$pkgname.desktop")
+ "$pkgname.desktop"
+ "patch.diff")
sha384sums=("c852283b5124ca53193f898fde5b4089db745231fae4a7ebed824e84f34aa659d3508b8074f99ac7db1e3587c3fbbba3"
- "965214960726d34efd08d82a879c75e20e49769e5d7c7d996b570f2754f4688a7331267e0a0e2c54dea1eea3c1ad9e38")
+ "965214960726d34efd08d82a879c75e20e49769e5d7c7d996b570f2754f4688a7331267e0a0e2c54dea1eea3c1ad9e38"
+ "d1bbd8906e0a1c458e4d8a3efb393f2a12854ebb7f5d31e72e2307586efb2628b61a06e66dd3016e7e683f83e9452e60")
+
+prepare() {
+ patch -d "$pkgname-$pkgver" -i "../patch.diff" -p1
+}
build() {
cd $pkgname-$pkgver
- make CXX=clang++
+ make
}
package() {
diff --git a/patch.diff b/patch.diff
new file mode 100644
index 00000000000..47d1314de3d
--- /dev/null
+++ b/patch.diff
@@ -0,0 +1,67 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index a53b6bb..08b285e 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -20,7 +20,7 @@ set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
+ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
+
+ if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fstrict-aliasing")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
+
+ set(warning_flags
+@@ -28,8 +28,9 @@ if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+ -Wextra
+ -Werror
+ -Wno-unused-variable
+- -Wno-type-limits
+ -Wno-unused-parameter
++ -Wno-unused-result
++ -Wno-type-limits
+ -Wno-missing-field-initializers
+ -Wno-unknown-pragmas
+ -Wno-reorder)
+diff --git a/renderdoc/driver/vulkan/CMakeLists.txt b/renderdoc/driver/vulkan/CMakeLists.txt
+index 8a3d7bc..56473ce 100644
+--- a/renderdoc/driver/vulkan/CMakeLists.txt
++++ b/renderdoc/driver/vulkan/CMakeLists.txt
+@@ -58,6 +58,12 @@ elseif(UNIX)
+ add_custom_target(generate-json ALL DEPENDS ${json_out})
+ endif()
+
++# GCC 6.1 may or may not complain about enum reference casts
++if(CMAKE_COMPILER_IS_GNUCXX)
++ set_source_files_properties(vk_common.cpp
++ PROPERTIES COMPILE_FLAGS "-Wno-strict-aliasing")
++endif()
++
+ add_library(rdoc_vulkan OBJECT ${sources})
+ target_compile_definitions(rdoc_vulkan ${definitions})
+ target_include_directories(rdoc_vulkan ${RDOC_INCLUDES})
+diff --git a/renderdoc/driver/vulkan/vk_common.cpp b/renderdoc/driver/vulkan/vk_common.cpp
+index eaf2683..9f576de 100644
+--- a/renderdoc/driver/vulkan/vk_common.cpp
++++ b/renderdoc/driver/vulkan/vk_common.cpp
+@@ -2809,7 +2809,7 @@ void Serialiser::Serialise(const char *name, VkDeviceQueueCreateInfo &el)
+ Serialise("queueCount", el.queueCount);
+ if(m_Mode == READING)
+ el.pQueuePriorities = NULL;
+- SerialisePODArray("pQueuePriorities", (uint32_t *&)el.pQueuePriorities, el.queueCount);
++ SerialisePODArray("pQueuePriorities", (float *&)el.pQueuePriorities, el.queueCount);
+ }
+
+ // technically this doesn't need a serialise function as it's POD,
+diff --git a/renderdoc/driver/vulkan/vk_debug.cpp b/renderdoc/driver/vulkan/vk_debug.cpp
+index 1b39857..38c71f5 100644
+--- a/renderdoc/driver/vulkan/vk_debug.cpp
++++ b/renderdoc/driver/vulkan/vk_debug.cpp
+@@ -4391,7 +4391,7 @@ ResourceId VulkanDebugManager::RenderOverlay(ResourceId texid, TextureDisplayOve
+ ubo->Inner_Color = Vec4f(0.2f, 0.2f, 0.9f, 0.7f);
+ ubo->Border_Color = Vec4f(0.1f, 0.1f, 0.1f, 1.0f);
+ ubo->Scissor = 0;
+- ubo->ViewRect = (Vec4f &)viewport;
++ ubo->ViewRect = Vec4f(viewport.x, viewport.y, viewport.width, viewport.height);
+
+ m_OutlineUBO.Unmap();
+