dev-embedded/stlink: add
[sgilles-overlay.git] / dev-embedded / stlink / stlink-9999.ebuild
blob5bbcef53edb8edaf6f87707735bbededdf377336
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
4 EAPI=7
6 inherit udev xdg cmake
8 DESCRIPTION="stm32 discovery line linux programmer"
9 HOMEPAGE="https://github.com/texane/stlink"
10 if [[ ${PV} == "9999" ]]; then
11 EGIT_REPO_URI="https://github.com/texane/stlink.git"
12 inherit git-r3
13 else
14 SRC_URI="https://github.com/texane/stlink/archive/v${PV}.tar.gz -> ${P}.tar.gz"
15 KEYWORDS="~amd64"
18 LICENSE="BSD"
19 SLOT="0"
21 IUSE="gtk3"
23 RDEPEND="virtual/libusb:1
24 >=dev-libs/glib-2.32.0:2
25 gtk3? ( x11-libs/gtk+:3 )"
26 DEPEND="${RDEPEND}"
27 BDEPEND="virtual/pkgconfig"
29 src_configure() {
30 local mycmakeargs=(
31 -DSTLINK_UDEV_RULES_DIR="$(get_udevdir)"/rules.d
32 -DSTLINK_MODPROBED_DIR="${EPREFIX}/etc/modprobe.d"
33 -DSTLINK_STATIC_LIB=OFF
34 -DLIB_INSTALL_DIR:PATH="$(get_libdir)"
37 cmake_src_configure