Add s390x support

This commit is contained in:
pcpa 2017-11-15 05:32:01 -05:00
parent e4f5d7df69
commit ce57a49469
2 changed files with 30 additions and 0 deletions

View File

@ -0,0 +1,27 @@
diff -up nvidia-texture-tools/src/nvcore/nvcore.h.orig nvidia-texture-tools/src/nvcore/nvcore.h
--- nvidia-texture-tools/src/nvcore/nvcore.h.orig 2017-11-15 05:24:04.826858170 -0500
+++ nvidia-texture-tools/src/nvcore/nvcore.h 2017-11-15 05:24:18.980858712 -0500
@@ -78,6 +78,8 @@
# define NV_CPU_MIPS 1
#elif defined POSH_CPU_MIPS64
# define NV_CPU_MIPS64 1
+#elif defined POSH_CPU_S390
+# define NV_CPU_S390 1
#else
# error "Unsupported CPU"
#endif
diff -up nvidia-texture-tools/src/nvcore/poshlib/posh.h.orig nvidia-texture-tools/src/nvcore/poshlib/posh.h
--- nvidia-texture-tools/src/nvcore/poshlib/posh.h.orig 2017-11-15 05:22:08.066853699 -0500
+++ nvidia-texture-tools/src/nvcore/poshlib/posh.h 2017-11-15 05:23:05.949855915 -0500
@@ -527,6 +527,11 @@ Metrowerks:
# define POSH_CPU_STRING "PA-RISC"
#endif
+#if defined __s390__ || defined __s390x__
+# define POSH_CPU_S390 1
+# define POSH_CPU_STRING "S390"
+#endif
+
#if !defined POSH_CPU_STRING
# error POSH cannot determine target CPU
# define POSH_CPU_STRING "Unknown" /* this is here for Doxygen's benefit */

View File

@ -35,6 +35,8 @@ Patch6: %{name}-aarch64.patch
Patch7: %{name}-bool-null.patch
# add MIPS support
Patch8: %{name}-mips.patch
# add S390 support
Patch9: %{name}-s390.patch
%description
The NVIDIA Texture Tools is a collection of image processing and texture
@ -67,6 +69,7 @@ Headers and libraries for development with %{name}.
%patch6 -p1
%patch7 -p1
%patch8 -p1
%patch9 -p1
%build
mkdir -p build