1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-18 00:10:04 +00:00

converters/dos2ansi: Add new port

A tool to convert MS-DOS/ANSI.SYS text files for modern terminals.
This commit is contained in:
Felix Palmen 2024-02-11 11:17:34 +01:00
parent 5c518ed652
commit 5482de3747
5 changed files with 76 additions and 0 deletions

View File

@ -20,6 +20,7 @@
SUBDIR += cmios9
SUBDIR += cocot
SUBDIR += convmv
SUBDIR += dos2ansi
SUBDIR += dos2unix
SUBDIR += dosunix
SUBDIR += drg2sbg

View File

@ -0,0 +1,53 @@
PORTNAME= dos2ansi
DISTVERSION= 2.0
CATEGORIES= converters
MASTER_SITES= ${WWW}/releases/download/v${DISTVERSION}/
MAINTAINER= zirias@FreeBSD.org
COMMENT= Converter for old MS-DOS/ANSI.SYS text files
WWW= https://github.com/Zirias/dos2ansi
LICENSE= BSD2CLAUSE
LICENSE_FILE= ${WRKSRC}/LICENSE.txt
FLAVORS= x11 nox11
FLAVOR?= x11
nox11_OPTIONS_EXCLUDE= BITMAP SCALABLE
nox11_PKGNAMESUFFIX= -nox11
x11_OPTIONS_SLAVE= SHOWANSI
x11_RUN_DEPENDS= xterm:x11/xterm
USES= compiler:c11 gmake tar:xz
MAKEFILE= GNUmakefile
ALL_TARGET= strip
CONFLICTS_INSTALL= ${PORTNAME} ${PORTNAME}-nox11
OPTIONS_DEFINE= DOCS HTML MANPAGES NCURSES SHOWANSI
OPTIONS_DEFAULT= MANPAGES NCURSES BITMAP SCALABLE
OPTIONS_GROUP= FONTS
OPTIONS_GROUP_FONTS= BITMAP SCALABLE
OPTIONS_EXCLUDE= ${${FLAVOR}_OPTIONS_EXCLUDE}
OPTIONS_SLAVE= ${${FLAVOR}_OPTIONS_SLAVE}
OPTIONS_SUB= yes
BITMAP_DESC= Add bitmap fonts from x11-fonts/ibmfonts
HTML_DESC= Build and install HTML manpages
NCURSES_DESC= Build with terminfo-based color output
SCALABLE_DESC= Add scalable fonts from x11-fonts/oldschool-pc-fonts
SHOWANSI_DESC= Install showansi script
BITMAP_RUN_DEPENDS= ibmfonts>0:x11-fonts/ibmfonts
HTML_MAKE_ENV= WITH_HTML=1
MANPAGES_MAKE_ENV_OFF= WITH_MAN=0
NCURSES_USES= ncurses
NCURSES_MAKE_ENV= INCLUDES=-I${NCURSESINC}
NCURSES_MAKE_ENV_OFF= WITH_CURSES=0
NCURSES_LDFLAGS= -Wl,--as-needed
SCALABLE_RUN_DEPENDS= oldschool-pc-fonts>0:x11-fonts/oldschool-pc-fonts
SHOWANSI_MAKE_ENV_OFF= WITH_SHOWANSI=0
.include <bsd.port.mk>

View File

@ -0,0 +1,3 @@
TIMESTAMP = 1710187093
SHA256 (dos2ansi-2.0.tar.xz) = a34979621f932fae36b3bfc77ddad26c172e6d05bc68aae865cb3eaf663db70c
SIZE (dos2ansi-2.0.tar.xz) = 74408

View File

@ -0,0 +1,7 @@
A tool to convert MS-DOS/ANSI.SYS text files to modern terminals.
This tool converts MS-DOS text files using ANSI.SYS escape sequences to a
format a modern terminal can display. The output will use a Unicode encoding
of characters and only ANSI SGR escape sequences to set basic foreground and
background colors, intensity and blinking attribute. The input is expected to
use CP-437 or one of the other supported DOS codepages.

View File

@ -0,0 +1,12 @@
bin/dos2ansi
%%SHOWANSI%%bin/showansi
%%SHOWANSI%%@sample %%ETCDIR%%/showansirc.sample
@comment %%DOCSDIR%%/LICENSE.txt
%%PORTDOCS%%%%DOCSDIR%%/README.md
%%HTML%%%%DOCSDIR%%/html/dos2ansi.1.html
%%HTML%%%%SHOWANSI%%%%DOCSDIR%%/html/showansi.1.html
%%SHOWANSI%%%%DATADIR%%/showansi/fonts.bitmap
%%SHOWANSI%%%%DATADIR%%/showansi/fonts.mixed
%%SHOWANSI%%%%DATADIR%%/showansi/fonts.scalable
%%MANPAGES%%share/man/man1/dos2ansi.1.gz
%%MANPAGES%%%%SHOWANSI%%share/man/man1/showansi.1.gz