Description: Support loongson64
Author: wuruilong <wuruilong@loongson.cn>
Bug-Debian: https://bugs.debian.org/1060369
Last-Update: 2025-03-06

--- gridengine-8.1.9+dfsg.orig/source/aimk
+++ gridengine-8.1.9+dfsg/source/aimk
@@ -1960,6 +1960,9 @@ if ( $JNI == 1 ) then
 	 case lx-x32:
              set JAVA_LIB_ARCH = `expr substr $buildarch 4 9`
              breaksw
+         case lx-loong64:
+             set JAVA_LIB_ARCH = loong64
+             breaksw
          case lx-ppc64:
              if ($FORCE_32BIT == 1) then
                 set JAVA_LIB_ARCH = ppc
--- gridengine-8.1.9+dfsg.orig/source/dist/util/arch
+++ gridengine-8.1.9+dfsg/source/dist/util/arch
@@ -206,6 +206,9 @@ Linux)
 	  lxmachine=amd64
       fi
       ;;
+   loongarch64)
+      lxmachine=loong64
+      ;;
    mips)
       lxmachine=mips
       maybe_el
--- gridengine-8.1.9+dfsg.orig/source/scripts/compilearch
+++ gridengine-8.1.9+dfsg/source/scripts/compilearch
@@ -185,6 +185,11 @@ case $buildarch in
       COMPILE_ARCH=LINUXIA64
       TARGET_BITS=TARGET_64BIT
       ;;
+   lx-loong64)
+      BUILDARCH=LINUXLOONG64
+      COMPILE_ARCH=LINUXLOONG64
+      TARGET_BITS=TARGET_64BIT
+      ;;
    lx-mips)
       BUILDARCH=LINUXMIPS
       COMPILE_ARCH=LINUXMIPS
