summaryrefslogtreecommitdiff
path: root/app-misc/dfshow
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-06-20 14:45:01 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-06-20 14:45:01 +0100
commit34dea8e38f88007799629d0a56b12dec480b1d21 (patch)
tree6790873994b58030360328cf5897d934b3b03d16 /app-misc/dfshow
parent7932d472a02d4c016ff7dff4b7a5479ab9d1883d (diff)
gentoo resync : 20.06.2021
Diffstat (limited to 'app-misc/dfshow')
-rw-r--r--app-misc/dfshow/Manifest3
-rw-r--r--app-misc/dfshow/dfshow-0.9.1_beta-r1.ebuild15
-rw-r--r--app-misc/dfshow/files/dfshow-0.9.1_beta-use-PKG_CHECK_MODULES-for-ncurses-libconfig.patch82
3 files changed, 96 insertions, 4 deletions
diff --git a/app-misc/dfshow/Manifest b/app-misc/dfshow/Manifest
index 5c5eca9d4459..dfd6939c77f3 100644
--- a/app-misc/dfshow/Manifest
+++ b/app-misc/dfshow/Manifest
@@ -1,3 +1,4 @@
+AUX dfshow-0.9.1_beta-use-PKG_CHECK_MODULES-for-ncurses-libconfig.patch 2955 BLAKE2B 8c1d5b8483a83d4f9051a444c97f96b4753dae76be410df12495c3df932a800ea804ae742f5ea918dcf0f3e5b5ec957218cc7b7dd12e5ffce8d910513874f720 SHA512 945037750e52fb4d20348b30a610ad6844b2aa94ddfd204fa2c536c7587d473cac10545becf3240770794c3b2203cee5121394ffebbc14b931c5dbdc1c2955fc
DIST dfshow-0.9.1_beta.tar.gz 109882 BLAKE2B a8351a4ae1e3d8f0a4166f7642bb32a1ec60723f73d7da9bdc8b496162c4174421e0e369499ace22cfeec64a32b3dbcd9411bdc10c19cc6427d04bc1df298c44 SHA512 c13347075f51c213e804855a1cc432076d8fcd5f278e4945b457fdddc3945e9d743f3dc4f26e4194f6a5b612a4e118081dd3afbb1a4523ae3c962a4fae68494e
-EBUILD dfshow-0.9.1_beta-r1.ebuild 1051 BLAKE2B 7b307677052456d972314e64de288153a7d12dded4cda7b6d10ce1e28f3fc81ce34c8934387843c1da2d79878cd097d426f918dec1241b6875a1a97ee8fff73d SHA512 996d8be6f69685b4702a051a054740de1fe07cd40b98822b0865395d10007c722e9c097d690b4e4f74155f643b2458be43d6a887f6dc1c8a75bfc625d89514f4
+EBUILD dfshow-0.9.1_beta-r1.ebuild 1231 BLAKE2B 9d0c16a6287456fff90660bcae31f2179b343e6787ffc8a50e84a66a7289ef010e18258225c7d72063fffd47ba020def6bb9f58123773acc812404c770641ab8 SHA512 f913d2f69c4c6359da04fdf974ae6626ce468f4d9c700ab2bdd09e9ff9eeb7c23a572f5cdcd6d716d2ea03858aa570954a045388a46bca293e59bd6a72752b7a
MISC metadata.xml 432 BLAKE2B 070e05fa430c4198c17b388d23dcf7dc75bd7249a3de6d664399a1a30bd26126b18098b11c144ef639b63b5cd8d5988e95cead669c4cac5081496d8ed19e5c7e SHA512 ebd53dbe275b79137bdc3515674b9a23afba5d727b5deeb63b41e97e069fd2873e5ec322b6e4635a227c9a0a2ee5080755b4c8d5566a5a24abc74ee9c965c812
diff --git a/app-misc/dfshow/dfshow-0.9.1_beta-r1.ebuild b/app-misc/dfshow/dfshow-0.9.1_beta-r1.ebuild
index 883ebd7c7fee..d6a901fd6e7d 100644
--- a/app-misc/dfshow/dfshow-0.9.1_beta-r1.ebuild
+++ b/app-misc/dfshow/dfshow-0.9.1_beta-r1.ebuild
@@ -3,7 +3,7 @@
EAPI=7
-inherit autotools bash-completion-r1
+inherit autotools bash-completion-r1 flag-o-matic
MY_PV="${PV//_beta/-beta}"
DESCRIPTION="DF-SHOW is a Unix-like rewrite of some of the applications from DF-EDIT"
@@ -19,11 +19,20 @@ DEPEND="dev-libs/libconfig:=
sys-libs/ncurses:0=
"
RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.9.1_beta-use-PKG_CHECK_MODULES-for-ncurses-libconfig.patch
+)
src_prepare() {
default
- sed -i 's/LDADD = -lncursesw -lm -lconfig/LDADD = -lncursesw -lm -lconfig -ltinfow/' Makefile.am ||
- die "sed in Makefile.am failed"
+
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ # Standard on macOS
+ # No real motivation to push libtool upstream just for this
+ append-ldflags -Wl,-undefined -Wl,dynamic_lookup
+ fi
eautoreconf
}
diff --git a/app-misc/dfshow/files/dfshow-0.9.1_beta-use-PKG_CHECK_MODULES-for-ncurses-libconfig.patch b/app-misc/dfshow/files/dfshow-0.9.1_beta-use-PKG_CHECK_MODULES-for-ncurses-libconfig.patch
new file mode 100644
index 000000000000..44fc11b34ca2
--- /dev/null
+++ b/app-misc/dfshow/files/dfshow-0.9.1_beta-use-PKG_CHECK_MODULES-for-ncurses-libconfig.patch
@@ -0,0 +1,82 @@
+From a8185ad9270db54b9e0c66002e7ceebdc264af19 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Fri, 30 Apr 2021 04:49:26 +0100
+Subject: [PATCH] Use PKG_CHECK_MODULES for ncurses, libconfig
+
+It's not always clear how to link against ncurses
+and the choices before us are:
+1) use a convoluted chain of autoconf checks
+2) use pkg-config (this commit)
+3) guess and hardcode the most popular values
+
+This is an iteration of a previous change [0] by a
+Gentoo contributor which landed upstream.
+
+The previous change ended up doing 3) which is fine
+but doesn't always work in strange situations. Gentoo
+_usually_ builds 'split tinfo' on Linux but this isn't
+guaranteed.
+
+This change now uses PKG_CHECK_MODULES which uses
+pkg-config behind the scenes to query ncurses
+for the correct way to build & link against it.
+
+(We do the same thing for libconfig too.)
+
+[0] https://github.com/roberthawdon/dfshow/pull/115
+---
+ Makefile.am | 13 ++++---------
+ configure.ac | 5 +++--
+ 2 files changed, 7 insertions(+), 11 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 048ded5..6dcaa1f 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -4,21 +4,16 @@ dfshowconfdir = $(sysconfdir)
+ dfshowdatadir = $(datadir)/dfshow
+
+ AM_CFLAGS = -DSYSCONFIG=\"$(dfshowconfdir)\" -DDATADIR=\"$(dfshowdatadir)\" -D_XOPEN_SOURCE_EXTENDED -fno-common
++AM_CFLAGS += $(ncurses_CFLAGS) $(libconfig_CFLAGS)
+
+-LDADD = -lm -lconfig
+-
+-if DARWIN
+-LDADD += -lncurses
+-else
+-LDADD += -lncursesw
+-endif
++LDADD = -lm $(ncurses_LIBS) $(libconfig_LIBS)
+
+ if LINUX
+-LDADD += -lacl -ltinfo
++LDADD += -lacl
+ endif
+
+ if HURD
+-LDADD += -lacl -ltinfo
++LDADD += -lacl
+ endif
+
+ if SELINUX
+diff --git a/configure.ac b/configure.ac
+index f185b69..8acf1ab 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -32,10 +32,11 @@ AC_CHECK_FUNCS(acl_get facl_get acl_set facl_set)
+
+ AC_CHECK_MEMBERS([struct stat.st_author])
+ AC_CHECK_HEADERS([stdio.h limits.h signal.h ctype.h wctype.h getopt.h sys/types.h sys/stat.h dirent.h fcntl.h pwd.h string.h stdlib.h unistd.h time.h sys/statvfs.h libgen.h errno.h wchar.h hurd.h math.h sys/sysmacros.h regex.h utime.h sys/xattr.h acl/libacl.h stdint.h])
+-AC_CHECK_HEADERS(ncurses.h, , AC_MSG_ERROR(ncurses header (ncurses.h) not found. You may need to install an ncurses development package.))
+-AC_CHECK_HEADERS(libconfig.h, , AC_MSG_ERROR(libconfig header (libconfig.h) not found. You may need to install a libconfig development package.))
+ AC_CHECK_HEADERS(sys/acl.h, , AC_MSG_ERROR(libacl header (sys/acl.h) not found. You may need to install a libacl development package.))
+
++PKG_CHECK_MODULES([ncurses], [ncursesw ncurses])
++PKG_CHECK_MODULES([libconfig], [libconfig])
++
+ AC_ARG_WITH([selinux], AS_HELP_STRING([--with-selinux], [Build with selinux library (default: disabled)]))
+ AC_ARG_ENABLE([move-between-devices], AS_HELP_STRING([--enable-move-between-devices], [Enable moving objects between mounted devices (default: disabled)]))
+
+--
+2.31.1
+