summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authordoragasu2015-06-21 16:35:53 +0200
committerdoragasu2015-06-21 16:35:53 +0200
commit18bdd78a4bf1ff6700e9a6c9420a8dd3d9908487 (patch)
treedfd322613fd25a523c2d6e3bf78b4e9afbbafc78
downloadaur-18bdd78a4bf1ff6700e9a6c9420a8dd3d9908487.tar.gz
AUR4 migration
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD44
-rw-r--r--config.patch12
-rw-r--r--gbcflsh.desktop10
-rw-r--r--gbcflsh.install5
-rw-r--r--ultraspeed.patch115
6 files changed, 209 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..e3f502f32836
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = gbcflsh
+ pkgdesc = GameBoy Cart Flasher
+ pkgver = 1.1
+ pkgrel = 2
+ url = http://sourceforge.net/projects/gbcf
+ install = gbcflsh.install
+ arch = i686
+ arch = x86_64
+ license = GPL
+ depends = qt4
+ provides = gbcflsh
+ conflicts = gbcflsh
+ source = http://downloads.sourceforge.net/gbcf/gbcflsh_1.1_src.tar.gz
+ source = gbcflsh.desktop
+ source = config.patch
+ source = ultraspeed.patch
+ md5sums = a2c6c1e0a9e4c4ba64631e0f66989dfc
+ md5sums = d6c39e134228d827d26db6d72fd65e85
+ md5sums = f4674e2030d797d1ec8a9d5603a8e97c
+ md5sums = 0fdff2428687a4e9f0eb774a6fbfde4f
+
+pkgname = gbcflsh
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..60c2b5b58dce
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,44 @@
+# Maintainer: doragasu <doragasu (yawn) hotmail (roll) com>
+
+pkgname=gbcflsh
+pkgver=1.1
+pkgrel=2
+pkgdesc="GameBoy Cart Flasher"
+arch=('i686' 'x86_64')
+url="http://sourceforge.net/projects/gbcf"
+license=('GPL')
+groups=()
+depends=('qt4')
+provides=('gbcflsh')
+conflicts=('gbcflsh')
+install=("$pkgname.install")
+source=(http://downloads.sourceforge.net/gbcf/${pkgname}_${pkgver}_src.tar.gz
+ gbcflsh.desktop
+ config.patch
+ ultraspeed.patch)
+md5sums=('a2c6c1e0a9e4c4ba64631e0f66989dfc'
+ 'd6c39e134228d827d26db6d72fd65e85'
+ 'f4674e2030d797d1ec8a9d5603a8e97c'
+ '0fdff2428687a4e9f0eb774a6fbfde4f')
+
+build() {
+ # Patch to install config files in /usr/share/gbcf instead of ~/config
+ patch -p0 < config.patch
+ # Patch to fix build errors and add -ultraspeed (for 1.5 Mbps).
+ patch -p0 < ultraspeed.patch
+ cd "$srcdir/gbcflsh_1.1_src"
+
+ qmake-qt4
+ make
+}
+
+package() {
+ # Install files
+ cd "$srcdir/gbcflsh_1.1_src"
+ INSTALL_ROOT="$pkgdir" make install
+ # Copy icon and .desktop file
+ mkdir -p "$pkgdir/usr/share/pixmaps"
+ cp src/icon.xpm "$pkgdir/usr/share/pixmaps/gbcflsh.xpm"
+ mkdir -p "$pkgdir/usr/share/applications"
+ cp "$srcdir/gbcflsh.desktop" "$pkgdir/usr/share/applications/"
+}
diff --git a/config.patch b/config.patch
new file mode 100644
index 000000000000..c545da67c8c5
--- /dev/null
+++ b/config.patch
@@ -0,0 +1,12 @@
+diff -ruN gbcflsh_1.1_src.orig/gbcf.pro gbcflsh_1.1_src/gbcf.pro
+--- gbcflsh_1.1_src.orig/gbcf.pro 2015-06-07 16:08:46.800217639 +0200
++++ gbcflsh_1.1_src/gbcf.pro 2015-06-07 16:09:15.903447609 +0200
+@@ -57,7 +57,7 @@
+ langpack.files = src/*.qm
+ exec.path = /usr/bin
+ exec.files = gbcflsh
+-config.path = ~/.config/GBCFProject
++config.path = /usr/share/gbcf/GBCFProject
+ config.files = GameBoyCartFlasher.conf
+ INSTALLS += langpack exec config
+ }
diff --git a/gbcflsh.desktop b/gbcflsh.desktop
new file mode 100644
index 000000000000..671ed60d740f
--- /dev/null
+++ b/gbcflsh.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Version=1.1
+Name=Gameboy Cart Flahser
+Comment=Software for reading and writing ROMs from/to Gameboy Carts.
+Exec=gbcflsh -ultraspeed
+Icon=gbcflsh.xpm
+Terminal=false
+Type=Application
+Categories=Utility;
+StartupNotify=true
diff --git a/gbcflsh.install b/gbcflsh.install
new file mode 100644
index 000000000000..294cdfe1f0eb
--- /dev/null
+++ b/gbcflsh.install
@@ -0,0 +1,5 @@
+post_install() {
+ echo Warning: You should copy /usr/share/gbcf/GBCFProject directory to ~/.config/ for each user you wish to use the application. Otherwise language configuration will not work!
+}
+
+
diff --git a/ultraspeed.patch b/ultraspeed.patch
new file mode 100644
index 000000000000..0e270995c294
--- /dev/null
+++ b/ultraspeed.patch
@@ -0,0 +1,115 @@
+diff -ruN gbcflsh_1.1_src.orig/src/const.h gbcflsh_1.1_src/src/const.h
+--- gbcflsh_1.1_src.orig/src/const.h 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/const.h 2015-06-04 13:21:56.421095104 +0200
+@@ -64,7 +64,7 @@
+ enum dap_t
+ { LONGER = 0x00, DEFAULT = 0x01, DATAPOLL = 0x02, TOGGLE = 0x03 };
+ enum speed_type
+-{ LOW = 0x00, STANDARD = 0x01, HIGH = 0x02 };
++{ LOW = 0x00, STANDARD = 0x01, HIGH = 0x02, ULTRA = 0x03 };
+
+ /* MBC types */
+ enum mbc_t
+diff -ruN gbcflsh_1.1_src.orig/src/gbcflsh.cpp gbcflsh_1.1_src/src/gbcflsh.cpp
+--- gbcflsh_1.1_src.orig/src/gbcflsh.cpp 2008-03-25 19:20:01.000000000 +0100
++++ gbcflsh_1.1_src/src/gbcflsh.cpp 2015-06-04 13:23:45.123778698 +0200
+@@ -35,12 +35,14 @@
+ if (strcmp (*argv, "-showbbl") == 0)
+ Settings::showbbl = TRUE;
+ /*
+- * USB speed LOW 125000bps HI 375000
++ * USB speed LOW 125000bps, HI 375000, ULTRA 1500000
+ */
+ if (strcmp (*argv, "-lowspeed") == 0)
+ Settings::speed = LOW;
+ if (strcmp (*argv, "-highspeed") == 0)
+ Settings::speed = HIGH;
++ if (strcmp (*argv, "-ultraspeed") == 0)
++ Settings::speed = ULTRA;
+ /*
+ * communication threads prioryty are used when communication
+ * or gui is freezing
+diff -ruN gbcflsh_1.1_src.orig/src/Logic.cpp gbcflsh_1.1_src/src/Logic.cpp
+--- gbcflsh_1.1_src.orig/src/Logic.cpp 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/Logic.cpp 2015-06-04 12:31:56.859682511 +0200
+@@ -8,6 +8,7 @@
+ #include "AbstractPort.h"
+ #include <ctype.h>
+ #include <cassert>
++#include <stdio.h>
+
+ /* array used to generate crc16 */
+ unsigned short crc16_tab[256] = {
+diff -ruN gbcflsh_1.1_src.orig/src/ReadFlashThread.cpp gbcflsh_1.1_src/src/ReadFlashThread.cpp
+--- gbcflsh_1.1_src.orig/src/ReadFlashThread.cpp 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/ReadFlashThread.cpp 2015-06-04 12:32:23.919628575 +0200
+@@ -2,6 +2,7 @@
+ ** ReadFlashThread.cpp
+ ** Author: Kraku
+ *****************************************************************************/
++#include <stdio.h>
+ #include "ReadFlashThread.h"
+ #include "Settings.h"
+ #include "Logic.h"
+diff -ruN gbcflsh_1.1_src.orig/src/ReadRamThread.cpp gbcflsh_1.1_src/src/ReadRamThread.cpp
+--- gbcflsh_1.1_src.orig/src/ReadRamThread.cpp 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/ReadRamThread.cpp 2015-06-04 12:32:45.456252452 +0200
+@@ -2,6 +2,7 @@
+ ** ReadRamThread.cpp
+ ** Author: Kraku
+ *****************************************************************************/
++#include <stdio.h>
+ #include "ReadRamThread.h"
+ #include "Settings.h"
+ #include "Logic.h"
+diff -ruN gbcflsh_1.1_src.orig/src/USBPort.cpp gbcflsh_1.1_src/src/USBPort.cpp
+--- gbcflsh_1.1_src.orig/src/USBPort.cpp 2008-03-25 19:11:14.000000000 +0100
++++ gbcflsh_1.1_src/src/USBPort.cpp 2015-06-04 13:25:20.819881457 +0200
+@@ -44,6 +44,11 @@
+ if (ftdi_set_baudrate (&ftdic, 375000) < 0)
+ return FALSE;
+ }
++ else if (Settings::speed == ULTRA)
++ {
++ if (ftdi_set_baudrate (&ftdic, 1500000) < 0)
++ return FALSE;
++ }
+
+ if (ftdi_set_latency_timer (&ftdic, 2) < 0)
+ return FALSE;
+diff -ruN gbcflsh_1.1_src.orig/src/USBPortWin.cpp gbcflsh_1.1_src/src/USBPortWin.cpp
+--- gbcflsh_1.1_src.orig/src/USBPortWin.cpp 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/USBPortWin.cpp 2015-06-04 13:25:54.339685692 +0200
+@@ -41,6 +41,10 @@
+ if(FT_SetBaudRate(ftHandle,375000) != FT_OK)
+ return FALSE;
+ }
++ else if(Settings::speed == ULTRA){
++ if(FT_SetBaudRate(ftHandle,1500000) != FT_OK)
++ return FALSE;
++ }
+
+ if(FT_SetLatencyTimer(ftHandle, 2) != FT_OK)
+ return FALSE;
+diff -ruN gbcflsh_1.1_src.orig/src/WriteFlashThread.cpp gbcflsh_1.1_src/src/WriteFlashThread.cpp
+--- gbcflsh_1.1_src.orig/src/WriteFlashThread.cpp 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/WriteFlashThread.cpp 2015-06-04 12:33:25.666172885 +0200
+@@ -2,6 +2,7 @@
+ ** WriteFlashThread.cpp
+ ** Author: Kraku
+ *****************************************************************************/
++#include <stdio.h>
+ #include "WriteFlashThread.h"
+ #include "Settings.h"
+ #include "Logic.h"
+diff -ruN gbcflsh_1.1_src.orig/src/WriteRamThread.cpp gbcflsh_1.1_src/src/WriteRamThread.cpp
+--- gbcflsh_1.1_src.orig/src/WriteRamThread.cpp 2008-03-15 00:43:57.000000000 +0100
++++ gbcflsh_1.1_src/src/WriteRamThread.cpp 2015-06-04 12:33:42.996138721 +0200
+@@ -2,6 +2,7 @@
+ ** WriteRamThread.cpp
+ ** Author: Kraku
+ *****************************************************************************/
++#include <stdio.h>
+ #include "WriteRamThread.h"
+ #include "Settings.h"
+ #include "Logic.h"