aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDex Conner <cantcuckthis@danwin1210.de>2022-04-24 18:21:06 +0300
committerDex Conner <cantcuckthis@danwin1210.de>2022-04-24 18:26:01 +0300
commit03ed3db1f7003bc01926cd6680b1692a5a4af2d2 (patch)
tree0d1e7e91b9ee813af4c232a81afbfce18f8494ad /app-office
parentnet-libs/ixwebsocket: add 11.4.1 (diff)
downloadguru-03ed3db1f7003bc01926cd6680b1692a5a4af2d2.tar.gz
guru-03ed3db1f7003bc01926cd6680b1692a5a4af2d2.tar.bz2
guru-03ed3db1f7003bc01926cd6680b1692a5a4af2d2.zip
app-office/sc-im: runtime dep change revbump
Signed-off-by: Dex Conner <cantcuckthis@danwin1210.de>
Diffstat (limited to 'app-office')
-rw-r--r--app-office/sc-im/sc-im-0.8.2-r1.ebuild103
1 files changed, 103 insertions, 0 deletions
diff --git a/app-office/sc-im/sc-im-0.8.2-r1.ebuild b/app-office/sc-im/sc-im-0.8.2-r1.ebuild
new file mode 100644
index 000000000..15abb065d
--- /dev/null
+++ b/app-office/sc-im/sc-im-0.8.2-r1.ebuild
@@ -0,0 +1,103 @@
+# Copyright 2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+LUA_COMPAT=( lua5-1 luajit )
+
+inherit lua-single toolchain-funcs flag-o-matic
+
+DESCRIPTION="Spreadsheet Calculator Improvised -- An ncurses spreadsheet program for terminal"
+HOMEPAGE="https://github.com/andmarti1424/sc-im"
+SRC_URI="https://github.com/andmarti1424/sc-im/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD-4"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="X plots wayland xls xlsx lua ods tmux"
+REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} )"
+
+PATCHES=(
+ "${FILESDIR}/${P}-prefix.patch"
+ "${FILESDIR}/${P}-automagic.patch"
+ "${FILESDIR}/${P}-clipboard.patch"
+)
+
+DEPEND="
+ sys-libs/ncurses
+
+ lua? (
+ ${LUA_DEPS}
+ )
+ ods? (
+ dev-libs/libxml2
+ dev-libs/libzip
+ )
+ plots? ( sci-visualization/gnuplot )
+ tmux? ( app-misc/tmux )
+ wayland? ( gui-apps/wl-clipboard )
+ X? ( x11-misc/xclip )
+ xls? (
+ dev-libs/libxls
+ )
+ xlsx? (
+ dev-libs/libxlsxwriter
+ dev-libs/libxml2
+ dev-libs/libzip
+ )
+"
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+S="${WORKDIR}/${P}/src"
+
+pkg_setup() {
+ CONFLICTING=$(usex tmux "tmux " "")$(usex wayland "wayland " "")$(usex X "X" "")
+ if ( use tmux && ( use wayland || use X ) ) ; then
+ elog "Conflicting flags for clipboard support are set: ${CONFLICTING}"
+ elog "tmux support has been preferred."
+ elif ( use wayland && use X ) ; then
+ elog "Conflicting flags for clipboard support are set: ${CONFLICTING}"
+ elog "Wayland support has been preferred."
+ fi
+
+ # Run lua setup
+ lua-single_pkg_setup
+}
+
+src_configure() {
+ tc-export CC
+
+ PKGCONF=$(tc-getPKG_CONFIG)
+
+ if use tmux ; then
+ append-cflags '-DDEFAULT_COPY_TO_CLIPBOARD_CMD=\""tmux load-buffer"\"'
+ append-cflags '-DDEFAULT_PASTE_FROM_CLIPBOARD_CMD=\""tmux show-buffer"\"'
+ elif use wayland ; then
+ append-cflags '-DDEFAULT_COPY_TO_CLIPBOARD_CMD=\""wl-copy <"\"'
+ append-cflags '-DDEFAULT_PASTE_FROM_CLIPBOARD_CMD=\""wl-paste"\"'
+ elif use X ; then
+ append-cflags '-DDEFAULT_COPY_TO_CLIPBOARD_CMD=\""xclip -i -selection clipboard <"\"'
+ append-cflags '-DDEFAULT_PASTE_FROM_CLIPBOARD_CMD=\""xclip -o -selection clipboard"\"'
+ fi
+
+ use plots && append-cflags -DGNUPLOT
+ if use xls; then
+ append-cflags -DXLS $(${PKGCONF} --cflags libxls)
+ LDLIBS+=" $(${PKGCONF} --libs libxls)"
+ fi
+ if use xlsx || use ods ; then
+ append-cflags -DODS -DXLSX $(${PKGCONF} --cflags libxml-2.0 libzip)
+ LDLIBS+=" -DODS -DXLSX $(${PKGCONF} --libs libxml-2.0 libzip)"
+ fi
+ if use xlsx ; then
+ append-cflags -DXLSX_EXPORT $(${PKGCONF} --cflags xlsxwriter)
+ LDLIBS+=" -DXLSX_EXPORT $(${PKGCONF} --libs xlsxwriter)"
+ fi
+ if use lua ; then
+ append-cflags -DXLUA $(${PKGCONF} --cflags lua)
+ LDLIBS+=" -DXLUA $(${PKGCONF} --libs lua) -rdynamic"
+ fi
+ append-cflags $(${PKGCONF} --cflags ncursesw) || append-cflags $(${PKGCONF} --cflags ncurses)
+ LDLIBS+=" $(${PKGCONF} --libs ncursesw)" || LDLIBS+=" $(${PKGCONF} --libs ncurses)"
+ export LDLIBS
+}