Package: guix-patches;
Reported by: Zheng Junjie <z572 <at> z572.online>
Date: Mon, 17 Mar 2025 14:55:01 UTC
Severity: normal
Tags: patch
Done: Z572 <z572 <at> z572.online>
Bug is archived. No further changes may be made.
View this message in rfc822 format
From: help-debbugs <at> gnu.org (GNU bug Tracking System) To: Zheng Junjie <z572 <at> z572.online> Subject: bug#77071: closed (Re: [bug#77071] [PATCH] gnu: ogre-next: Fix build on riscv64.) Date: Sun, 30 Mar 2025 03:28:03 +0000
[Message part 1 (text/plain, inline)]
Your bug report #77071: [PATCH] gnu: ogre-next: Fix build on riscv64. which was filed against the guix-patches package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 77071 <at> debbugs.gnu.org. -- 77071: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=77071 GNU Bug Tracking System Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Z572 <z572 <at> z572.online> To: 77071-done <at> debbugs.gnu.org Subject: Re: [bug#77071] [PATCH] gnu: ogre-next: Fix build on riscv64. Date: Sun, 30 Mar 2025 11:26:01 +0800[Message part 3 (text/plain, inline)]Zheng Junjie <z572 <at> z572.online> writes: > * gnu/packages/graphics.scm (ogre-next): Fix build on riscv64. > [source]: Add ogre-next-add-riscv64-support.patch. > [argument]<#:configure-flags>: When target riscv64, Add -DOGRE_SIMD_SSE2=OFF > and -DOGRE_SIMD_NEON=OFF. > * gnu/packages/patches/ogre-next-add-riscv64-support.patch: New file. > * gnu/local.mk (dist_patch_DATA): Register it. > > Change-Id: I77279f3f5ed238f8b6526b5eceea5751f86ea6e1 > --- > gnu/local.mk | 1 + > gnu/packages/graphics.scm | 12 ++++++-- > .../ogre-next-add-riscv64-support.patch | 28 +++++++++++++++++++ > 3 files changed, 39 insertions(+), 2 deletions(-) > create mode 100644 gnu/packages/patches/ogre-next-add-riscv64-support.patch > > diff --git a/gnu/local.mk b/gnu/local.mk > index 01d13a11ae8..c9533507eac 100644 > --- a/gnu/local.mk > +++ b/gnu/local.mk > @@ -1918,6 +1918,7 @@ dist_patch_DATA = \ > %D%/packages/patches/nyacc-binary-literals.patch \ > %D%/packages/patches/obs-modules-location.patch \ > %D%/packages/patches/ocaml-multiple-definitions.patch \ > + %D%/packages/patches/ogre-next-add-riscv64-support.patch \ > %D%/packages/patches/ocaml-4.07-dynamically-allocate-signal-stack.patch \ > %D%/packages/patches/ocaml-4.09-dynamically-allocate-signal-stack.patch \ > %D%/packages/patches/ocaml-4.09-multiple-definitions.patch \ > diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm > index 9d7ec2933a9..82057adf680 100644 > --- a/gnu/packages/graphics.scm > +++ b/gnu/packages/graphics.scm > @@ -29,7 +29,7 @@ > ;;; Copyright © 2021, 2022 Vinicius Monego <monego <at> posteo.net> > ;;; Copyright © 2022 Michael Rohleder <mike <at> rohleder.de> > ;;; Copyright © 2022, 2023, 2024 John Kehayias <john.kehayias <at> protonmail.com> > -;;; Copyright © 2022, 2024 Zheng Junjie <873216071 <at> qq.com> > +;;; Copyright © 2022, 2024, 2025 Zheng Junjie <z572 <at> z572.online> > ;;; Copyright © 2022 Tobias Kortkamp <tobias.kortkamp <at> gmail.com> > ;;; Copyright © 2022 Paul A. Patience <paul <at> apatience.com> > ;;; Copyright © 2022 dan <i <at> dan.games> > @@ -1351,6 +1351,7 @@ (define-public ogre-next > (url "https://github.com/OGRECave/ogre-next") > (commit (string-append "v" version)))) > (file-name (git-file-name name version)) > + (patches (search-patches "ogre-next-add-riscv64-support.patch")) > (sha256 > (base32 > "1yrlg3s654xbp95208h9a2b8jcwdk69r6sjvll0aiyvxm4c056cw")))) > @@ -1358,7 +1359,14 @@ (define-public ogre-next > ((#:tests? _ #f) > ;; The test suite is currently disabled by the build system > ;; (see: https://github.com/OGRECave/ogre-next/issues/466). > - #f))) > + #f) > + ((#:configure-flags flags #~(list)) > + (if (target-riscv64?) > + #~(cons* > + "-DOGRE_SIMD_SSE2=OFF" > + "-DOGRE_SIMD_NEON=OFF" > + #$flags) > + flags)))) > (inputs > (modify-inputs (package-inputs ogre) > (append rapidjson))))) > diff --git a/gnu/packages/patches/ogre-next-add-riscv64-support.patch b/gnu/packages/patches/ogre-next-add-riscv64-support.patch > new file mode 100644 > index 00000000000..37251eaaf20 > --- /dev/null > +++ b/gnu/packages/patches/ogre-next-add-riscv64-support.patch > @@ -0,0 +1,28 @@ > +from https://github.com/OGRECave/ogre-next/pull/478 > + > +From 12081a8f1a0e676ac618dd7c4c1d2e8390c07278 Mon Sep 17 00:00:00 2001 > +From: Eric Long <i <at> hack3r.moe> > +Date: Mon, 18 Nov 2024 21:56:13 +0800 > +Subject: [PATCH] Add riscv64 to 64-bit architectures > + > +--- > + OgreMain/include/OgrePlatform.h | 3 ++- > + 1 file changed, 2 insertions(+), 1 deletion(-) > + > +diff --git a/OgreMain/include/OgrePlatform.h b/OgreMain/include/OgrePlatform.h > +index f9f7a12e46..a977aa2958 100644 > +--- a/OgreMain/include/OgrePlatform.h > ++++ b/OgreMain/include/OgrePlatform.h > +@@ -81,7 +81,8 @@ THE SOFTWARE. > + #if defined( __x86_64__ ) || defined( _M_X64 ) || defined( _M_X64 ) || defined( _M_AMD64 ) || \ > + defined( __ppc64__ ) || defined( __PPC64__ ) || defined( __arm64__ ) || defined( __aarch64__ ) || \ > + defined( _M_ARM64 ) || defined( __mips64 ) || defined( __mips64_ ) || defined( __alpha__ ) || \ > +- defined( __ia64__ ) || defined( __e2k__ ) || defined( __s390__ ) || defined( __s390x__ ) > ++ defined( __ia64__ ) || defined( __e2k__ ) || defined( __s390__ ) || defined( __s390x__ ) || \ > ++ (defined(__riscv) && __riscv_xlen == 64) > + # define OGRE_ARCH_TYPE OGRE_ARCHITECTURE_64 > + #else > + # define OGRE_ARCH_TYPE OGRE_ARCHITECTURE_32 > +-- > +2.47.1 > + > > base-commit: cb386c3c70212252ddcdb0bb9f6a8ecfd22378a6 pushed, closing.[signature.asc (application/pgp-signature, inline)]
[Message part 5 (message/rfc822, inline)]
From: Zheng Junjie <z572 <at> z572.online> To: guix-patches <at> gnu.org Subject: [PATCH] gnu: ogre-next: Fix build on riscv64. Date: Mon, 17 Mar 2025 22:54:07 +0800* gnu/packages/graphics.scm (ogre-next): Fix build on riscv64. [source]: Add ogre-next-add-riscv64-support.patch. [argument]<#:configure-flags>: When target riscv64, Add -DOGRE_SIMD_SSE2=OFF and -DOGRE_SIMD_NEON=OFF. * gnu/packages/patches/ogre-next-add-riscv64-support.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. Change-Id: I77279f3f5ed238f8b6526b5eceea5751f86ea6e1 --- gnu/local.mk | 1 + gnu/packages/graphics.scm | 12 ++++++-- .../ogre-next-add-riscv64-support.patch | 28 +++++++++++++++++++ 3 files changed, 39 insertions(+), 2 deletions(-) create mode 100644 gnu/packages/patches/ogre-next-add-riscv64-support.patch diff --git a/gnu/local.mk b/gnu/local.mk index 01d13a11ae8..c9533507eac 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1918,6 +1918,7 @@ dist_patch_DATA = \ %D%/packages/patches/nyacc-binary-literals.patch \ %D%/packages/patches/obs-modules-location.patch \ %D%/packages/patches/ocaml-multiple-definitions.patch \ + %D%/packages/patches/ogre-next-add-riscv64-support.patch \ %D%/packages/patches/ocaml-4.07-dynamically-allocate-signal-stack.patch \ %D%/packages/patches/ocaml-4.09-dynamically-allocate-signal-stack.patch \ %D%/packages/patches/ocaml-4.09-multiple-definitions.patch \ diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 9d7ec2933a9..82057adf680 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -29,7 +29,7 @@ ;;; Copyright © 2021, 2022 Vinicius Monego <monego <at> posteo.net> ;;; Copyright © 2022 Michael Rohleder <mike <at> rohleder.de> ;;; Copyright © 2022, 2023, 2024 John Kehayias <john.kehayias <at> protonmail.com> -;;; Copyright © 2022, 2024 Zheng Junjie <873216071 <at> qq.com> +;;; Copyright © 2022, 2024, 2025 Zheng Junjie <z572 <at> z572.online> ;;; Copyright © 2022 Tobias Kortkamp <tobias.kortkamp <at> gmail.com> ;;; Copyright © 2022 Paul A. Patience <paul <at> apatience.com> ;;; Copyright © 2022 dan <i <at> dan.games> @@ -1351,6 +1351,7 @@ (define-public ogre-next (url "https://github.com/OGRECave/ogre-next") (commit (string-append "v" version)))) (file-name (git-file-name name version)) + (patches (search-patches "ogre-next-add-riscv64-support.patch")) (sha256 (base32 "1yrlg3s654xbp95208h9a2b8jcwdk69r6sjvll0aiyvxm4c056cw")))) @@ -1358,7 +1359,14 @@ (define-public ogre-next ((#:tests? _ #f) ;; The test suite is currently disabled by the build system ;; (see: https://github.com/OGRECave/ogre-next/issues/466). - #f))) + #f) + ((#:configure-flags flags #~(list)) + (if (target-riscv64?) + #~(cons* + "-DOGRE_SIMD_SSE2=OFF" + "-DOGRE_SIMD_NEON=OFF" + #$flags) + flags)))) (inputs (modify-inputs (package-inputs ogre) (append rapidjson))))) diff --git a/gnu/packages/patches/ogre-next-add-riscv64-support.patch b/gnu/packages/patches/ogre-next-add-riscv64-support.patch new file mode 100644 index 00000000000..37251eaaf20 --- /dev/null +++ b/gnu/packages/patches/ogre-next-add-riscv64-support.patch @@ -0,0 +1,28 @@ +from https://github.com/OGRECave/ogre-next/pull/478 + +From 12081a8f1a0e676ac618dd7c4c1d2e8390c07278 Mon Sep 17 00:00:00 2001 +From: Eric Long <i <at> hack3r.moe> +Date: Mon, 18 Nov 2024 21:56:13 +0800 +Subject: [PATCH] Add riscv64 to 64-bit architectures + +--- + OgreMain/include/OgrePlatform.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/OgreMain/include/OgrePlatform.h b/OgreMain/include/OgrePlatform.h +index f9f7a12e46..a977aa2958 100644 +--- a/OgreMain/include/OgrePlatform.h ++++ b/OgreMain/include/OgrePlatform.h +@@ -81,7 +81,8 @@ THE SOFTWARE. + #if defined( __x86_64__ ) || defined( _M_X64 ) || defined( _M_X64 ) || defined( _M_AMD64 ) || \ + defined( __ppc64__ ) || defined( __PPC64__ ) || defined( __arm64__ ) || defined( __aarch64__ ) || \ + defined( _M_ARM64 ) || defined( __mips64 ) || defined( __mips64_ ) || defined( __alpha__ ) || \ +- defined( __ia64__ ) || defined( __e2k__ ) || defined( __s390__ ) || defined( __s390x__ ) ++ defined( __ia64__ ) || defined( __e2k__ ) || defined( __s390__ ) || defined( __s390x__ ) || \ ++ (defined(__riscv) && __riscv_xlen == 64) + # define OGRE_ARCH_TYPE OGRE_ARCHITECTURE_64 + #else + # define OGRE_ARCH_TYPE OGRE_ARCHITECTURE_32 +-- +2.47.1 + base-commit: cb386c3c70212252ddcdb0bb9f6a8ecfd22378a6 -- 2.48.1
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.