Skip to content

Commit 3e6be02

Browse files
committed
---
yaml --- r: 146390 b: refs/heads/try2 c: 7f31b07 h: refs/heads/master v: v3
1 parent ed37ddf commit 3e6be02

File tree

5 files changed

+33
-18
lines changed

5 files changed

+33
-18
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: 2b9c7742b919d97dd2d720eef0c0785c799e9546
8+
refs/heads/try2: 7f31b079e5cf36ea7852032a14fc4e4650420ec3
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/mk/rt.mk

Lines changed: 28 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -92,14 +92,7 @@ RUNTIME_CXXS_$(1)_$(2) := \
9292
rt/rust_android_dummy.cpp \
9393
rt/rust_test_helpers.cpp
9494

95-
RUNTIME_CS_$(1)_$(2) := rt/sundown/src/autolink.c \
96-
rt/sundown/src/buffer.c \
97-
rt/sundown/src/stack.c \
98-
rt/sundown/src/markdown.c \
99-
rt/sundown/html/houdini_href_e.c \
100-
rt/sundown/html/houdini_html_e.c \
101-
rt/sundown/html/html_smartypants.c \
102-
rt/sundown/html/html.c
95+
RUNTIME_CS_$(1)_$(2) :=
10396

10497
RUNTIME_S_$(1)_$(2) := rt/arch/$$(HOST_$(1))/_context.S \
10598
rt/arch/$$(HOST_$(1))/record_sp.S
@@ -109,8 +102,6 @@ RT_BUILD_DIR_$(1)_$(2) := $$(RT_OUTPUT_DIR_$(1))/stage$(2)
109102
RUNTIME_DEF_$(1)_$(2) := $$(RT_OUTPUT_DIR_$(1))/rustrt$$(CFG_DEF_SUFFIX_$(1))
110103
RUNTIME_INCS_$(1)_$(2) := -I $$(S)src/rt -I $$(S)src/rt/isaac -I $$(S)src/rt/uthash \
111104
-I $$(S)src/rt/arch/$$(HOST_$(1)) \
112-
-I $$(S)src/rt/sundown/src \
113-
-I $$(S)src/rt/sundown/html \
114105
-I $$(S)src/libuv/include
115106
RUNTIME_OBJS_$(1)_$(2) := $$(RUNTIME_CXXS_$(1)_$(2):rt/%.cpp=$$(RT_BUILD_DIR_$(1)_$(2))/%.o) \
116107
$$(RUNTIME_CS_$(1)_$(2):rt/%.c=$$(RT_BUILD_DIR_$(1)_$(2))/%.o) \
@@ -242,6 +233,33 @@ $$(LIBUV_LIB_$(1)): $$(LIBUV_DEPS) $$(LIBUV_MAKEFILE_$(1))
242233
NO_LOAD="$$(LIBUV_NO_LOAD)" \
243234
V=$$(VERBOSE)
244235
endif
236+
237+
SUNDOWN_NAME_$(1) := $$(call CFG_STATIC_LIB_NAME_$(1),sundown)
238+
SUNDOWN_DIR_$(1) := $$(RT_OUTPUT_DIR_$(1))/sundown
239+
SUNDOWN_LIB_$(1) := $$(SUNDOWN_DIR_$(1))/$$(SUNDOWN_NAME_$(1))
240+
241+
SUNDOWN_CS_$(1) := rt/sundown/src/autolink.c \
242+
rt/sundown/src/buffer.c \
243+
rt/sundown/src/stack.c \
244+
rt/sundown/src/markdown.c \
245+
rt/sundown/html/houdini_href_e.c \
246+
rt/sundown/html/houdini_html_e.c \
247+
rt/sundown/html/html_smartypants.c \
248+
rt/sundown/html/html.c
249+
250+
SUNDOWN_OBJS_$(1) := $$(SUNDOWN_CS_$(1):rt/%.c=$$(SUNDOWN_DIR_$(1))/%.o)
251+
252+
$$(SUNDOWN_DIR_$(1))/%.o: rt/%.c
253+
@$$(call E, compile: $$@)
254+
@mkdir -p $$(@D)
255+
$$(Q)$$(call CFG_COMPILE_C_$(1), $$@, \
256+
-I $$(S)src/rt/sundown/src -I $$(S)src/rt/sundown/html \
257+
$$(RUNTIME_CFLAGS_$(1))) $$<
258+
259+
$$(SUNDOWN_LIB_$(1)): $$(SUNDOWN_OBJS_$(1))
260+
@$$(call E, link: $$@)
261+
$$(Q)$$(AR_$(1)) rcs $$@ $$^
262+
245263
endef
246264

247265
# Instantiate template for all stages/targets

branches/try2/mk/tools.mk

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,12 @@ $$(TLIB$(1)_T_$(4)_H_$(3))/$(CFG_LIBRUSTDOC_$(4)): \
5757
$$(RUSTDOC_LIB) $$(RUSTDOC_INPUTS) \
5858
$$(SREQ$(1)_T_$(4)_H_$(3)) \
5959
$$(TLIB$(1)_T_$(4)_H_$(3))/$(CFG_LIBRUSTC_$(4)) \
60+
$$(SUNDOWN_LIB_$(4)) \
6061
| $$(TLIB$(1)_T_$(4)_H_$(3))/
6162
@$$(call E, compile_and_link: $$@)
6263
$$(call REMOVE_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTDOC_GLOB_$(4)),$$(notdir $$@))
63-
$$(STAGE$(1)_T_$(4)_H_$(3)) $$(WFLAGS_ST$(1)) --out-dir $$(@D) $$< && touch $$@
64+
$$(STAGE$(1)_T_$(4)_H_$(3)) $$(WFLAGS_ST$(1)) \
65+
-L $$(SUNDOWN_DIR_$(4)) --out-dir $$(@D) $$< && touch $$@
6466
$$(call LIST_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTDOC_GLOB_$(4)),$$(notdir $$@))
6567

6668
$$(TBIN$(1)_T_$(4)_H_$(3))/rustdoc$$(X_$(4)): \

branches/try2/src/librustdoc/html/markdown.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ struct buf {
6969
}
7070

7171
// sundown FFI
72+
#[link_args = "-lsundown"]
7273
extern {
7374
fn sdhtml_renderer(callbacks: *sd_callbacks,
7475
options_ptr: *html_renderopt,

branches/try2/src/rt/rustrt.def.in

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -183,12 +183,6 @@ rust_uv_pipe_init
183183
rust_uv_signal_init
184184
rust_uv_signal_start
185185
rust_uv_signal_stop
186-
sdhtml_renderer
187-
sd_markdown_new
188-
sd_markdown_render
189-
sd_markdown_free
190-
bufrelease
191-
bufnew
192186
rust_take_dlerror_lock
193187
rust_drop_dlerror_lock
194188
rust_uv_pipe_open

0 commit comments

Comments
 (0)