forked from sekimura/text-markdown-discount
/
INSTALL.Discount
39 lines (26 loc) · 910 Bytes
/
INSTALL.Discount
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
"Discount" is a C implementation of the Markdown markup language maintained
by David Parsons.
http://www.pell.portland.or.us/~orc/Code/markdown/
The "Makefile", at least in version 1.3.1, doesn't includes a way to create
a shared library so that I'd like to keep a note how I did it.
Linux
-----
0. run configure.sh
1. put '-fPIC' into CC options and make the first line as below:
CC=cc -fPIC -I. -L.
2. add a line to create libmarkdown.so into MKDLIB block
$(MKDLIB): $(OBJS)
$(AR) crv $(MKDLIB) $(OBJS)
$(RANLIB) $(MKDLIB)
$(CC) -shared -o libmarkdown.so $(OBJS)
Mac OS X
--------
0. run configure.sh
1. add a line to create libmarkdown.dynlib into MKDLIB block
$(MKDLIB): $(OBJS)
$(AR) crv $(MKDLIB) $(OBJS)
$(RANLIB) $(MKDLIB)
$(CC) -dynaliclib -o libmarkdown.dynlib $(OBJS)
Note
----
Using libtools might be a good solution, but I'm not sure how to do it for now.