File tree Expand file tree Collapse file tree 5 files changed +5
-7
lines changed Expand file tree Collapse file tree 5 files changed +5
-7
lines changed Original file line number Diff line number Diff line change 11ebin /
2- html /
32test /tmp
43* .o
54* .so
Original file line number Diff line number Diff line change @@ -34,13 +34,12 @@ NIF_SRC=\
3434
3535clean :
3636rm -f sundown/src/* .o sundown/html/* .o src/* .o
37- rm -f share /markdown.so
37+ rm -f priv /markdown.so
3838rm -rf $(EBIN_DIR )
3939rm -rf test/tmp
4040@ echo
4141
42-
43- share/markdown.so : sundown/libsundown.so ${NIF_SRC}
42+ priv/markdown.so : sundown/libsundown.so ${NIF_SRC}
4443$(CC ) $(CFLAGS ) $(ERLANG_FLAGS ) -shared $(OPTIONS ) -o $@ $(SUNDOWN_OBJS ) $(NIF_SRC )
4544
4645.PHONY : clean
Original file line number Diff line number Diff line change @@ -2,8 +2,8 @@ defmodule Markdown do
22 @ on_load { :init , 0 }
33
44 def init do
5- file = Path . expand ( '../../share/markdown' , __FILE__ )
6- :ok = :erlang . load_nif ( String . to_char_list! ( file ) , 1 )
5+ path = :filename . join ( :code . priv_dir ( :ex_doc ) , 'markdown' )
6+ :ok = :erlang . load_nif ( path , 1 )
77 end
88
99 def to_html ( _ ) do
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ defmodule Mix.Tasks.Compile.Sundown do
22 @ shortdoc "Compiles sundown that ships with ExDoc"
33
44 def run ( _ ) do
5- Mix . shell . info System . cmd ( "make share /markdown.so" )
5+ Mix . shell . info System . cmd ( "make priv /markdown.so" )
66 end
77end
88
File renamed without changes.
You can’t perform that action at this time.
0 commit comments