linamh/sci-electronics/saleae-logic-bin/saleae-logic-bin-2.3.30.ebuild

48 lines
1.0 KiB
Bash
Raw Normal View History

2021-06-30 18:45:43 +02:00
# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit appimage desktop
DESCRIPTION="Debug hardware like the pros."
HOMEPAGE="https://www.saleae.com/"
SRC_URI="
amd64? ( https://downloads.saleae.com/logic2/Logic-${PV}-master.AppImage )
"
LICENSE="EULA"
SLOT="0"
KEYWORDS="~amd64"
IUSE=""
RESTRICT="bindist mirror splitdebug"
RDEPEND="
net-print/cups
"
S="${WORKDIR}"
QA_PREBUILT="opt/Saleae/${PN}/Logic opt/Saleae/${PN}/libffmpeg.so opt/Saleae/${PN}/libnode.so"
MY_PN=${PN/-bin/}
src_prepare() {
rm -r ${P}/usr/lib
sed -i 's/^Exec=AppRun/Exec=${MY_PN}/' "${P}/${MY_PN}.desktop" \
|| die "Failed to patch desktop file"
default_src_prepare
}
src_install() {
mv ${P}/usr "${ED}"
rm -f ${P}/${MY_PN}.png
rm -f ${P}/.DirIcon
dodir /opt/Saleae/Logic
mv ${P}/* "${ED}"/opt/Saleae/Logic || die "Failed to move directory"
dosym ../../opt/Saleae/${MY_PN}/${MY_PN} /usr/bin/${MY_PN}
domenu "${ED}"/opt/Saleae/${MY_PN}/${MY_PN}.desktop
#doicon "${ED}"/opt/${P}/${MY_PN}.png
}