Bug 11856 - Busybox static build fails due to missing libtirpc
Summary: Busybox static build fails due to missing libtirpc
Status: RESOLVED WORKSFORME
Alias: None
Product: buildroot
Classification: Unclassified
Component: Other (show other bugs)
Version: 2019.02.2
Hardware: All Linux
: P5 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-10 03:59 UTC by Pete Morici
Modified: 2019-05-10 07:29 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pete Morici 2019-05-10 03:59:54 UTC
The busybox build fails if the CONFIG_STATIC option is selected in the busybox config.  The failure is caused by a missing static library libtirpc.

The libtirpc package doesn't build a static version by default.  The --enable-static option needs to be added to LIBTIRPC_CONF_OPTS in package/libtirpc/libtirpc.mk
Comment 1 Thomas Petazzoni 2019-05-10 07:29:22 UTC
This is not a bug. By default Buildroot has the option BR2_SHARED_LIBS=y, which means "build only shared libraries, link everything dynamically".

If you set BR2_STATIC_LIBS=y instead, then only static libraries will be built, and everything will be statically linked.

If you set BR2_SHARED_STATIC_LIBS=y, then both static and shared libraries will be built (when possible: some sub-par build systems only allow building either static or shared libs, not both), and programs will generally be linked dynamically, unless their build system explicitly links statically.