瀏覽代碼

More flags for the static build to shrink the final binary

default_compile_flags
vector-of-bool 5 年之前
父節點
當前提交
df92921326
共有 1 個檔案被更改,包括 7 行新增1 行删除
  1. +7
    -1
      tools/gcc-9-static-rel.jsonc

+ 7
- 1
tools/gcc-9-static-rel.jsonc 查看文件

"warning_flags": [ "warning_flags": [
"-Werror", "-Werror",
], ],
"flags": [
"-fdata-sections",
"-ffunction-sections",
"-Os"
],
"cxx_flags": [ "cxx_flags": [
"-fconcepts", "-fconcepts",
"-std=c++2a",
"-std=c++2a"
], ],
"link_flags": [ "link_flags": [
"-static", "-static",
"-ldl", "-ldl",
// WORKAROUND: https://sourceware.org/legacy-ml/glibc-bugs/2018-09/msg00009.html // WORKAROUND: https://sourceware.org/legacy-ml/glibc-bugs/2018-09/msg00009.html
"-Wl,-u,pthread_mutex_lock,-u,pthread_mutex_unlock,-u,pthread_self", "-Wl,-u,pthread_mutex_lock,-u,pthread_mutex_unlock,-u,pthread_self",
"-Wl,--gc-sections,--strip-all"
], ],
"optimize": true "optimize": true
} }

Loading…
取消
儲存