Skip to content

Commit

Permalink
k9copy: fix build with gcc6
Browse files Browse the repository at this point in the history
  • Loading branch information
Samuel Leathers authored and fpletz committed Aug 30, 2017
1 parent 8211dfb commit d99d902
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkgs/applications/video/k9copy/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ stdenv.mkDerivation rec {
sha256 = "0dp06rwihks50c57bbv04d6bj2qc88isl91971r4lii2xp0qn7sg";
};

patches = [
./gcc6.patch
];

cmakeFlags = [
"-DQT5_BUILD=ON"
"-DCMAKE_MINIMUM_REQUIRED_VERSION=3.0"
Expand Down
26 changes: 26 additions & 0 deletions pkgs/applications/video/k9copy/gcc6.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
diff --git c/src/backup/k9dvdbackup.cpp i/src/backup/k9dvdbackup.cpp
index f5e4859..82fa392 100755
--- c/src/backup/k9dvdbackup.cpp
+++ i/src/backup/k9dvdbackup.cpp
@@ -907,7 +907,7 @@ k9Vobu * k9DVDBackup::remapOffset(uint32_t _sector,uint32_t *_offset,int _dir) {


if ((vobu1 !=NULL) && (vobu2!=NULL)) {
- *_offset = abs(vobu1->newSector - vobu2->newSector) | maskOffset1 ;
+ *_offset = (vobu1->newSector - vobu2->newSector) | maskOffset1 ;
*_offset |= maskOffset2;
return vobu2;
}
diff --git c/src/backup/k9execcopy.cpp i/src/backup/k9execcopy.cpp
index d59222c..35de923 100644
--- c/src/backup/k9execcopy.cpp
+++ i/src/backup/k9execcopy.cpp
@@ -306,7 +306,7 @@ void k9ExecCopy::createMkv(k9DVDTitle *_title,const QString &_filename,QMultiMap

#if QT_VERSION >= 0x050000
m_progressDialog=new QProgressDialog(k9Dialogs::getMainWidget() );
- m_progressDialog->setCancelButton(false);
+ m_progressDialog->setCancelButton(0);

#else
m_progressDialog=new KProgressDialog(k9Dialogs::getMainWidget() );

0 comments on commit d99d902

Please sign in to comment.