On Thu, 09 Jun 2016 at 00:11:36 -0400, Jeremy Bicha wrote:
> The below patch works for me. I don't know a lot about SELinux on
> Ubuntu except that most Ubuntu users don't use it.
Thanks for the report, but this is the wrong fix. Please try this
pseudo-patch:
-bwrap_LDFLAGS = $(SELINUX_LIBS)
+bwrap_LDADD = $(SELINUX_LIBS)
The bug is that when it's linked:
gcc -Wall -Werror=missing-prototypes -g -O2 -fstack-protector-strong -Wformat
-Werror=format-security -lselinux -Wl,-Bsymbolic-functions -Wl,-z,relro -o
bwrap bwrap-bubblewrap.o bwrap-bind-mount.o bwrap-network.o bwrap-utils.o
the library comes before the objects on the linker line, which means it is
not used to satisfy dependencies from those objects on linkers that default
to -Wl,--as-needed (which I think Ubuntu's does).
I can reproduce this on Debian with CC="gcc -Wl,--as-needed". I'll send
a fix upstream, and upload a fix to Debian when the current version has
migrated to testing.
S