summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net-news/sfeed/files/sfeed-1.2-ldflags.patch20
-rw-r--r--net-news/sfeed/sfeed-1.2.ebuild18
2 files changed, 29 insertions, 9 deletions
diff --git a/net-news/sfeed/files/sfeed-1.2-ldflags.patch b/net-news/sfeed/files/sfeed-1.2-ldflags.patch
new file mode 100644
index 000000000000..51f712976e9a
--- /dev/null
+++ b/net-news/sfeed/files/sfeed-1.2-ldflags.patch
@@ -0,0 +1,20 @@
+diff -ru sfeed-1.2.orig/Makefile sfeed-1.2/Makefile
+--- sfeed-1.2.orig/Makefile 2022-02-20 11:43:35.164358731 +0100
++++ sfeed-1.2/Makefile 2022-02-20 11:43:45.874495281 +0100
+@@ -27,14 +27,14 @@
+ SFEED_CURSES_CFLAGS = ${CFLAGS}
+ SFEED_CURSES_CPPFLAGS = -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=700 -D_BSD_SOURCE \
+ -DSFEED_THEME=\"themes/${SFEED_THEME}.h\" ${SFEED_CPPFLAGS}
+-SFEED_CURSES_LDFLAGS = ${LDFLAGS} -lcurses
++#SFEED_CURSES_LDFLAGS = ${LDFLAGS} -lcurses
+
+ # Linux: some distros use ncurses and require -lncurses.
+ #SFEED_CURSES_LDFLAGS = ${LDFLAGS} -lncurses
+
+ # Gentoo Linux: some distros might also require -ltinfo and -D_DEFAULT_SOURCE
+ # to prevent warnings about feature test macros.
+-#SFEED_CURSES_LDFLAGS = ${LDFLAGS} -lcurses -ltinfo
++SFEED_CURSES_LDFLAGS = ${LDFLAGS} -lcurses -ltinfo
+
+ # FreeBSD: unset feature test macros for SIGWINCH etc.
+ #SFEED_CURSES_CPPFLAGS =
diff --git a/net-news/sfeed/sfeed-1.2.ebuild b/net-news/sfeed/sfeed-1.2.ebuild
index d4f43e5c5c2b..f70410c8c920 100644
--- a/net-news/sfeed/sfeed-1.2.ebuild
+++ b/net-news/sfeed/sfeed-1.2.ebuild
@@ -25,16 +25,16 @@ RDEPEND="${DEPEND}
x11-misc/xdg-utils"
BDEPEND=""
+PATCHES=(
+ "${FILESDIR}/${PN}-1.2-ldflags.patch"
+)
+
src_compile() {
- if use ncurses; then
- emake \
- CC=$(tc-getCC) \
- LDFLAGS="$LDFLAGS -lcurses -ltinfo"
- else
- emake \
- CC=$(tc-getCC) \
- SFEED_CURSES=""
- fi
+ emake \
+ CC=$(tc-getCC) \
+ RANLIB=$(tc-getRANLIB) \
+ AR=$(tc-getAR) \
+ SFEED_CURSES=$(usex ncurses "sfeed_curses" "")
}
src_install() {