diff -pruN 6.2.0-8/debian/changelog 6.2.0-8ubuntu2/debian/changelog
--- 6.2.0-8/debian/changelog	2014-07-04 21:25:10.000000000 +0000
+++ 6.2.0-8ubuntu2/debian/changelog	2018-04-03 12:40:32.000000000 +0000
@@ -1,3 +1,16 @@
+qfits (6.2.0-8ubuntu2) bionic; urgency=high
+
+  * No change rebuild to pick up -fPIE compiler default
+
+ -- Balint Reczey <rbalint@ubuntu.com>  Tue, 03 Apr 2018 12:40:32 +0000
+
+qfits (6.2.0-8ubuntu1) xenial; urgency=medium
+
+  * debian/patches/largefile.patch:
+    fix overflows when loading files larger than 2gb in size
+
+ -- Julian Taylor <jtaylor@ubuntu.com>  Mon, 18 Apr 2016 21:47:53 +0200
+
 qfits (6.2.0-8) unstable; urgency=medium
 
   * debian/control: update homepage to the new location (closes: #753688).
diff -pruN 6.2.0-8/debian/control 6.2.0-8ubuntu2/debian/control
--- 6.2.0-8/debian/control	2014-07-04 21:24:48.000000000 +0000
+++ 6.2.0-8ubuntu2/debian/control	2016-04-18 19:49:18.000000000 +0000
@@ -1,7 +1,8 @@
 Source: qfits
 Section: libs
 Priority: optional
-Maintainer: Aurelien Jarno <aurel32@debian.org>
+Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
+XSBC-Original-Maintainer: Aurelien Jarno <aurel32@debian.org>
 Build-Depends: debhelper (>= 9), dh-autoreconf
 Standards-Version: 3.9.5
 Homepage: http://www.eso.org/sci/software/eclipse/qfits/
diff -pruN 6.2.0-8/debian/patches/largefile.patch 6.2.0-8ubuntu2/debian/patches/largefile.patch
--- 6.2.0-8/debian/patches/largefile.patch	1970-01-01 00:00:00.000000000 +0000
+++ 6.2.0-8ubuntu2/debian/patches/largefile.patch	2016-04-18 19:47:24.000000000 +0000
@@ -0,0 +1,45 @@
+Index: qfits-6.2.0/main/dfits.c
+===================================================================
+--- qfits-6.2.0.orig/main/dfits.c
++++ qfits-6.2.0/main/dfits.c
+@@ -192,7 +192,8 @@ int dump_fits_filter(FILE * in, int xtnu
+     int            n_xt ;
+     char        buf[LGTH+2];
+     int            err ;
+-    int         data_bytes, naxis ;
++    int         naxis ;
++    off_t       data_bytes ;
+     char    *   read_val ;
+     int         skip_blocks ;
+     int         seeked ;
+@@ -291,7 +292,7 @@ int dump_fits_filter(FILE * in, int xtnu
+             /* Skip as many blocks as there are declared pixels */
+             skip_blocks = data_bytes/BLOCK_SIZE ;
+             if ((data_bytes % BLOCK_SIZE)!=0) skip_blocks ++ ;
+-            seeked = fseek(in, skip_blocks*BLOCK_SIZE, SEEK_CUR);
++            seeked = fseeko(in, (off_t)skip_blocks*BLOCK_SIZE, SEEK_CUR);
+             if (seeked<0) return -1 ;
+         }
+ 
+Index: qfits-6.2.0/src/qfits_cache.c
+===================================================================
+--- qfits-6.2.0.orig/src/qfits_cache.c
++++ qfits-6.2.0/src/qfits_cache.c
+@@ -335,7 +335,7 @@ static int qfits_cache_add(const char *
+     char    *    read_val ;
+     int            last ;
+     int            end_of_file ;
+-    int            data_bytes ;
++    off_t          data_bytes ;
+     int            skip_blocks ;
+     struct stat sta ;
+     int         seeked ;
+@@ -530,7 +530,7 @@ static int qfits_cache_add(const char *
+                 if ((data_bytes % FITS_BLOCK_SIZE)!=0) {
+                     skip_blocks ++ ;
+                 }
+-                seeked = fseek(in, skip_blocks*FITS_BLOCK_SIZE, SEEK_CUR);
++                seeked = fseeko(in, (off_t)skip_blocks*FITS_BLOCK_SIZE, SEEK_CUR);
+                 if (seeked<0) {
+                     qdebug(
+                         printf("qfits: error seeking file %s\n", filename);
diff -pruN 6.2.0-8/debian/patches/series 6.2.0-8ubuntu2/debian/patches/series
--- 6.2.0-8/debian/patches/series	2014-04-28 15:40:06.000000000 +0000
+++ 6.2.0-8ubuntu2/debian/patches/series	2016-04-18 19:46:30.000000000 +0000
@@ -5,3 +5,4 @@
 05-frameq-nofile.diff
 06-dfits-args.diff
 07-replacekey-manpage.diff
+largefile.patch
