summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorConrad Kostecki <conrad@kostecki.com>2018-06-22 20:38:00 +0200
committerMichał Górny <mgorny@gentoo.org>2018-06-22 20:48:28 +0200
commitc819a508ae5b25cb0745ceccea8e4e0c1a362d21 (patch)
tree7cb4cc414411a911779170d77f5e072ddb9bc5d1 /app-misc
parentprofiles/license_groups: add SPS license to EULA group (diff)
downloadgentoo-c819a508ae5b25cb0745ceccea8e4e0c1a362d21.tar.gz
gentoo-c819a508ae5b25cb0745ceccea8e4e0c1a362d21.tar.bz2
gentoo-c819a508ae5b25cb0745ceccea8e4e0c1a362d21.zip
app-misc/kryoflux-dtc: New package
Closes: https://bugs.gentoo.org/651482 Package-Manager: Portage-2.3.40, Repoman-2.3.9
Diffstat (limited to 'app-misc')
-rw-r--r--app-misc/kryoflux-dtc/Manifest2
-rw-r--r--app-misc/kryoflux-dtc/kryoflux-dtc-2.6.ebuild104
-rw-r--r--app-misc/kryoflux-dtc/metadata.xml17
3 files changed, 123 insertions, 0 deletions
diff --git a/app-misc/kryoflux-dtc/Manifest b/app-misc/kryoflux-dtc/Manifest
new file mode 100644
index 000000000000..e6d215853fe9
--- /dev/null
+++ b/app-misc/kryoflux-dtc/Manifest
@@ -0,0 +1,2 @@
+DIST kryoflux-ui.jar 2101377 BLAKE2B db9922b9d5787772849d1ef9edae52d64de066f643c471412ed9129307c4ee399ec3a18ebcacd7428ab15eabf5307e916b678831f2fa456cbd7073aa60bbb574 SHA512 66ba81ed1b2a97a0391e513c45b19436f17677e3dfe7c063749e41763658f99a5eb92e5b3312f4151f8fc51bd79502ac11ffd895966117e1d5a9849867aeb957
+DIST kryoflux_2.6_linux.tar.bz2 9177658 BLAKE2B 6eb0bc7a166950bfedb32da466c17125a8a7d64e4bc9aa6610c69dd0f98c2fb5187ad19dbaf191b33dcb5a786ec4a1fa9bce2464c3c04eb152e0b9ed7ae770f2 SHA512 9bf700e9c646bad135999eb1fed12c86ff6fbc11a0034b86af7541fb16a4905dd740c706ebb87bf5848f5d80f45699c350a56397df5b6850559c2576d18eef1b
diff --git a/app-misc/kryoflux-dtc/kryoflux-dtc-2.6.ebuild b/app-misc/kryoflux-dtc/kryoflux-dtc-2.6.ebuild
new file mode 100644
index 000000000000..de512258d895
--- /dev/null
+++ b/app-misc/kryoflux-dtc/kryoflux-dtc-2.6.ebuild
@@ -0,0 +1,104 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+MY_P="kryoflux_${PV}_linux"
+
+inherit desktop eutils udev xdg-utils
+
+DESCRIPTION="KryoFlux Host Software"
+HOMEPAGE="https://www.kryoflux.com"
+SRC_URI="https://www.kryoflux.com/download/${MY_P}.tar.bz2
+ gui? ( https://www.kryoflux.com/kryoflux-ui.jar )"
+
+KEYWORDS="-* ~amd64 ~x86"
+LICENSE="SPS"
+SLOT="0"
+IUSE="demos doc fast-firmware gui static"
+
+RDEPEND="dev-libs/spsdeclib
+ virtual/libusb:1
+ virtual/udev
+ gui? ( virtual/jre )"
+
+DEPEND="app-arch/unzip"
+
+RESTRICT="bindist mirror strip"
+
+S="${WORKDIR}/${MY_P}"
+
+QA_PREBUILT="/usr/bin/kryoflux-dtc"
+
+src_unpack() {
+ unpack ${MY_P}.tar.bz2
+
+ if use gui; then
+ # Updated *.jar for compatibility with >= Java 9
+ cp "${DISTDIR}"/kryoflux-ui.jar "${S}" || die
+
+ # Extract kryoflux-ui.jar to get a logo for the meny entry
+ unpack kryoflux-ui.jar
+ fi
+}
+
+src_install() {
+ newbin dtc/$(usex amd64 x86_64 i686)/$(usex static static dynamic)/dtc kryoflux-dtc
+
+ cat <<-EOF > "${T}"/80-kryoflux.rules || die
+ ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="03eb", ATTR{idProduct}=="6124", GROUP="floppy", MODE="0660"
+ EOF
+ udev_dorules "${T}"/80-kryoflux.rules
+
+ if use gui; then
+ insinto /usr/share/kryoflux-ui
+ doins kryoflux-ui.jar
+
+ dosym ../../bin/kryoflux-dtc /usr/share/kryoflux-ui/dtc
+
+ make_wrapper kryoflux-ui "java -jar kryoflux-ui.jar" /usr/share/kryoflux-ui
+
+ newicon "${WORKDIR}"/images/disk.png kryoflux-ui.png
+
+ make_desktop_entry "kryoflux-ui" "KryoFlux UI" kryoflux-ui Development
+
+ dodoc dtc/kryoflux-ui_README.txt
+ fi
+
+ if use fast-firmware; then
+ insinto /lib/firmware
+ doins dtc/firmware_fast/firmware_kf_usb_rosalie.bin
+
+ dodoc dtc/firmware_fast/firmware_fast_README.txt
+ else
+ insinto /lib/firmware
+ doins dtc/firmware_kf_usb_rosalie.bin
+ fi
+
+ if use demos; then
+ dodoc -r g64_demo ipf_demo
+ fi
+
+ if use doc; then
+ dodoc -r docs schematics
+ fi
+
+ local DOCS=( "DONATIONS.txt" "RELEASE.txt" "README.linux" )
+ einstalldocs
+}
+
+pkg_postinst() {
+ elog "If you want to access your Kryoflux without root access,"
+ elog "please add yourself to the floppy group."
+
+ if use fast-firmware; then
+ elog ""
+ elog "You have enabled the fast firmware. Please keep in mind,"
+ elog "that this firmware can cause trouble with older floppy drives."
+ fi
+
+ if use gui; then
+ xdg_desktop_database_update
+ xdg_mimeinfo_database_update
+ fi
+}
diff --git a/app-misc/kryoflux-dtc/metadata.xml b/app-misc/kryoflux-dtc/metadata.xml
new file mode 100644
index 000000000000..c95657a7f862
--- /dev/null
+++ b/app-misc/kryoflux-dtc/metadata.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>ck+gentoo@bl4ckb0x.de</email>
+ <name>Conrad Kostecki</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <use>
+ <flag name="demos">Install example floppy game files.</flag>
+ <flag name="fast-firmware">Install fast firmware instead of slow firmware.</flag>
+ <flag name="gui">Install the Kryoflux GUI</flag>
+ </use>
+</pkgmetadata>