Bug#1060885: gambc: Please add loongarch support

2024-01-15 Thread yalingfang

Source:  gambc
Version: 4.9.3-1.2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64

Dear Maintainer,
     Error happenes when compiling gambc in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/fetch.php?pkg=gambc=loong64=4.9.3-1.2=1704952464=0

I have  compiled and all cases passed by adding loongarch support  in my 
local env.

Attach the control patch.

Please add support for it. Thanks!
Any question, contact me!


add_loongarch_support.patch
Description: Binary data


Bug#1060833: git-annex: Please add build dep for loong64

2024-01-15 Thread yalingfang

Source: git-annex
Version: 10.20230802-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

When I built git-annex in my local, found lack of some build dependency.
Got a patch and attached it.

Please add support for it. Thanks!
Any question, contact me!


add-build-dep-for-loong64.patch
Description: Binary data


Bug#1060656: haskell-charsetdetect-ae: Please add support for loongarch

2024-01-12 Thread yalingfang

Source: haskell-charsetdetect-ae
Version: 1.1.0.4-5
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

    Unsupportted arch error happend when compiling 
fhaskell-charsetdetect-ae in Loongarch env.


The error message is following:

libcharsetdetect/nspr-emu/prcpucfg_linux.h:703:2: error:

     error: #error "Unknown CPU architecture"
      703 | #error "Unknown CPU architecture"
          |  ^
    |
703 | #error "Unknown CPU architecture"
    |  ^


libcharsetdetect/nspr-emu/prtypes.h:258:2: error:
     error: #error No suitable type for PRInt8/PRUint8
      258 | #error No suitable type for PRInt8/PRUint8
          |  ^


I have verified and compiled pass by adding loong64 support in my local env.
Attached the  patch.

Please add support for it. Thanks!
Any question, contact me!


add-loongarch-support.patch
Description: Binary data


Bug#1060125: qemu-web-desktop: Please add loong64 binary output

2024-01-05 Thread yalingfang

Source: qemu-web-desktop
Version: 23.06.22+ds1-2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,
     Currently no loong64 binary output for mindthegap in Loongarch env.
The buildd link is following:

https://buildd.debian.org/status/package.php?p=qemu-web-desktop=sid

I have verified and compiled pass by adding loong64 to debian/control 
file in my local env(Currently no pandoc related).

Attach the control patch.


Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_output.patch
Description: Binary data


Bug#1060123: knot: Please update libknot14.symbols.loong64

2024-01-05 Thread yalingfang

Source:  knot
Version: 1.4.0-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64

Dear Maintainer,

     The symbols error happens when build knot in Loongarch.

The error message is following:

dh_makeshlibs: error: failing due to earlier errors
make: *** [debian/rules:51: binary] Error 255

I have compiled and all cases passed  in my local env.

Attach the symbols patch.
Please add support for it. Thanks!
Any question, contact me!


libknot14.symbols.loong64.diff
Description: Binary data


Bug#1059963: mindthegap: Please add loong64 binary output for Loongarch

2024-01-04 Thread yalingfang

Source: mindthegap
Version:  3.107
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,
     Currently no loong64 binary output for mindthegap in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=mindthegap=sid

I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.


Attach the control patch.

And the mindthegap will be passed after the gatb-core updating the 
patch in the folllowing link:


https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1058714


Please add support for it. Thanks!
Any question, contact me!


add-loong64-binary-output-for-loongarch.patch
Description: Binary data


Bug#1059962: mozc: Please add loong64 binary output for Loongarch

2024-01-03 Thread yalingfang

Source:  mozc
Version: 2.28.4715.102+dfsg-2.2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,
     Currently no loong64 binary output for mozc in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=mozc=sid

I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.


Attach the control patch.

And The moze building needs update sigscheme's patch depended by 
libuim-dev firstly, for libuim-dev  needed during the moze's compiling.


The sigscheme's patch is https://github.com/uim/libgcroots/pull/6/commits.

Please add support for it. Thanks!

Any question, contact me!


add-loong64-binary-output.patch
Description: Binary data


Bug#1059960: flash-kernel: Please add loong64 binary output for Loongarch

2024-01-03 Thread yalingfang

Source: flash-kernel
Version: 3.107
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,
     Currently no loong64 binary output for flash-kernel in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=flash-kernel=sid

I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.

Attach the control patch.
Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_output_for_loongarch.patch
Description: Binary data


Bug#1059958: olive-editor: Please add loong64 binary output for Loongarch

2024-01-03 Thread yalingfang

Source: olive-editor
Version: 20221024+ds-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     Currently no loong64 binary output for olive-editor in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=olive-editor=sid


I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.


Attach the control patch.

And provide the debian bug for circle dependency between opencolorio and 
openimageio during compiling olive-editor。


https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1059837


Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_output.patch
Description: Binary data


Bug#1059837: opencolorio: Please help fix circle dependence in Loongarch between openimageio and opencolorio

2024-01-02 Thread yalingfang

Source: opencolorio
Version: 2.1.3+dfsg-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     Currently when I built opencolorio in Loongarch env, I  
found there is circle dependence between openimageio and opencolorio

The buildd link is following:

https://buildd.debian.org/status/package.php?p=opencolorio=sid

https://buildd.debian.org/status/package.php?p=openimageio=sid


But the initial version of opencolorio can build pass by using 
DEB_BUILD_PROFILE="pkg.opencolorio.noopenimageio" when dpkg-buildpackage 
running.


and then we  can  use this first binary output to compile 
the openimageio to fix the circle dependence.


I have verified and passed  in my local env.

Please help fix the issue for some other application waiting the 
opencolorio and openimageio binary.


Any question, contact me!



Bug#1059423: r-cran-lwgeom: Please add loong64 binary output for Loongarch

2023-12-25 Thread yalingfang

Source: r-cran-lwgeom
Version: 0.2-13-2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64

Dear Maintainer,
     Currently no loong64 binary output for r-cran-lwgeom in Loongarch env.

The buildd link is following:

https://buildd.debian.org/status/package.php?p=r-cran-lwgeom=sid

I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.


Attach the control patch.
Please add support for it. Thanks!
Any question, contact me!


add_loong64_output.patch
Description: Binary data


Bug#1059196: naev: Please add loong64 binary output

2023-12-20 Thread yalingfang

Source:  naev
Version: 0.8.2-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     Currently no loong64 binary output for naev in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=naev=sid


I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.

Attach the control patch.


Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_output.patch
Description: Binary data


Bug#1059096: metaeuk : Please add loong64 binary output for LoongArch

2023-12-20 Thread yalingfang

Source: metaeuk
Version: 6-a5d39d9+ds-3
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64



Dear Maintainer,


     Currently no loong64 binary output for metaeuk in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=metaeuk=sid


I have verified and compiled pass by adding loong64 to debian/control 
file in my local env.

Attach the control patch.

Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_ouput.patch
Description: Binary data


Bug#1059093: wlcs: Modfiy configure info for Loongarch64

2023-12-19 Thread yalingfang

Source:   wlcs
Version: 1.6.1-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

    When I compiled wlcs  in Loongarch env, error happened for some 
modules is not supported in loongarch64


The buildd link is following:

https://buildd.debian.org/status/fetch.php?pkg=wlcs=loong64=1.6.1-1=1700185593=0


I have verified and compiled pass by adding loong64 to debian/rules file 
in my local env.

Attach the rules's patch.
Please add support for it. Thanks!
Any question, contact me!


add_support_for_loongarch64.patch
Description: Binary data


Bug#1059077: memkind: Add loong64 binary output for Loongarch

2023-12-19 Thread yalingfang

Source:   memkind
Version: 1.14.0-3
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     Currently no loong64 binary output for memkind in Loongarch env.
The buildd link is following:

https://buildd.debian.org/status/package.php?p=memkind=sid


I have verified by Add loong64 to debian/control file, All test cases 
are passed in my local env.

Attach the control patch.

Please add support for it. Thanks!
Any question, contact me!


add_binary_output_for_loongarch.patch
Description: Binary data


Bug#1059075: lltsv: Please add loong64 binary output for Loongarch

2023-12-19 Thread yalingfang

Source: lltsv
Version: 0.7.0-2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64

Dear Maintainer,

     Currently no loong64 binary output for lltsv in Loongarch env.

The buildd link is following:

https://buildd.debian.org/status/package.php?p=lltsv=sid


I have verified and passed by Add loong64 to debian/control file in my 
local env.

Attach the control patch.

Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_output.patch
Description: Binary data


Bug#1059024: libcrcutil: Please add loong64 binary output for Loongarch

2023-12-19 Thread yalingfang

Source: libcrcutil
Version: 1.0-5.2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     Currently no loong64 binary output for libcrcutil in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=++libcrcutil%E2%80%8B=sid


I have verified by Add loong64 to debian/control file, All test cases 
are passed in my local env.

Attach the control patch.

Please add support for it. Thanks!
Any question, contact me!


add_loong64_binary_output_for_loongarch.patch
Description: Binary data


Bug#1059020: ettercap: Disable luajit for loong64

2023-12-19 Thread yalingfang

Source: ettercap
Version: 0.8.3.1-12
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     Currently there is no luajit for loongarch platform.

Maybe in a long time there is no loongarch support for luajit , 
because the patch is not received by luajit repo maintainer.


So we disabled the luajit conf in ettercap  workaround. We verified  and 
compiled pass in loongarch Platform.



Attach the ettercap's patch for loong64.

Please add support for it. Thanks!
Any question, contact me!


no_luajit_support.patch
Description: Binary data


Bug#1059000: mutter : Please add support for loong64

2023-12-19 Thread yalingfang

Source: mutter
Version: 44.7-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

     When I compiled the mutter in Loongarch platform, the mutter and 
gnome-settings-daemon depend each other.


I disabled some cases and used -d flags, the compiler passed, and then 
both mutter and gnome-settings-daemon compile pass.


Attach the mutter's patch for loong64.

Please add support for it. Thanks!
Any question, contact me!


disable_some_test_in_loong64.patch
Description: Binary data


Bug#1058989: appstream: Please add support for loong64

2023-12-18 Thread yalingfang

Source: appstream
Version: 1.0.1-1
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64




Dear Maintainer,


     Currently lack of some loong64 binary outputs for appstream in 
Loongarch platform.

Such as appstream-compose, libappstream-compose0 etc .

I have verified by Add loong64 to debian/control and rules file, All 
test cases are passed in my local env.

Attach the  patch.

Please add support for it. Thanks!
Any question, contact me!


add-support-for-loong64.patch
Description: Binary data


Bug#1058682: glusterfs: Please add support for loong64

2023-12-14 Thread yalingfang

Source: glusterfs
Version: 11.1-2
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,


     Currently no loong64 binary output for glusterfs in Loongarch env.
The buildd link is following:
https://buildd.debian.org/status/package.php?p=glusterfs=sid

I have verified by Add loong64 to debian/control file, All test cases 
are passed in my local env.

Attach the control patch.

Please add support for it. Thanks!


Any question, contact me!



add_loong64_support.patch
Description: Binary data


Bug#1058650: ext3grep: Please add support for loong64

2023-12-13 Thread yalingfang

Source: ext3grep
Version: 0.10.2-5
Severity: wishlist
Tags: patch
User: debian-loonga...@lists.debian.org
Usertags: loong64


Dear Maintainer,

 Currently no loong64 binary output for ext3grep in Loongarch env.

The buildd link is following:

https://buildd.debian.org/status/package.php?p=ext3grep=sid


I have verified by Add loong64 to debian/control file, It's passed in my 
local env.



Please add support for it. Thanks!

Any question, contact me!





Bug#1057637: mozjs102: Please enable jit default in LoongArch

2023-12-06 Thread yalingfang

Source: mozjs102
Version: 102.15.1-1
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64



  Dear maintainers,


        When compiling the package mozjs102 for loong64 in the Debian 
Package


Auto-Building environment , many js error happened, the whole log in in 
the following link:


https://buildd.debian.org/status/fetch.php?pkg=mozjs102=loong64=102.15.1-1=1700200988=0 



And now I added the patch in the 
https://phabricator.services.mozilla.com/D158397 to mozjs102, the 
package mozjs102 compiled pass and all cases passed.



Attached the patch, or you can get from 
https://phabricator.services.mozilla.com/D158397.


Any question, you can contact me.



Enable-jit-default.patch
Description: Binary data


Bug#1057633: gluegen2: Please add support for LoongArch

2023-12-06 Thread yalingfang

Source: gluegen2
Version: 2.5.0+dfsg-1
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64


   Dear maintainers,

        When compiling the package gluegen2 for loong64 in the Debian 
Package
Auto-Building environment , Error happened for lack of some LoongArch 
define, and the whole log is in following link:


https://buildd.debian.org/status/fetch.php?pkg=gluegen2=loong64=2.5.0%2Bdfsg-1=1694461876=0

I modified in my local env , compiled pass, and test  cases are  passed.

Attached my patch.  Any question, you can contact me!






add-support-for-loongarch.patch
Description: Binary data


Bug#1055145: varnish-modules: Please modify control file for LoongArch support

2023-11-01 Thread yalingfang

Package: varnish-modules

Version: 0.20.0-2
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

    When I compiled varnish-modules for loongarch architecture, no 
binary  for

LoongArch output.


We had modified control file for LoongArch and built success in my localenv.

The sample patch is following:

diff --git a/debian/control b/debian/control

index 53d6bb4..aae545b 100644
--- a/debian/control
+++ b/debian/control
@@ -15,7 +15,7 @@ Vcs-Git: 
https://salsa.debian.org/varnish-team/varnish-modules.git

 Homepage: https://github.com/varnish/varnish-modules

 Package: varnish-modules
-Architecture: amd64 arm64 i386 mips64el mipsel ppc64el s390x alpha hppa 
ia64 m68k powerpc ppc64 riscv64 sh4 x32
+Architecture: amd64 arm64 i386 loong64 mips64el mipsel ppc64el s390x 
alpha hppa ia64 m68k powerpc ppc64 riscv64 sh4 x32

 Depends: ${shlibs:Depends},
          ${misc:Depends},
          ${Varnish:ABI}



Any question you can contact me any time.

Thanks!


Modify_control_file_for_support_LoongArch.patch
Description: Binary data


Bug#1055135: vkd3d: Please modify control for Loongarch support

2023-11-01 Thread yalingfang


Package: vkd3d

Version: 1.2-15
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled vkd3d for loongarch architecture, no binary  for 
LoongArch output.



We had modified control file for LoongArch and built success in my localenv.

The sample patch is in the attachment.

Any question you can contact me any time.

Thanks!




Modify_control_for_LoongArch_support.patch
Description: Binary data


Bug#1054643: golang-honnef-go-tools: Add loong64 for test file

2023-10-27 Thread yalingfang

Package: golang-honnef-go-tools
Version:  2023.1.3-1
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

    When I compiled golang-honnef-go-tools for  for loong64 in the 
Debian Package,


and found case failed same 
as https://buildd.debian.org/status/logs.php?pkg=golang-honnef-go-tools=2023.1.3-1=loong64


.

We have added loongarch architecture support for golang-honnef-go-tools 
success in local env and submited the


patch to github. The patch  link 
is  https://github.com/dominikh/go-tools/pull/1459/commits/6e18a5cbabed6482bfaafd2759e06ca464e96e8b


or you can get from  the attachment .


   If you have any questions, you can contact me at any time.


add-loongarch.patch
Description: Binary data


Bug#1054575: jffi: Add support for Loongarch

2023-10-26 Thread yalingfang

Package: jffi
Version:  1.3.9+ds-6
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled jffi for  for loong64 in the Debian Package,

and found it should be added support for loongarch.

Now the patched had been merged in github and released in tag 1.3.10.

https://github.com/jnr/jffi/commit/f870ed046006dc90c33f1af338061f7a77bf51b5


We have added loongarch architecture support for jffi in local env. The 
patch


can be found in the attachment or got from github.

  If you have any questions, you can contact me at any time.


add-support-for-loongarch64.patch
Description: Binary data


Bug#1053828: liboqs: Add support for Loongarch64

2023-10-12 Thread yalingfang

Package: liboqs
Version:  0.8.0-1
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled liboqs for  for loong64 in the Debian Package,
 The error message is as follows:
CMake Error at CMakeLists.txt:93 (message):
  Unknown or unsupported processor: loongarch64.  Override by setting
  OQS_PERMIT_UNSUPPORTED_ARCHITECTURE=ON

We have added loongarch architecture support for liboqs, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.


--- liboqs-0.8.0.orig/CMakeLists.txt
+++ liboqs-0.8.0/CMakeLists.txt
@@ -61,6 +61,12 @@ elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "a
 if(${OQS_DIST_BUILD})
 set(OQS_DIST_ARM64_V8_BUILD ON)
 endif()
+elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "loong64|loongarch64")
+set(ARCH "loongarch64")
+set(ARCH_LOONGARCH64 ON)
+if(${OQS_DIST_BUILD})
+set(OQS_DIST_LOONGARCH64_BUILD ON)
+endif()
 elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "armel|armhf|armv7|arm32v7")
 set(ARCH "arm32v7")
 set(ARCH_ARM32v7 ON)


Bug#1053792: libapache2-mod-auth-cas: Update config.sub and config.guess from upstream to recognize the Loongarch

2023-10-11 Thread yalingfang

Package: libapache2-mod-auth-cas
Version:  1.2-1
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled libapache2-mod-auth-cas for  for loong64 in the 
Debian Package,

 The error message is as follows:


checking build system type... Invalid configuration 
`loongarch64-linux-gnu': machine `loongarch64' not recognized

configure: error: /bin/bash ./config.sub loongarch64-linux-gnu failed


The version of autosetup/config.{sub,guess} in the 
 libapache2-mod-auth-cas source package


are too old for the LoongArch architecture.

The LoongArch architecture has been supported in config upstream [1] and
autotools-dev source package [2].

Please consider update the outdated config.guess and config.sub to
recognize the LoongArch.

If you have any questions, you can contact me at any time.

Thanks!


[1]:https://git.savannah.gnu.org/cgit/config.git/commit/?id=20403c5701973a4cbd7e0b4bbeb627fcd424a0f1

[2]:https://packages.debian.org/bookworm/autotools-dev



Bug#1053778: dpkg: add loong64 to mask builtin feature list

2023-10-10 Thread yalingfang
Package: dpkg Version: 1.22.0 Severity: normal Tags: patch User: 
debian-de...@lists.debian.org Usertags: loongarch64 Dear maintainers,    
We need add loong64 to mask builtin feature list for pie flag wrong 
during compiling.


We have added loong64 for dpkg, the patch

can be found in the attachment. If you have any questions, you can 
contact me at any time. Thanks!


diff --git a/scripts/Dpkg/Vendor/Debian.pm b/scripts/Dpkg/Vendor/Debian.pm
index 1cc2393..0ac3ebe 100644
--- a/scripts/Dpkg/Vendor/Debian.pm
+++ b/scripts/Dpkg/Vendor/Debian.pm
@@ -184,6 +184,7 @@ sub set_build_features {
 i386
 kfreebsd-amd64
 kfreebsd-i386
+	loong64
 mips
 mips64
 mips64el


Bug#1051911: java-common: Please add support for loongarch64

2023-09-14 Thread yalingfang

Package: java-common

Version: 0.74
Severity: normal
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

  When I compiled jpathwatch for loongarch64 architecture, it reported 
java include patch error.


We have added loongarch64 architecture support for java-common , the patch
can be found in the attachment.

 If you have any questions, you can contact me at any time.

diff --git a/debian/java_defaults.mk b/debian/java_defaults.mk
index cc21070..565df9f 100644
--- a/debian/java_defaults.mk
+++ b/debian/java_defaults.mk
@@ -3,7 +3,7 @@
 
 java17_architectures = \
 		alpha amd64 arm64 armel armhf i386 \
-		ia64 m68k mipsel mips64el \
+		ia64 loong64 m68k mipsel mips64el \
 		powerpc ppc64 ppc64el \
 		riscv64 s390x sh4 sparc64 x32
 java11_architectures = $(java17_architectures) \
@@ -34,7 +34,7 @@ endif
 _java_host_cpu := $(if $(DEB_HOST_ARCH_CPU),$(DEB_HOST_ARCH_CPU),$(shell dpkg-architecture -qDEB_HOST_ARCH_CPU))
 jvm_archdir_map = \
 	alpha=alpha armel=arm armhf=arm arm64=aarch64 amd64=amd64 \
-	i386=i386 m68k=m68k mips=mips mipsel=mipsel mips64=mips64 mips64el=mips64el \
+	i386=i386 loong64=loongarch64 m68k=m68k mips=mips mipsel=mipsel mips64=mips64 mips64el=mips64el \
 	powerpc=ppc ppc64=ppc64 ppc64el=ppc64le riscv64=riscv64 \
 	sparc64=sparc64 sh4=sh s390x=s390x ia64=ia64 x32=x32
 


Bug#1051905: jpeg-xl: Please add support for Loongarch

2023-09-13 Thread yalingfang

Package: jpeg-xl

Version: 0.7.0-10
Severity: normal
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

  When I compiled jpeg-xl for loongarch architecture, it reported case 
fail for lack for depency app.


We have added loongarch architecture support for jpeg-xl , the patch
can be found in the attachment.

 If you have any questions, you can contact me at any time.
diff --git a/debian/control b/debian/control
index ca93aea..b3683cd 100644
--- a/debian/control
+++ b/debian/control
@@ -7,7 +7,7 @@ Standards-Version: 4.6.2
 Build-Depends: asciidoc-base,
cmake (>= 3.10),
debhelper (>= 11),
-   default-jdk [amd64 arm64 armel armhf i386 mips64el mipsel ppc64el s390x alpha ia64 m68k powerpc ppc64 riscv64 sh4 sparc64 x32],
+   default-jdk [amd64 arm64 armel armhf i386 loong64 mips64el mipsel ppc64el s390x alpha ia64 m68k powerpc ppc64 riscv64 sh4 sparc64 x32],
docbook-xml,
help2man,
libavif-dev (>= 0.10.1),
@@ -15,7 +15,7 @@ Build-Depends: asciidoc-base,
libgflags-dev,
libgif-dev (>= 5.1),
libgmock-dev ,
-   libgoogle-perftools-dev [amd64 arm64 armel armhf i386 mips64el mipsel ppc64el s390x kfreebsd-amd64 kfreebsd-i386 powerpc ppc64 riscv64],
+   libgoogle-perftools-dev [amd64 arm64 armel armhf i386 loong64 mips64el mipsel ppc64el s390x kfreebsd-amd64 kfreebsd-i386 powerpc ppc64 riscv64],
libgtest-dev ,
libhwy-dev (>= 1.0.2),
libjpeg-dev,
@@ -108,7 +108,7 @@ Description: JPEG XL Image Coding System - "JXL" (dev command line utility)
  This package installs the devtools command line utilities.
 
 Package: libjpegxl-java
-Architecture: amd64 arm64 armel armhf i386 mips64el mipsel ppc64el s390x alpha ia64 m68k powerpc ppc64 riscv64 sh4 sparc64 x32
+Architecture: amd64 arm64 armel armhf i386 loong64 mips64el mipsel ppc64el s390x alpha ia64 m68k powerpc ppc64 riscv64 sh4 sparc64 x32
 Section: java
 Depends: ${java:Depends}, ${misc:Depends}, ${shlibs:Depends}
 Suggests: java-virtual-machine
diff --git a/debian/rules b/debian/rules
index e364ac1..89456c2 100755
--- a/debian/rules
+++ b/debian/rules
@@ -3,14 +3,14 @@
 include /usr/share/dpkg/default.mk
 
 # keep same order as https://buildd.debian.org/status/package.php?p=google-perftools=sid
-TCMALLOC_ARCHS=amd64 arm64 armel armhf i386 mips64el mipsel ppc64el s390x kfreebsd-amd64 kfreebsd-i386 powerpc ppc64 riscv64
+TCMALLOC_ARCHS=amd64 arm64 armel armhf i386 loong64 mips64el mipsel ppc64el s390x kfreebsd-amd64 kfreebsd-i386 powerpc ppc64 riscv64
 ifeq ($(DEB_HOST_ARCH),$(filter $(DEB_HOST_ARCH),$(TCMALLOC_ARCHS)))
   ENABLE_TCMALLOC=ON
 else
   ENABLE_TCMALLOC=OFF
 endif
 
-JAVA_ARCHS=amd64 arm64 armel armhf i386 mips64el mipsel ppc64el s390x alpha ia64 m68k powerpc ppc64 riscv64 sh4 sparc64 x32
+JAVA_ARCHS=amd64 arm64 armel armhf i386 loong64 mips64el mipsel ppc64el s390x alpha ia64 m68k powerpc ppc64 riscv64 sh4 sparc64 x32
 ifeq ($(DEB_HOST_ARCH),$(filter $(DEB_HOST_ARCH),$(JAVA_ARCHS)))
   ENABLE_JNI=ON
 else


Bug#1051775: hardinfo: Please add support for hardinfo

2023-09-12 Thread yalingfang

Package: hardinfo
Version: 0.5.1+git20180227-2.1
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled hardinfo for loongarch architecture, the unsupport arch 
happened.

We have added loong64 check for hardinfo, the patch

can be found in the attachment.

or you can refer the patch https://github.com/lpereira/hardinfo/pull/631

 If you have any questions, you can contact me at any time.

Thanks!

Description: Add loongarch64 support
Signed-off-by: liuxiang 
Pull request link: https://github.com/lpereira/hardinfo/pull/631
Last-Update: 2023-09-12

--- hardinfo-0.5.1+git20180227.orig/CMakeLists.txt
+++ hardinfo-0.5.1+git20180227/CMakeLists.txt
@@ -50,6 +50,8 @@ elseif(${CMAKE_HOST_SYSTEM_PROCESSOR} MA
 	set(HARDINFO_ARCH "sh")
 elseif(${CMAKE_HOST_SYSTEM_PROCESSOR} MATCHES "(riscv|riscv32|riscv64)")
 	set(HARDINFO_ARCH "riscv")
+elseif(${CMAKE_HOST_SYSTEM_PROCESSOR} MATCHES "loongarch64")
+   set(HARDINFO_ARCH "loongarch64")
 else()
 	message(FATAL_ERROR "Unsupported architecture: ${CMAKE_HOST_SYSTEM_PROCESSOR}")
 endif()
--- /dev/null
+++ hardinfo-0.5.1+git20180227/includes/loongarch64/processor-platform.h
@@ -0,0 +1,28 @@
+/*
+ *HardInfo - Displays System Information
+ *Copyright (C) 2003-2006 Leandro A. F. Pereira 
+ *
+ *This program is free software; you can redistribute it and/or modify
+ *it under the terms of the GNU General Public License as published by
+ *the Free Software Foundation, version 2.
+ *
+ *This program is distributed in the hope that it will be useful,
+ *but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *GNU General Public License for more details.
+ *
+ *You should have received a copy of the GNU General Public License
+ *along with this program; if not, write to the Free Software
+ *Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+ */
+
+#ifndef __PROCESSOR_PLATFORM_H__
+#define __PROCESSOR_PLATFORM_H__
+
+struct _Processor {
+gchar *model_name;
+gchar *vendor_id;
+gfloat bogomips, cpu_mhz;
+};
+
+#endif /* __PROCESSOR_PLATFORM_H__ */
--- /dev/null
+++ hardinfo-0.5.1+git20180227/modules/devices/loongarch64/processor.c
@@ -0,0 +1,81 @@
+/*
+ *HardInfo - Displays System Information
+ *Copyright (C) 2003-2006 Leandro A. F. Pereira 
+ *
+ *This program is free software; you can redistribute it and/or modify
+ *it under the terms of the GNU General Public License as published by
+ *the Free Software Foundation, version 2.
+ *
+ *This program is distributed in the hope that it will be useful,
+ *but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *GNU General Public License for more details.
+ *
+ *You should have received a copy of the GNU General Public License
+ *along with this program; if not, write to the Free Software
+ *Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+ */
+
+#include "hardinfo.h"
+#include "devices.h"
+#include "cpu_util.h"
+
+GSList *
+processor_scan(void)
+{
+Processor *processor;
+FILE *cpuinfo;
+gchar buffer[128];
+
+cpuinfo = fopen(PROC_CPUINFO, "r");
+if (!cpuinfo)
+return NULL;
+
+processor = g_new0(Processor, 1);
+while (fgets(buffer, 128, cpuinfo)) {
+gchar **tmp = g_strsplit(buffer, ":", 2);
+
+if (tmp[0] && tmp[1]) {
+tmp[0] = g_strstrip(tmp[0]);
+tmp[1] = g_strstrip(tmp[1]);
+
+get_str("system type", processor->vendor_id);
+get_str("model name", processor->model_name);
+get_float("CPU MHz", processor->cpu_mhz);
+get_float("BogoMIPS", processor->bogomips);
+}
+g_strfreev(tmp);
+}
+
+fclose(cpuinfo);
+
+return g_slist_append(NULL, processor);
+}
+
+gchar *processor_name(GSList * processors) {
+return processor_name_default(processors);
+}
+
+gchar *processor_describe(GSList * processors) {
+return processor_describe_default(processors);
+}
+
+gchar *
+processor_get_info(GSList *processors)
+{
+Processor *processor = (Processor *)processors->data;
+
+return g_strdup_printf("[%s]\n"
+"%s=%s\n"
+"%s=%s\n"
+"%s=%.2f %s\n" /* frequency */
+"%s=%.2f\n"/* bogoMIPS */
+"%s=%s\n", /* byte order */
+_("Processor"),
+_("Model"), processor->model_name,
+_("System Type"), processor->vendor_id,
+_("Frequency"), processor->cpu_mhz, _("MHz"),
+_("BogoMIPS"), processor->bogomips,
+_("Byte Order"), byte_order_str()
+   );
+}


Bug#1051751: libopendbx: Please add support for new arch Loongarch

2023-09-12 Thread yalingfang
Package: libopendbx Version: 1.4.6-16 Severity: wishlist Tags: patch 
User: debian-de...@lists.debian.org Usertags: loongarch64 Dear 
maintainers,    When I compiled libopendbx for loongarch architecture, 
libopendbx symbols checked fail is happened.


We have added loong64 check for libopendbx symbols, the patch

can be found in the attachment. If you have any questions, you can 
contact me at any time. Thanks!


diff --git a/debian/libopendbx1.symbols b/debian/libopendbx1.symbols
index f385fe0..87505f7 100644
--- a/debian/libopendbx1.symbols
+++ b/debian/libopendbx1.symbols
@@ -53,11 +53,11 @@ libopendbxplus.so.1 libopendbx1 #MINVER#
  _ZN7OpenDBX15StmtSimple_ImplD0Ev@Base 1.4.6
  _ZN7OpenDBX15StmtSimple_ImplD1Ev@Base 1.4.6
  _ZN7OpenDBX15StmtSimple_ImplD2Ev@Base 1.4.6
- (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX3Lob4readEPvj@Base 1.4.6
- (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX3Lob4readEPvm@Base 1.4.6
+ (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX3Lob4readEPvj@Base 1.4.6
+ (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 loong64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX3Lob4readEPvm@Base 1.4.6
  _ZN7OpenDBX3Lob5closeEv@Base 1.4.6
- (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX3Lob5writeEPvj@Base 1.4.6
- (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX3Lob5writeEPvm@Base 1.4.6
+ (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX3Lob5writeEPvj@Base 1.4.6
+ (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 loong64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX3Lob5writeEPvm@Base 1.4.6
  _ZN7OpenDBX3LobC1EPNS_9Lob_IfaceE@Base 1.4.6
  _ZN7OpenDBX3LobC1ERKS0_@Base 1.4.6
  _ZN7OpenDBX3LobC2EPNS_9Lob_IfaceE@Base 1.4.6
@@ -113,11 +113,11 @@ libopendbxplus.so.1 libopendbx1 #MINVER#
  _ZN7OpenDBX6ResultD1Ev@Base 1.4.6
  _ZN7OpenDBX6ResultD2Ev@Base 1.4.6
  _ZN7OpenDBX6ResultaSERKS0_@Base 1.4.6
- (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX8Lob_Impl4readEPvj@Base 1.4.6
- (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX8Lob_Impl4readEPvm@Base 1.4.6
+ (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX8Lob_Impl4readEPvj@Base 1.4.6
+ (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 loong64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX8Lob_Impl4readEPvm@Base 1.4.6
  _ZN7OpenDBX8Lob_Impl5closeEv@Base 1.4.6
- (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX8Lob_Impl5writeEPvj@Base 1.4.6
- (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX8Lob_Impl5writeEPvm@Base 1.4.6
+ (arch=!alpha !amd64 !arm64 !ia64 !kfreebsd-amd64 !loong64 !mips64 !mips64el !ppc64 !ppc64el !riscv64 !s390 !s390x !sparc64)_ZN7OpenDBX8Lob_Impl5writeEPvj@Base 1.4.6
+ (arch=alpha amd64 arm64 ia64 kfreebsd-amd64 loong64 mips64 mips64el ppc64 ppc64el riscv64 s390 s390x sparc64)_ZN7OpenDBX8Lob_Impl5writeEPvm@Base 1.4.6
  _ZN7OpenDBX8Lob_ImplC1EP13odbx_result_tPKc@Base 1.4.6
  _ZN7OpenDBX8Lob_ImplC2EP13odbx_result_tPKc@Base 1.4.6
  _ZN7OpenDBX8Lob_ImplD0Ev@Base 1.4.6


Bug#1051750: libjpeg-turbo:Please add support for new arch Loongarch

2023-09-12 Thread yalingfang

Package: libjpeg-turbo
Version: 2.1.5-2
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled libjpeg-turbo for loongarch architecture, test case fail is 
happened during float prog cmp.

We have added loong64 check for libjpeg-turbo, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

Thanks!

diff --git a/debian/rules b/debian/rules
index 5905900..937c00c 100755
--- a/debian/rules
+++ b/debian/rules
@@ -11,7 +11,7 @@ include /usr/share/dpkg/default.mk
 ifneq (,$(filter $(DEB_HOST_ARCH), m68k))
   FLOAT_STORE=-ffloat-store
 endif
-ifneq (,$(filter $(DEB_HOST_ARCH), ia64 riscv64 s390x))
+ifneq (,$(filter $(DEB_HOST_ARCH), ia64 loong64 riscv64 s390x))
   FLOATTEST=-DFLOATTEST=fp-contract
 endif
 


Bug#1051307: kcov: Please add support for new arch Loongarch

2023-09-05 Thread yalingfang

Package: kcov

Version: 38+dfsg-1
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

  When I compiled kcov for loongarch architecture, it reported missing 
architecture support.


We have added loongarch architecture support for kcov, the patch

can be found in the attachment.

And the patch is merged in github 
https://github.com/SimonKagstrom/kcov/commit/02bc582371c5ff5f4b4781975c2c12f9744b4162


 If you have any questions, you can contact me at any time.


Description: Add loongarch64 support
Signed-off-by: chenfeiyang 
Pull request link: https://github.com/SimonKagstrom/kcov/pull/399
Last-Update: 2023-08-31

--- kcov-38+dfsg.orig/src/engines/ptrace.cc
+++ kcov-38+dfsg/src/engines/ptrace.cc
@@ -49,6 +49,12 @@ static unsigned long arch_setupBreakpoin
 	unsigned long shift = 8 * offs;
 
 	val = (old_data & ~(0xUL << shift)) | (0xd420UL << shift);
+#elif defined(__loongarch__)
+	unsigned long aligned_addr = getAligned(addr);
+	unsigned long offs = addr - aligned_addr;
+	unsigned long shift = 8 * offs;
+
+	val = (old_data & ~(0xUL << shift)) | (0x002a0004UL << shift); /* break 0x4 */
 #else
 # error Unsupported architecture
 #endif
--- kcov-38+dfsg.orig/src/engines/ptrace_linux.cc
+++ kcov-38+dfsg/src/engines/ptrace_linux.cc
@@ -3,7 +3,7 @@
 #include 
 #include 
 
-#if defined(__aarch64__)
+#if defined(__aarch64__) || defined(__loongarch__)
 #  include 
 #  include 
 #endif
@@ -20,6 +20,7 @@
 enum
 {
 	i386_EIP = 12, x86_64_RIP = 16, ppc_NIP = 32, arm_PC = 15, aarch64_PC = 32, // See Linux arch/arm64/include/asm/ptrace.h
+	loongarch_ERA = 33
 };
 
 static void arch_adjustPcAfterBreakpoint(unsigned long *regs);
@@ -40,7 +41,7 @@ static void arch_adjustPcAfterBreakpoint
 	regs[i386_EIP]--;
 #elif defined(__x86_64__)
 	regs[x86_64_RIP]--;
-#elif defined(__powerpc__) || defined(__arm__) || defined(__aarch64__)
+#elif defined(__powerpc__) || defined(__arm__) || defined(__aarch64__) ||defined(__loongarch__)
 	// Do nothing
 #else
 # error Unsupported architecture
@@ -61,6 +62,8 @@ static unsigned long arch_getPcFromRegs(
 	out = regs[aarch64_PC];
 #elif defined(__powerpc__)
 	out = regs[ppc_NIP];
+#elif defined(__loongarch__)
+	out = regs[loongarch_ERA];
 #else
 # error Unsupported architecture
 #endif
@@ -318,7 +321,7 @@ static unsigned long getPcFromRegs(unsig
 
 static long getRegs(pid_t pid, void *addr, void *regs, size_t len)
 {
-#if defined(__aarch64__)
+#if defined(__aarch64__) || defined(__loongarch__)
 	struct iovec iov =
 	{	regs, len};
 	return ptrace(PTRACE_GETREGSET, pid, (void *)NT_PRSTATUS, );
@@ -366,7 +369,7 @@ void ptrace_sys::pokeWord(pid_t pid, uns
 
 static long setRegs(pid_t pid, void *addr, void *regs, size_t len)
 {
-#if defined(__aarch64__)
+#if defined(__aarch64__) || defined(__loongarch__)
 	struct iovec iov =
 	{	regs, len};
 	return ptrace(PTRACE_SETREGSET, pid, (void *)NT_PRSTATUS, );
@@ -389,7 +392,7 @@ void ptrace_sys::singleStep(pid_t pid)
 void ptrace_sys::skipInstruction(pid_t pid)
 {
 	// Nop on x86, op on PowerPC/ARM
-#if defined(__powerpc__) || defined(__arm__) || defined(__aarch64__)
+#if defined(__powerpc__) || defined(__arm__) || defined(__aarch64__) || defined(__loongarch__)
 	unsigned long regs[1024];
 
 	getRegs(pid, NULL, regs, sizeof regs);
@@ -398,6 +401,8 @@ void ptrace_sys::skipInstruction(pid_t p
 	regs[ppc_NIP] += 4;
 # elif defined(__aarch64__)
 	regs[aarch64_PC] += 4;
+# elif defined(__loongarch__)
+	regs[loongarch_ERA] += 4;
 # else
 	regs[arm_PC] += 4;
 # endif
--- kcov-38+dfsg.orig/src/solib-parser/lib.c
+++ kcov-38+dfsg/src/solib-parser/lib.c
@@ -95,6 +95,8 @@ static void force_breakpoint(void)
 			".long 0xfedeffe7\n" /* undefined insn */
 #elif defined(__aarch64__)
 			".long 0xd420\n" /* From https://github.com/scottt/debugbreak */
+#elif defined(__loongarch__)
+			"break 0x4\n"
 #else
 # error Unsupported architecture
 #endif


Bug#1051306: cln: Please add support for new arch Loongarch

2023-09-05 Thread yalingfang


Package: cln
Version: 1.3.6-4
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

  When I compiled cln for loongarch architecture, it reported missing 
architecture support.

The error message is following:
../include/cln/object.h:32:4: error: #error "Define cl_word_alignment 
for your CPU!"

32 | #error "Define cl_word_alignment for your CPU!"

We have added loongarch architecture support for cln, the patch
can be found in the attachment.
And the patch is merged 
https://www.ginac.de/CLN/cln.git/?p=cln.git;a=shortlog.


 If you have any questions, you can contact me at any time.
--- cln-1.3.6.orig/include/cln/object.h
+++ cln-1.3.6/include/cln/object.h
@@ -25,7 +25,7 @@ namespace cln {
 #if defined(__i386__) || (defined(__mips__) && !defined(__LP64__)) || (defined(__sparc__) && !defined(__arch64__)) || defined(__hppa__) || defined(__arm__) || defined(__rs6000__) || defined(__m88k__) || defined(__convex__) || (defined(__s390__) && !defined(__s390x__)) || defined(__sh__) || (defined(__x86_64__) && defined(__ILP32__))
   #define cl_word_alignment  4
 #endif
-#if defined(__alpha__) || defined(__ia64__) || defined(__mips64__) || defined(__powerpc64__) || (defined(__sparc__) && defined(__arch64__)) || (defined(__x86_64__) && !defined(__ILP32__)) || defined(__s390x__) || defined(__aarch64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__)
+#if defined(__alpha__) || defined(__ia64__) || defined(__mips64__) || defined(__powerpc64__) || (defined(__sparc__) && defined(__arch64__)) || (defined(__x86_64__) && !defined(__ILP32__)) || defined(__s390x__) || defined(__aarch64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__) || defined(__loongarch_lp64)
   #define cl_word_alignment  8
 #endif
 #if !defined(cl_word_alignment)
--- cln-1.3.6.orig/include/cln/types.h
+++ cln-1.3.6/include/cln/types.h
@@ -51,7 +51,7 @@
 #undef HAVE_LONGLONG
#endif
   #endif
-  #if defined(HAVE_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__mips64__) || defined(__powerpc64__) || defined(__s390x__) || (defined(__sparc__) && defined(__arch64__)) || (defined(__x86_64__) || defined(_M_AMD64)) || defined(__aarch64__) || (defined(__riscv) && __riscv_xlen == 64)) || defined(__e2k__)
+  #if defined(HAVE_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__mips64__) || defined(__powerpc64__) || defined(__s390x__) || (defined(__sparc__) && defined(__arch64__)) || (defined(__x86_64__) || defined(_M_AMD64)) || defined(__aarch64__) || (defined(__riscv) && __riscv_xlen == 64)) || defined(__e2k__) || defined(__loongarch_lp64)
 // 64 bit registers in hardware
 #define HAVE_FAST_LONGLONG
   #endif
@@ -79,7 +79,7 @@
 
 // Integer type used for counters.
 // Constraint: sizeof(uintC) >= sizeof(uintL)
-  #if (defined(HAVE_FAST_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__powerpc64__) || defined(__s390x__) || (defined(__sparc__) && defined(__arch64__)) || defined(__x86_64__) || defined(__aarch64__) || defined(__mips64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__)))
+  #if (defined(HAVE_FAST_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__powerpc64__) || defined(__s390x__) || (defined(__sparc__) && defined(__arch64__)) || defined(__x86_64__) || defined(__aarch64__) || defined(__mips64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__) || defined(__loongarch_lp64)))
 #define intCsize long_bitsize
 typedef long   sintC;
 typedef unsigned long  uintC;
@@ -91,7 +91,7 @@
 
 // Integer type used for lfloat exponents.
 // Constraint: sizeof(uintE) >= sizeof(uintC)
-  #if (defined(HAVE_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__powerpc64__) || defined(__s390x__) || (defined(__sparc__) && defined(__arch64__)) || defined(__x86_64__) || defined(__i386__) || defined(__mips__) || defined(__rs6000__) || defined(__aarch64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__)))
+  #if (defined(HAVE_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__powerpc64__) || defined(__s390x__) || (defined(__sparc__) && defined(__arch64__)) || defined(__x86_64__) || defined(__i386__) || defined(__mips__) || defined(__rs6000__) || defined(__aarch64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__) || defined(__loongarch_lp64)))
 #define intEsize 64
 typedef sint64  sintE;
 typedef uint64  uintE;
@@ -132,7 +132,7 @@
 typedef int sintD;
 typedef unsigned int uintD;
   #else  // we are not using GMP, so just guess something reasonable
-#if (defined(HAVE_FAST_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__powerpc64__) || (defined(__sparc__) && defined(__arch64__)) || defined(__s390x__) || defined(__x86_64__) || defined(__aarch64__) || defined(__mips64__) || (defined(__riscv) && __riscv_xlen == 64) || defined(__e2k__)))
+#if 

Bug#1050857: fweb: Please modify rules file for texinfo upgrade

2023-08-30 Thread yalingfang

Package: fweb
Version: 1.62-14
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled 1.62-14 for loongarch architecture. Currently the texinfo 
upgrade to 7.*.
The folder name is changed from fweb to fweb_html by using makeinfo --html 
fweb.texi, so the rules should be modified after texinfo upgrade.

We have added sample patch and built success in my localenv.

The sample is following:
diff --git a/debian/rules b/debian/rules
index d83dad5..0b8018b 100755
--- a/debian/rules
+++ b/debian/rules
@@ -64,7 +64,7 @@ clean:
 
-rm -f Web/idxmerge Web/idxmerge.c Web/custom.h Web/config.h \

Manual/fweb.info* Manual/fweb*.html
-   rm -rf Manual/fweb/
+   rm -rf Manual/fweb_html/
rm -f Web/fweave.mds Web/fweave.ndx
dh_clean
 
@@ -88,7 +88,7 @@ install: build

mandir=${mandir}/man1 \
install
 # documentation
-   ${installdoc} Manual/fweb/* ${htmldocdir}/
+   ${installdoc} Manual/fweb_html/* ${htmldocdir}/
${installdoc} Manual/fweb.texi ${docdir}/
${installdoc} debian/idxmerge.1 ${mandir}/man1/
ln -s fweb.1.gz ${mandir}/man1/fweave.1.gz



 If you have any questions, you can contact me at any time.



Bug#1050846: libvhdi: Please add support for new arch Loongarch

2023-08-30 Thread yalingfang

Package: libvhdi
Version: 20210425-1
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled libvhdi for loongarch architecture, test case fail is 
happened during memory check.

We have added loongarch architecture support for libvhdi, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

--- libvhdi-20210425.orig/tests/vhdi_test_memory.h
+++ libvhdi-20210425/tests/vhdi_test_memory.h
@@ -28,7 +28,7 @@
 extern "C" {
 #endif
 
-#if defined( HAVE_GNU_DL_DLSYM ) && defined( __GNUC__ ) && !defined( LIBVHDI_DLL_IMPORT ) && !defined( __aarch64__ ) && !defined( __alpha__ ) && !defined( __arm__ ) && !defined( __clang__ ) && !defined( __CYGWIN__ ) && !defined( __hppa__ ) && !defined( __mips__ ) && !defined( __powerpc__ ) && !defined( __ppc64__ ) && !defined( __ppc64le__ ) && !defined( __riscv ) && !defined( __s390x__ ) && !defined( __sparc__ ) && !defined( HAVE_ASAN )
+#if defined( HAVE_GNU_DL_DLSYM ) && defined( __GNUC__ ) && !defined( LIBVHDI_DLL_IMPORT ) && !defined( __aarch64__ ) && !defined( __alpha__ ) && !defined( __arm__ ) && !defined( __clang__ ) && !defined( __CYGWIN__ ) && !defined( __hppa__ ) && !defined(__loongarch__) && !defined( __mips__ ) && !defined( __powerpc__ ) && !defined( __ppc64__ ) && !defined( __ppc64le__ ) && !defined( __riscv ) && !defined( __s390x__ ) && !defined( __sparc__ ) && !defined( HAVE_ASAN )
 #define HAVE_VHDI_TEST_MEMORY		1
 #endif
 


Bug#1050844: xutils-dev: Please add support for new arch Loongarch

2023-08-29 Thread yalingfang

Package: xutils-dev
Version: 7.7+6.1
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled kdrill for loongarch architecture, the error message is 
happened for lacking of loongarch machine defined in xutils-dev.

We have added loongarch architecture support for xutils-dev, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

diff --git a/xorg-cf-files/Imake.cf b/xorg-cf-files/Imake.cf
index e2e4f1b..164e47f 100644
--- a/xorg-cf-files/Imake.cf
+++ b/xorg-cf-files/Imake.cf
@@ -1037,6 +1037,18 @@ XCOMM Keep cpp from replacing path elements containing i486/i586/i686
 #   define AArch64Architecture
 #   undef __aarch64__
 # endif
+# if defined(__loongarch__)
+#   undef __loongarch__
+#   if __loongarch_grlen == 64
+# undef __loongarch_grlen
+# undef __loongarch_lp64
+# define LoongArch64Architecture
+#   endif
+#   if __loongarch_grlen == 32
+# undef __loongarch_grlen
+# define LoongArch32Architecture
+#   endif
+# endif
 # if defined(__riscv) && (__riscv_xlen == 64)
 #   define RISCV64Architecture
 #   /* undef __riscv */
diff --git a/xorg-cf-files/linux.cf b/xorg-cf-files/linux.cf
index fb5924d..6209639 100644
--- a/xorg-cf-files/linux.cf
+++ b/xorg-cf-files/linux.cf
@@ -1117,6 +1117,25 @@ InstallNamedTargetNoClobber(install,file.ad,$(INSTAPPFLAGS),$(XAPPLOADDIR),class
 # define ServerExtraDefines-DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
 #endif /* AArch64Architecture */
 
+#ifdef LoongArch64Architecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags -O2 GccAliasingArgs
+# endif
+# define LinuxMachineDefines	-D__loongarch__ -D__loongarch_grlen=64 -D__loongarch_lp64
+# define ServerOSDefines	XFree86ServerOSDefines -DDDXTIME
+# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
+#endif /* LoongArch64Architecture */
+
+#ifdef LoongArch32Architecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags -O2 GccAliasingArgs
+# endif
+# define LinuxMachineDefines	-D__loongarch__ -D__loongarch_grlen=32
+# define ServerOSDefines	XFree86ServerOSDefines -DDDXTIME
+# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines
+#endif /* LoongArch32Architecture */
+
+
 #ifdef RISCV64Architecture
 # ifndef OptimizedCDebugFlags
 #  define OptimizedCDebugFlags DefaultGcc2RISCV64Opt DefaultGcc2OptimizeOpt GccAliasingArgs


Bug#1050764: scm: Please add support for new arch Loongarch

2023-08-28 Thread yalingfang

Package: scm
Version: 5f3-4
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled scm for loongarch architecture, it reported
missing architecture support.

We have added loongarch architecture support for scm, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

--- scm-5f3.orig/scmfig.h
+++ scm-5f3/scmfig.h
@@ -284,6 +284,10 @@ rgx.c	init_rgx();	regcomp and regexec. *
 # define SHORT_INT
 # define CDR_DOUBLES
 #endif
+#ifdef __loongarch__
+# define SHORT_INT
+# define CDR_DOUBLES
+#endif
 #ifdef MSDOS			/* Microsoft C 5.10 and 6.00A */
 # ifndef GO32
 #  define SHORT_INT


Bug#1050763: pvm: Please add support for new arch Loongarch

2023-08-28 Thread yalingfang

Package: pvm
Version: 3.4.6-5
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled pvm for loongarch architecture, it reported
missing architecture support.

We have added loongarch architecture support for pvm, the patch and the 
getpvmarch change sample file


can be found in the attachment.
 The sample in getpvmarch is following:
loong64)
echo LINUXLOONGARCH
;;


 If you have any questions, you can contact me at any time.

--- /dev/null
+++ pvm-3.4.6/conf/LINUXLOONGARCH.def
@@ -0,0 +1,10 @@
+ARCHCFLAGS =   -DSYSVSIGNAL -DNOWAIT3 -DRSHCOMMAND=\"/usr/bin/rsh\" \
+   -DNEEDENDIAN -DFDSETNOTSTRUCT -DHASERRORVARS \
+   -DCTIMEISTIMET -DSYSERRISCONST -DHASREADLINE
+ARCHDLIB   =
+ARCHDOBJ   =
+ARCHLIB=   -lreadline
+HASRANLIB  =   t
+AR =   ar
+PVM_ARCH   =   LINUXLOONGARCH
+MAKE   =   make
--- /dev/null
+++ pvm-3.4.6/conf/LINUXLOONGARCH.m4
@@ -0,0 +1,19 @@
+divert(-1)
+undefine(`len')
+#
+# append an underscore to FORTRAN function names
+#
+define(`FUNCTION',`$1_')
+#
+# FORTRAN character strings are passed as follows:
+# a pointer to the base of the string is passed in the normal
+# argument list, and the length is passed by value as an extra
+# argument, after all of the other arguments.
+#
+define(`ARGS',`($1`'undivert(1))')
+define(`SAVE',`divert(1)$1`'divert(0)')
+define(`STRING_ARG',`$1_ptr`'SAVE(`, $1_len')')
+define(`STRING_ARG_DECL',`char * $1_ptr; int $1_len')
+define(`STRING_LEN',`$1_len')
+define(`STRING_PTR',`$1_ptr')
+divert(0)
#! /bin/sh

eval `dpkg-architecture`

case $DEB_HOST_ARCH_CPU in
i[36]86)
echo LINUX
;;
sparc*)
echo LINUXSPARC
;;
alpha)
echo LINUXALPHA
;;
m68k)
echo LINUXATARI
;;
amd64)
echo LINUX64
;;
ia64)
echo LINUX64
;;
ppc64|ppc64el)
echo LINUX64
;;
hppa)
echo LINUXHPPA
;;
mips*)
echo LINUXMIPS
;;
s390)
echo LINUXS390
;;
s390x)
echo LINUXS390
;;
powerpc)
echo LINUXPPC
;;
arm)
echo LINUXARM
;;
arm64)
echo LINUX64
;;
sh4)
echo LINUXSH
;;
riscv64)
echo LINUXRISCV
;;
loong64)
echo LINUXLOONGARCH
;;
*)
echo 'Unknown architecture!' 1>&2
exit 1;
esac



Bug#1050486: netw-ib-ox-ag: Please add support for new arch Loongarch64

2023-08-25 Thread yalingfang

Package: netw-ib-ox-ag
Version: 5.39.0-1.5
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled netw-ib-ox-ag for loongarch architecture, it reported
missing architecture support.
   The error message is following:

System architecture selection
Error: Could not guess NETWIBDEF_SYSARCH.
Edit genemake to set NETWIBDEF_SYSARCH, and rerun genemake.
Please contact Laurent to permanently solve this problem.
make: *** [debian/rules:30: build-stamp] Error 1

We have added loongarch architecture support for netw-ib-ox-ag, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

--- netw-ib-ox-ag-5.39.0.orig/src/netwib-src/src/genemake
+++ netw-ib-ox-ag-5.39.0/src/netwib-src/src/genemake
@@ -130,6 +130,9 @@ case $unamem in
   "riscv64" )
 NETWIBDEF_SYSARCH="riscv64"
 ;;
+  "loongarch64" )
+NETWIBDEF_SYSARCH="loongarch64"
+;;
   * )
 echo "Error: Could not guess NETWIBDEF_SYSARCH.";
 echo "Edit genemake to set NETWIBDEF_SYSARCH, and rerun genemake.";


Bug#1050485: nx-libs: Please add support for new arch Loongarch64

2023-08-25 Thread yalingfang

Package: nx-libs
Version: 2:3.5.99.26-5
Severity: wishlist
Tags: patch
User:debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled nx-libs for loongarch architecture, it reported
missing architecture support.

We have added loongarch architecture support for nx-libs, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

--- nx-libs-3.5.99.26.orig/nx-X11/config/cf/Imake.cf
+++ nx-libs-3.5.99.26/nx-X11/config/cf/Imake.cf
@@ -883,6 +883,18 @@ XCOMM Keep cpp from replacing path eleme
 #   define Riscv64Architecture
 #  endif
 # endif
+# if defined(__loongarch__)
+#   undef __loongarch__
+#   if __loongarch_grlen == 64
+# undef __loongarch_grlen
+# undef __loongarch_lp64
+# define LoongArch64Architecture
+#   endif
+#   if __loongarch_grlen == 32
+# undef __loongarch_grlen
+# define LoongArch32Architecture
+#   endif
+# endif
 # ifdef sparc
 #  define SparcArchitecture
 #  undef sparc
--- nx-libs-3.5.99.26.orig/nx-X11/config/cf/Imake.tmpl
+++ nx-libs-3.5.99.26/nx-X11/config/cf/Imake.tmpl
@@ -517,6 +517,8 @@ XCOMM the platform-specific parameters -
 #define ByteOrder		X_LITTLE_ENDIAN
 #elif defined(SuperHebArchitecture)
 #define ByteOrder		X_BIG_ENDIAN
+#elif defined(LoongArch64Architecture) || defined(LoongArch32Architecture)
+#define ByteOrder   X_LITTLE_ENDIAN
 #endif
 #endif /* ByteOrder */
 X_BYTE_ORDER = ByteOrder
--- nx-libs-3.5.99.26.orig/nx-X11/config/cf/linux.cf
+++ nx-libs-3.5.99.26/nx-X11/config/cf/linux.cf
@@ -792,6 +792,24 @@ XCOMM binutils:	(LinuxBinUtilsMajorVersi
 # define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
 #endif /* Riscv64Achitecture */
 
+#ifdef LoongArch64Architecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags -O2 GccAliasingArgs
+# endif
+# define LinuxMachineDefines	-D__loongarch__ -D__loongarch_grlen=64 -D__loongarch_lp64
+# define ServerOSDefines	XFree86ServerOSDefines
+# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
+#endif /* LoongArch64Architecture */
+
+#ifdef LoongArch32Architecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags -O2 GccAliasingArgs
+# endif
+# define LinuxMachineDefines	-D__loongarch__ -D__loongarch_grlen=32
+# define ServerOSDefines	XFree86ServerOSDefines
+# define ServerExtraDefines	-DGCCUSESGAS XFree86ServerDefines
+#endif /* LoongArch32Architecture */
+
 #ifdef s390Architecture
 # ifndef OptimizedCDebugFlags
 #  define OptimizedCDebugFlags	-O2 -fomit-frame-pointer GccAliasingArgs


Bug#1050419: openni: Please add support for arch Loongarch64

2023-08-24 Thread yalingfang

Package: openni
Version: 1.5.4.0+dfsg-6
Severity: wishlist
Tags: patch
User: debian-de...@lists.debian.org
Usertags: loongarch64

Dear maintainers,

   When I compiled openni for loongarch architecture, it reported
missing architecture support.
   The error message is following:

cd Platform/Linux/CreateRedist && ./RedistMaker
Unknown platform: loongarch64
make[1]: *** [debian/rules:7: override_dh_auto_build] Error 1


We have added loongarch architecture support for openni, the patch

can be found in the attachment.

If you have any questions, you can contact me at any time.

Index: openni-1.5.4.0+dfsg/Include/Linux-Loongarch64/XnPlatformLinux-Loongarch64.h
===
--- /dev/null
+++ openni-1.5.4.0+dfsg/Include/Linux-Loongarch64/XnPlatformLinux-Loongarch64.h
@@ -0,0 +1,39 @@
+/
+*   *
+*  OpenNI 1.x Alpha *
+*  Copyright (C) 2011 PrimeSense Ltd.   *
+*   *
+*  This file is part of OpenNI. *
+*   *
+*  OpenNI is free software: you can redistribute it and/or modify   *
+*  it under the terms of the GNU Lesser General Public License as published *
+*  by the Free Software Foundation, either version 3 of the License, or *
+*  (at your option) any later version.  *
+*   *
+*  OpenNI is distributed in the hope that it will be useful,*
+*  but WITHOUT ANY WARRANTY; without even the implied warranty of   *
+*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+*  GNU Lesser General Public License for more details.  *
+*   *
+*  You should have received a copy of the GNU Lesser General Public License *
+*  along with OpenNI. If not, see .   *
+*   *
+/
+#ifndef _XN_PLATFORM_LINUX_LOONGARCH64_H_
+#define _XN_PLATFORM_LINUX_LOONGARCH64_H_
+
+// Start with Linux-x86, and override what's different
+#include "../Linux-x86/XnPlatformLinux-x86.h"
+
+//---
+// Platform Basic Definition
+//---
+#undef XN_PLATFORM
+#undef XN_PLATFORM_STRING
+#undef XN_PLATFORM_ENDIAN_TYPE
+#define XN_PLATFORM XN_PLATFORM_LINUX_LOONGARCH64
+#define XN_PLATFORM_STRING "Linux-Loongarch64"
+
+#define XN_PLATFORM_ENDIAN_TYPE XN_PLATFORM_IS_LITTLE_ENDIAN
+
+#endif //_XN_PLATFORM_LINUX_LOONGARCH64_H_
Index: openni-1.5.4.0+dfsg/Include/XnOS.h
===
--- openni-1.5.4.0+dfsg.orig/Include/XnOS.h
+++ openni-1.5.4.0+dfsg/Include/XnOS.h
@@ -44,7 +44,7 @@
 //---
 #if (XN_PLATFORM == XN_PLATFORM_WIN32)
 	#include "Win32/XnOSWin32.h"
-#elif (XN_PLATFORM == XN_PLATFORM_LINUX_X86 || XN_PLATFORM == XN_PLATFORM_LINUX_ARM || XN_PLATFORM == XN_PLATFORM_LINUX_AARCH64 || XN_PLATFORM == XN_PLATFORM_MACOSX || XN_PLATFORM == XN_PLATFORM_ANDROID_ARM || XN_PLATFORM == XN_PLATFORM_LINUX_POWERPC || XN_PLATFORM == XN_PLATFORM_LINUX_MIPS || XN_PLATFORM == XN_PLATFORM_LINUX_RISCV64)
+#elif (XN_PLATFORM == XN_PLATFORM_LINUX_X86 || XN_PLATFORM == XN_PLATFORM_LINUX_ARM || XN_PLATFORM == XN_PLATFORM_LINUX_AARCH64 || XN_PLATFORM == XN_PLATFORM_MACOSX || XN_PLATFORM == XN_PLATFORM_ANDROID_ARM || XN_PLATFORM == XN_PLATFORM_LINUX_POWERPC || XN_PLATFORM == XN_PLATFORM_LINUX_MIPS || XN_PLATFORM == XN_PLATFORM_LINUX_RISCV64 || XN_PLATFORM == XN_PLATFORM_LINUX_LOONGARCH64)
 	#include "Linux-x86/XnOSLinux-x86.h"
 #elif defined(_ARC)
 	#include "ARC/XnOSARC.h"
Index: openni-1.5.4.0+dfsg/Include/XnPlatform.h
===
--- openni-1.5.4.0+dfsg.orig/Include/XnPlatform.h
+++ openni-1.5.4.0+dfsg/Include/XnPlatform.h
@@ -39,6 +39,7 @@
 #define XN_PLATFORM_LINUX_AARCH64 11
 #define XN_PLATFORM_LINUX_MIPS 12
 #define XN_PLATFORM_LINUX_RISCV64 13
+#define XN_PLATFORM_LINUX_LOONGARCH64 14
 
 #define XN_PLATFORM_IS_LITTLE_ENDIAN 1
 #define XN_PLATFORM_IS_BIG_ENDIAN2
@@ -78,6 +79,8 @@
 	#include "Linux-Mips/XnPlatformLinux-Mips.h"
 #elif (__linux__ && (__riscv && __riscv_xlen == 64))
 	#include "Linux-Riscv64/XnPlatformLinux-Riscv64.h"
+#elif