mirror of
https://git.FreeBSD.org/ports.git
synced 2024-10-18 19:49:40 +00:00
misc/mc: improve the check whether installed diff(1) is GNU or BSD
In 2017, GNU diff had been replaced by BSD licensed diff in our base, but some features of GNU diff had not been implemented, particularly, the ``group format'' family of options. Instead of checking for the ${OSVERSION} value, check if installed diff(1) implementation is GNU or BSD one based on the --version output. Because conditions are subject to immediate expansion, we cannot use ${DIFF} and ${GREP} variables; however, literal ``diff'' is actually correct in this particular case as user's preferred diff(1) does not necessarily point to ``/usr/bin/diff'' which ${DIFF} expands to. While here, amend the EDITOR option description so it clearly refers to the internal *text* editor.
This commit is contained in:
parent
50ae64ad8f
commit
bf294827ef
@ -15,6 +15,11 @@ LICENSE_FILE= ${WRKSRC}/COPYING
|
||||
|
||||
RUN_DEPENDS= zip:archivers/zip
|
||||
|
||||
.if ${:!diff --version 2>/dev/null | grep -c GNU\ diffutils || :!} < 1
|
||||
EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src_diffviewer_ydiff.c
|
||||
RUN_DEPENDS+= gdiff:textproc/diffutils
|
||||
.endif
|
||||
|
||||
USES= gmake gnome libtool perl5 pkgconfig python shebangfix tar:xz
|
||||
SHEBANG_FILES= ${WRKSRC}/src/vfs/extfs/helpers/s3+.in \
|
||||
${WRKSRC}/src/vfs/extfs/helpers/uc1541
|
||||
@ -32,7 +37,7 @@ OPTIONS_SINGLE_SCREEN= SLANG NCURSES
|
||||
OPTIONS_SUB= yes
|
||||
|
||||
ASPELL_DESC= Aspell support for internal editor
|
||||
EDITOR_DESC= Build with internal editor
|
||||
EDITOR_DESC= Build with internal text editor
|
||||
EXTATTR_DESC= Extended attributes support
|
||||
SCREEN_DESC= Screen library
|
||||
SFTP_DESC= Support for SFTP (via libssh)
|
||||
@ -94,11 +99,4 @@ post-install-X11-on:
|
||||
${STAGEDIR}${PREFIX}/share/pixmaps/
|
||||
${INSTALL_DATA} ${FILESDIR}/${PORTNAME}.desktop ${STAGEDIR}${DESKTOPDIR}
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1200030
|
||||
EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src_diffviewer_ydiff.c
|
||||
RUN_DEPENDS+= gdiff:textproc/diffutils
|
||||
.endif
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
.include <bsd.port.mk>
|
||||
|
Loading…
Reference in New Issue
Block a user