Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 849a836

Browse files
committedAug 1, 2022
Remove duplicates from defined-symbols.txt
In WebAssembly#311, it became apparent that duplicate symbol definitions were becoming unwieldy. This change merges all duplicates using `uniq`.
1 parent 6575e7d commit 849a836

File tree

2 files changed

+1
-16
lines changed

2 files changed

+1
-16
lines changed
 

‎Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -527,7 +527,7 @@ check-symbols: startup_files libc
527527
@# Ignore certain llvm builtin symbols such as those starting with __mul
528528
@# since these dependencies can vary between llvm versions.
529529
"$(NM)" --defined-only "$(SYSROOT_LIB)"/libc.a "$(SYSROOT_LIB)"/libwasi-emulated-*.a "$(SYSROOT_LIB)"/*.o \
530-
|grep ' [[:upper:]] ' |sed 's/.* [[:upper:]] //' |LC_ALL=C sort > "$(DEFINED_SYMBOLS)"
530+
|grep ' [[:upper:]] ' |sed 's/.* [[:upper:]] //' |LC_ALL=C sort |uniq > "$(DEFINED_SYMBOLS)"
531531
for undef_sym in $$("$(NM)" --undefined-only "$(SYSROOT_LIB)"/libc.a "$(SYSROOT_LIB)"/libc-*.a "$(SYSROOT_LIB)"/*.o \
532532
|grep ' U ' |sed 's/.* U //' |LC_ALL=C sort |uniq); do \
533533
grep -q '\<'$$undef_sym'\>' "$(DEFINED_SYMBOLS)" || echo $$undef_sym; \

‎expected/wasm32-wasi/defined-symbols.txt

-15
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,6 @@ __des_setkey
3737
__do_des
3838
__duplocale
3939
__env_rm_add
40-
__env_rm_add
41-
__env_rm_add
42-
__env_rm_add
4340
__exp2f_data
4441
__exp_data
4542
__expo2
@@ -70,8 +67,6 @@ __fsmu8
7067
__ftello
7168
__ftello_unlocked
7269
__funcs_on_exit
73-
__funcs_on_exit
74-
__funcs_on_quick_exit
7570
__funcs_on_quick_exit
7671
__futimesat
7772
__fwritable
@@ -127,7 +122,6 @@ __isxdigit_l
127122
__lctrans
128123
__lctrans_cur
129124
__lctrans_impl
130-
__lctrans_impl
131125
__ldexp_cexp
132126
__ldexp_cexpf
133127
__lgamma_r
@@ -199,22 +193,16 @@ __sinl
199193
__small_printf
200194
__stderr_FILE
201195
__stderr_used
202-
__stderr_used
203-
__stderr_used
204196
__stdin_FILE
205197
__stdin_used
206-
__stdin_used
207198
__stdio_close
208199
__stdio_exit
209-
__stdio_exit
210200
__stdio_exit_needed
211201
__stdio_read
212202
__stdio_seek
213203
__stdio_write
214204
__stdout_FILE
215205
__stdout_used
216-
__stdout_used
217-
__stdout_used
218206
__stdout_write
219207
__stpcpy
220208
__stpncpy
@@ -310,7 +298,6 @@ __wasilibc_deinitialize_environ
310298
__wasilibc_dttoif
311299
__wasilibc_ensure_environ
312300
__wasilibc_environ
313-
__wasilibc_environ
314301
__wasilibc_fd_renumber
315302
__wasilibc_find_abspath
316303
__wasilibc_find_relpath
@@ -322,7 +309,6 @@ __wasilibc_link
322309
__wasilibc_link_newat
323310
__wasilibc_link_oldat
324311
__wasilibc_maybe_reinitialize_environ_eagerly
325-
__wasilibc_maybe_reinitialize_environ_eagerly
326312
__wasilibc_nocwd___wasilibc_rmdirat
327313
__wasilibc_nocwd___wasilibc_unlinkat
328314
__wasilibc_nocwd_faccessat
@@ -359,7 +345,6 @@ _exit
359345
_flushlbf
360346
_initialize
361347
_start
362-
_start
363348
a64l
364349
abort
365350
abs

0 commit comments

Comments
 (0)
Please sign in to comment.