linamh/app-emulation/fluxengine/fluxengine-9999.ebuild
2023-07-10 19:43:00 +02:00

70 lines
2.0 KiB
Bash

# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
WX_GTK_VER="3.0-gtk3"
inherit toolchain-funcs wxwidgets xdg udev desktop
if [[ ${PV} = 9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/davidgiven/fluxengine.git"
else
#SRC_URI="http://debian.trikaliotis.net/opencbm/opencbm_${PV}-1.tar.gz"
#SRC_URI="http://www.trikaliotis.net/Download/opencbm-${PV}/opencbm-${PV}-source.tar.bz2"
SRC_URI="https://github.com/OpenCBM/OpenCBM/archive/v${PV//./_}.tar.gz -> opencbm-${PV}-source.tar.gz
https://github.com/OpenCBM/nibtools/archive/master.tar.gz -> nibtools-${PV}-source.tar.gz"
KEYWORDS="~amd64 ~ppc ~sparc ~x86"
fi
DESCRIPTION="The FluxEngine is a very cheap USB floppy disk interface capable of reading and writing exotic non-PC floppy disk formats"
HOMEPAGE="https://github.com/davidgiven/fluxengine"
LICENSE="MIT"
SLOT="0"
IUSE="doc"
DEPEND="dev-util/xxd
dev-lang/lua
dev-libs/protobuf
dev-libs/libfmt
dev-db/sqlite
sys-libs/zlib
sys-apps/systemd"
S="${WORKDIR}"/fluxengine-${PV//./_}
BUILD_TARGETS="all"
#src_prepare() {
# eapply_user
#}
src_compile() {
emake DESTDIR="${D}" CC="$(tc-getCC)" AR="$(tc-getAR)" CXX="$(tc-getCXX)" PREFIX="/usr"
#emake -j1 -f LINUX/Makefile CC="$(tc-getCC)" AR="$(tc-getAR)" LIBDIR="/usr/$(get_libdir)" all || die "make fail
#emake -j1 -f LINUX/Makefile CC="$(tc-getCC)" AR="$(tc-getAR)" LIBDIR="/usr/$(get_libdir)" opencbm || die "make fail"
}
src_install() {
#dodir lib/udev/rules.d
#dodir etc/opencbm.conf.d
#dodir usr/lib/opencbm
emake DESTDIR="${D}" PREFIX="/usr" install
#exeinto usr/lib/opencbm
#doexe opencbm/LINUX/plugin_helper_tools
#newexe debian/install_plugin.sh install_plugin
#insinto lib/udev/rules.d
#newins opencbm/sys/linux/45-opencbm-xa1541.rules 45-opencbm-xa1541.rules
#rm -rf "${D}"/var
newicon extras/icon.png ${PN}.png
make_desktop_entry ${PN}-gui "Flux Engine" ${PN}
}
pkg_postinst() {
udev_reload
}
pkg_postrm() {
udev_reload
}