Package: flexpart
Version: 9.02-27
Severity: important
Tags: ftbfs patch
User: [email protected]
Usertags: riscv64
X-Debbugs-Cc: [email protected]

Dear Maintainer,

Now flexpart has one FTBFS issue on riscv64 like:

```
...
gfortran `LC_ALL=C ls *.o` -o flexpart.gfs -Wl,-z,relro -O2 
-I/usr/lib/riscv64-linux-gnu/fortran/gfortran-mod-16 
-L/usr/lib/riscv64-linux-gnu/fortran/gnu -O2 -fdefault-real-8 
-fconvert=little-endian -frecord-marker=4 -I/usr/include -L/usr/lib 
-Wl,--as-needed  -leccodes_f90 -leccodes -lm
convmix_gfs.o: in function `convmix_':
convmix_gfs.f90:(.text+0xdc): relocation truncated to fit: R_RISCV_PCREL_HI20 
against `igrid.1'
getfields.o: in function `getfields_':
getfields.f90:(.text+0x1f4): relocation truncated to fit: R_RISCV_PCREL_HI20 
against `wwh.1'
gridcheck_gfs.o: in function `gridcheck_':
gridcheck_gfs.f90:(.text+0x5e6): relocation truncated to fit: 
R_RISCV_PCREL_HI20 against `zsec4.0'
gridcheck_nests.o: in function `gridcheck_nests_':
gridcheck_nests.f90:(.text+0x450): relocation truncated to fit: 
R_RISCV_PCREL_HI20 against `zsec4.0'
init_domainfill.o: in function `init_domainfill_':
init_domainfill.f90:(.text+0x356): relocation truncated to fit: 
R_RISCV_PCREL_HI20 against `colmass.1'
partoutput_short.o: in function `partoutput_short_':
partoutput_short.f90:(.text+0x2ac): relocation truncated to fit: 
R_RISCV_PCREL_HI20 against `idump.1'
plumetraj.o: in function `plumetraj_':
plumetraj.f90:(.text+0x210): relocation truncated to fit: R_RISCV_PCREL_HI20 
against `yl.1'
random.o: in function `ran3_':
random.f90:(.text+0x2): relocation truncated to fit: R_RISCV_PCREL_HI20 against 
`.LANCHOR0'
readavailable.o: in function `readavailable_':
readavailable.f90:(.text+0x208): relocation truncated to fit: 
R_RISCV_PCREL_HI20 against `wfname1.2'
readlanduse.o: in function `readlanduse_':
readlanduse.f90:(.text+0xe0): relocation truncated to fit: R_RISCV_PCREL_HI20 
against `ilr_buffer.0'
readwind_gfs.o: in function `readwind_':

```

I follow the tip of other architectures then the package can
be built on riscv64.

Could we have a try on it? Please let me know any issue.

-- 
Regards,
--
  Bo YU

diff -Nru flexpart-9.02/debian/changelog flexpart-9.02/debian/changelog
--- flexpart-9.02/debian/changelog      2025-11-02 17:53:20.000000000 +0800
+++ flexpart-9.02/debian/changelog      2025-11-04 09:12:08.000000000 +0800
@@ -1,3 +1,10 @@
+flexpart (9.02-27.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTBFS on riscv64. Closes: #-1
+
+ -- Bo YU <[email protected]>  Tue, 04 Nov 2025 09:12:08 +0800
+
 flexpart (9.02-27) unstable; urgency=medium
 
   * Use dh-fortran-mod to get default fmoddir, flibdrir. Closes: #1119734
diff -Nru flexpart-9.02/debian/rules flexpart-9.02/debian/rules
--- flexpart-9.02/debian/rules  2025-11-02 17:52:40.000000000 +0800
+++ flexpart-9.02/debian/rules  2025-11-03 20:36:45.000000000 +0800
@@ -20,6 +20,9 @@
 ifeq ($(CPU), ppc64el)
   export FCFLAGS:= $(FCFLAGS) -mcmodel=large
 endif
+ifeq ($(CPU), riscv64)
+  export FCFLAGS:= $(FCFLAGS) -mcmodel=large -fno-pie
+endif
 
 LC_ALL=C
 export LC_ALL

Attachment: signature.asc
Description: PGP signature

Reply via email to