浏览代码

package/tini: compile executable static

One usecase for tini is as the init process for a container which has
a single executable and no C runtime library. It therefore needs to be
independent of any C runtime library within the container.

Previously, we didn't build statically to avoid problems with
BR2_SHARED_LIBS=y. However, it turns out that tini can successfully link
statically even with glibc and BR2_SHARED_LIBS=y, because libc.a is
still included in staging, and tini doesn't use any NSS functionality.

Signed-off-by: Simon Rowe <simon.rowe@citrix.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Simon Rowe 5 年之前
父节点
当前提交
e4732222e4
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      package/tini/tini.mk

+ 1 - 0
package/tini/tini.mk

@@ -10,6 +10,7 @@ TINI_LICENSE = MIT
 TINI_LICENSE_FILES = LICENSE
 
 TINI_CFLAGS = $(TARGET_CFLAGS) \
+	-static \
 	-DTINI_VERSION=\"$(TINI_VERSION)\" \
 	-DTINI_GIT=\"\"