import discount, from maintainer Scott Vokes with minor tweaks:
This is David Loren Parsons's implementation of John Gruber's Markdown text to html language. There's not much here that differentiates it from any of the existing Markdown implementations except that it's written in C instead of one of the vast flock of scripting languages that are fighting it out for the Perl crown. Markdown provides a library that gives you formatting functions suitable for marking down entire documents or lines of text, a command-line program that you can use to mark down documents interactively or from a script, and a tiny suite of example programs that show how to fully utilize the markdown library.
This commit is contained in:
parent
51eae6244a
commit
c565dc3c04
32
textproc/discount/Makefile
Normal file
32
textproc/discount/Makefile
Normal file
@ -0,0 +1,32 @@
|
||||
# $OpenBSD: Makefile,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
|
||||
COMMENT = fast C implementation of Markdown
|
||||
|
||||
DISTNAME = discount-1.3.5
|
||||
CATEGORIES = textproc
|
||||
|
||||
HOMEPAGE = http://www.pell.portland.or.us/~orc/Code/markdown/
|
||||
|
||||
MAINTAINER = Scott Vokes <vokes.s@gmail.com>
|
||||
|
||||
# BSD
|
||||
PERMIT_PACKAGE_CDROM = Yes
|
||||
PERMIT_PACKAGE_FTP = Yes
|
||||
PERMIT_DISTFILES_CDROM =Yes
|
||||
PERMIT_DISTFILES_FTP = Yes
|
||||
|
||||
WANTLIB += c
|
||||
|
||||
MASTER_SITES = http://www.pell.portland.or.us/~orc/Code/markdown/
|
||||
|
||||
CONFIGURE_STYLE = simple
|
||||
CONFIGURE_SCRIPT = configure.sh
|
||||
CONFIGURE_ARGS += ${CONFIGURE_SHARED}
|
||||
|
||||
INSTALL_TARGET = install.everything
|
||||
REGRESS_TARGET = test
|
||||
|
||||
pre-configure:
|
||||
@perl -pi -e 's,\./markdown,\./discount,' ${WRKSRC}/tests/*.t
|
||||
|
||||
.include <bsd.port.mk>
|
5
textproc/discount/distinfo
Normal file
5
textproc/discount/distinfo
Normal file
@ -0,0 +1,5 @@
|
||||
MD5 (discount-1.3.5.tar.gz) = IDbEM2jjxRFCBhArnskcUA==
|
||||
RMD160 (discount-1.3.5.tar.gz) = 2wm87/8H0kd9JLk/6lWSnh+DwDw=
|
||||
SHA1 (discount-1.3.5.tar.gz) = kvTbT0yfcKklP6jJBbyjioD9Nw4=
|
||||
SHA256 (discount-1.3.5.tar.gz) = O6yaGc6BJrckB+NLQoprnulAGQdt1tsDlAosV0VVBlY=
|
||||
SIZE (discount-1.3.5.tar.gz) = 70287
|
32
textproc/discount/patches/patch-Makefile_in
Normal file
32
textproc/discount/patches/patch-Makefile_in
Normal file
@ -0,0 +1,32 @@
|
||||
$OpenBSD: patch-Makefile_in,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
--- Makefile.in.orig Sun Apr 12 18:45:50 2009
|
||||
+++ Makefile.in Sun Apr 12 18:48:28 2009
|
||||
@@ -7,7 +7,7 @@ MANDIR=@mandir@
|
||||
LIBDIR=@libdir@
|
||||
INCDIR=@prefix@/include
|
||||
|
||||
-PGMS=markdown
|
||||
+PGMS=discount
|
||||
SAMPLE_PGMS=mkd2html makepage
|
||||
@THEME@SAMPLE_PGMS+= theme
|
||||
MKDLIB=libmarkdown.a
|
||||
@@ -40,15 +40,16 @@ install.man:
|
||||
@INSTALL_DIR@ $(DESTDIR)/$(MANDIR)/man7
|
||||
@INSTALL_DATA@ markdown.7 mkd-extensions.7 $(DESTDIR)/$(MANDIR)/man7
|
||||
@INSTALL_DIR@ $(DESTDIR)/$(MANDIR)/man1
|
||||
- @INSTALL_DATA@ markdown.1 $(DESTDIR)/$(MANDIR)/man1
|
||||
+ @mv markdown.1 discount.1
|
||||
+ @INSTALL_DATA@ discount.1 $(DESTDIR)/$(MANDIR)/man1
|
||||
|
||||
install.everything: install install.man
|
||||
|
||||
version.o: version.c VERSION
|
||||
$(CC) -DVERSION=\"`cat VERSION`\" -c version.c
|
||||
|
||||
-markdown: main.o $(MKDLIB)
|
||||
- $(CC) -o markdown main.o -lmarkdown @LIBS@
|
||||
+discount: main.o $(MKDLIB)
|
||||
+ $(CC) -o discount main.o -lmarkdown @LIBS@
|
||||
|
||||
# example programs
|
||||
@THEME@theme: theme.o $(MKDLIB)
|
12
textproc/discount/patches/patch-cstring_h
Normal file
12
textproc/discount/patches/patch-cstring_h
Normal file
@ -0,0 +1,12 @@
|
||||
$OpenBSD: patch-cstring_h,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
--- cstring.h.orig Fri Apr 3 17:57:34 2009
|
||||
+++ cstring.h Mon Apr 13 10:39:25 2009
|
||||
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
#define STRING(type) struct { type *text; int size, alloc; }
|
||||
|
||||
-#define CREATE(x) T(x) = (void*)(S(x) = (x).alloc = 0)
|
||||
+#define CREATE(x) T(x) = NULL; (S(x) = (x).alloc = 0)
|
||||
#define EXPAND(x) (S(x)++)[(S(x) < (x).alloc) \
|
||||
? (T(x)) \
|
||||
: (T(x) = T(x) ? realloc(T(x), sizeof T(x)[0] * ((x).alloc += 100)) \
|
16
textproc/discount/patches/patch-markdown_1_in
Normal file
16
textproc/discount/patches/patch-markdown_1_in
Normal file
@ -0,0 +1,16 @@
|
||||
$OpenBSD: patch-markdown_1_in,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
--- markdown.1.in.orig Sun Apr 12 18:49:05 2009
|
||||
+++ markdown.1.in Sun Apr 12 18:49:41 2009
|
||||
@@ -1,10 +1,10 @@
|
||||
.\" %A%
|
||||
.\"
|
||||
.Dd January 7, 2008
|
||||
-.Dt MARKDOWN 1
|
||||
+.Dt DISCOUNT 1
|
||||
.Os MASTODON
|
||||
.Sh NAME
|
||||
-.Nm markdown
|
||||
+.Nm discount
|
||||
.Nd text to html conversion tool
|
||||
.Sh SYNOPSIS
|
||||
.Nm
|
12
textproc/discount/patches/patch-markdown_3
Normal file
12
textproc/discount/patches/patch-markdown_3
Normal file
@ -0,0 +1,12 @@
|
||||
$OpenBSD: patch-markdown_3,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
--- markdown.3.orig Sun Apr 12 18:57:11 2009
|
||||
+++ markdown.3 Sun Apr 12 18:57:23 2009
|
||||
@@ -107,7 +107,7 @@ and
|
||||
.Fn mkd_string
|
||||
functions return a MMIOT* on success, null on failure.
|
||||
.Sh SEE ALSO
|
||||
-.Xr markdown 1 ,
|
||||
+.Xr discount 1 ,
|
||||
.Xr mkd-functions 3 ,
|
||||
.Xr markdown 7 ,
|
||||
.Xr mkd-extensions 7 ,
|
12
textproc/discount/patches/patch-markdown_7
Normal file
12
textproc/discount/patches/patch-markdown_7
Normal file
@ -0,0 +1,12 @@
|
||||
$OpenBSD: patch-markdown_7,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
--- markdown.7.orig Sun Apr 12 18:57:14 2009
|
||||
+++ markdown.7 Sun Apr 12 18:57:35 2009
|
||||
@@ -999,7 +999,7 @@ assumes that tabs are set to 4 spaces.
|
||||
John Gruber
|
||||
.%T http://daringfireball.net/
|
||||
.Sh SEE ALSO
|
||||
-.Xr markdown 1 ,
|
||||
+.Xr discount 1 ,
|
||||
.Xr markdown 3 ,
|
||||
.Xr mkd-functions 3 ,
|
||||
.Xr mkd-extensions 7 .
|
11
textproc/discount/pkg/DESCR
Normal file
11
textproc/discount/pkg/DESCR
Normal file
@ -0,0 +1,11 @@
|
||||
This is David Loren Parsons's implementation of John Gruber's Markdown
|
||||
text to html language. There's not much here that differentiates it from
|
||||
any of the existing Markdown implementations except that it's written in
|
||||
C instead of one of the vast flock of scripting languages that are
|
||||
fighting it out for the Perl crown.
|
||||
|
||||
Markdown provides a library that gives you formatting functions suitable
|
||||
for marking down entire documents or lines of text, a command-line
|
||||
program that you can use to mark down documents interactively or from a
|
||||
script, and a tiny suite of example programs that show how to fully
|
||||
utilize the markdown library.
|
23
textproc/discount/pkg/PLIST
Normal file
23
textproc/discount/pkg/PLIST
Normal file
@ -0,0 +1,23 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1.1.1 2009/04/13 20:45:05 sthen Exp $
|
||||
@bin bin/discount
|
||||
@bin bin/makepage
|
||||
@bin bin/mkd2html
|
||||
@bin bin/theme
|
||||
include/mkdio.h
|
||||
lib/libmarkdown.a
|
||||
@man man/man1/discount.1
|
||||
@man man/man1/theme.1
|
||||
@man man/man3/markdown.3
|
||||
@man man/man3/mkd-functions.3
|
||||
@man man/man3/mkd_cleanup.3
|
||||
@man man/man3/mkd_compile.3
|
||||
@man man/man3/mkd_doc_author.3
|
||||
@man man/man3/mkd_doc_date.3
|
||||
@man man/man3/mkd_doc_title.3
|
||||
@man man/man3/mkd_generatehtml.3
|
||||
@man man/man3/mkd_in.3
|
||||
@man man/man3/mkd_string.3
|
||||
@man man/man3/mkd_style.3
|
||||
@man man/man3/mkd_text.3
|
||||
@man man/man7/markdown.7
|
||||
@man man/man7/mkd-extensions.7
|
Loading…
Reference in New Issue
Block a user