From 54e90e1f0629d07dd82da8320788c132eb23e439e8849ce094eafab6d6115ebc Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Klaus=20K=C3=A4mpf?= <kkaempf@suse.com>
Date: Mon, 6 Feb 2023 09:29:14 +0000
Subject: [PATCH] Accepting request 1060942 from
 home:guoyunhe:branches:Emulators

- Add patch fix-test-files.patch
- Remove test files that are only useful for developers and testers
- Remove rpmlint because lint issues had been fixed by patch

OBS-URL: https://build.opensuse.org/request/show/1060942
OBS-URL: https://build.opensuse.org/package/show/Emulators/rpcs3?expand=0&rev=41
---
 fix-test-files.patch | 11 +++++++++++
 rpcs3.changes        |  7 +++++++
 rpcs3.rpmlintrc      |  4 ----
 rpcs3.spec           |  4 +++-
 4 files changed, 21 insertions(+), 5 deletions(-)
 create mode 100644 fix-test-files.patch
 delete mode 100644 rpcs3.rpmlintrc

diff --git a/fix-test-files.patch b/fix-test-files.patch
new file mode 100644
index 0000000..ad6987f
--- /dev/null
+++ b/fix-test-files.patch
@@ -0,0 +1,11 @@
+diff --git a/rpcs3/CMakeLists.txt b/rpcs3/CMakeLists.txt
+index 72b3e06e0bd..5a599102287 100644
+--- a/rpcs3/CMakeLists.txt
++++ b/rpcs3/CMakeLists.txt
+@@ -217,6 +217,4 @@ if(UNIX AND NOT APPLE)
+         DESTINATION ${CMAKE_INSTALL_DATADIR}/rpcs3)
+     install(DIRECTORY ../bin/git
+         DESTINATION ${CMAKE_INSTALL_DATADIR}/rpcs3)
+-    install(DIRECTORY ../bin/test
+-        DESTINATION ${CMAKE_INSTALL_DATADIR}/rpcs3)
+ endif()
diff --git a/rpcs3.changes b/rpcs3.changes
index 5cabf90..a4f3bff 100644
--- a/rpcs3.changes
+++ b/rpcs3.changes
@@ -1,3 +1,10 @@
+-------------------------------------------------------------------
+Wed Jan 25 12:42:08 UTC 2023 - Yunhe Guo <i@guoyunhe.me>
+
+- Add patch fix-test-files.patch
+- Remove test files that are only useful for developers and testers
+- Remove rpmlint because lint issues had been fixed by patch
+
 -------------------------------------------------------------------
 Mon Jan 09 11:08:49 UTC 2023 - i@guoyunhe.me
 
diff --git a/rpcs3.rpmlintrc b/rpcs3.rpmlintrc
deleted file mode 100644
index f4b1466..0000000
--- a/rpcs3.rpmlintrc
+++ /dev/null
@@ -1,4 +0,0 @@
-addFilter("missing-PT_GNU_STACK-section /usr/share/rpcs3/test/.*.elf")
-addFilter("position-independent-executable-suggested /usr/share/rpcs3/test/.*.elf")
-addFilter("statically-linked-binary /usr/share/rpcs3/test/.*.elf")
-addFilter("arch-dependent-file-in-usr-share /usr/share/rpcs3/test/.*.elf")
diff --git a/rpcs3.spec b/rpcs3.spec
index 35e1541..55e8b41 100644
--- a/rpcs3.spec
+++ b/rpcs3.spec
@@ -23,7 +23,8 @@ Summary:        PS3 emulator/debugger
 License:        GPL-2.0-only
 URL:            https://rpcs3.net
 Source0:        %{name}-%{version}.tar.xz
-Source1:	intel-ittapi.tar.xz
+Source1:        intel-ittapi.tar.xz
+Patch1:         fix-test-files.patch
 BuildRequires:  gcc-c++ >= 9
 BuildRequires:  cmake(x86-64) >= 3.14.1
 BuildRequires:  pkgconfig(libpng)
@@ -91,6 +92,7 @@ An open-source PlayStation 3 emulator/debugger written in C++.
 
 %prep
 %setup -q -a 1
+%patch1 -p 1
 
 #Generate Version Strings
 GIT_VERSION=$(echo %{version} | sed 's|.*git|git~|g')