diff mbox

libfuse: not available for static builds

Message ID 1361873801-8672-1-git-send-email-gustavo@zacarias.com.ar
State Accepted
Commit 3776138c7b3ccc031afcb014a5bf1f2c542ba88f
Headers show

Commit Message

Gustavo Zacarias Feb. 26, 2013, 10:16 a.m. UTC
Unfortunately libfuse uses dl functions exclusively so it can't be used
for static builds so exclude it so.
Fixes:
http://autobuild.buildroot.net/results/a1c3d2b9c436023675c363d9d3b365c95ade0329/

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
---
 package/curlftpfs/Config.in | 5 +++--
 package/libfuse/Config.in   | 6 ++++--
 package/sshfs/Config.in     | 5 +++--
 package/unionfs/Config.in   | 5 +++--
 4 files changed, 13 insertions(+), 8 deletions(-)

Comments

Peter Korsgaard Feb. 26, 2013, 4:22 p.m. UTC | #1
>>>>> "Gustavo" == Gustavo Zacarias <gustavo@zacarias.com.ar> writes:

 Gustavo> Unfortunately libfuse uses dl functions exclusively so it can't be used
 Gustavo> for static builds so exclude it so.
 Gustavo> Fixes:
 Gustavo> http://autobuild.buildroot.net/results/a1c3d2b9c436023675c363d9d3b365c95ade0329/

Huh, that build error is just because of the hardcoded target install
step (why don't we just use make install)?

Did you mean another build error?
Gustavo Zacarias Feb. 26, 2013, 4:26 p.m. UTC | #2
On 02/26/2013 01:22 PM, Peter Korsgaard wrote:

> Huh, that build error is just because of the hardcoded target install
> step (why don't we just use make install)?
> 
> Did you mean another build error?

Yes, but it leads to other errors if we avoid copying libfuse*.so
If you've just got libfuse.a in staging and fuse-using programs link/use
it it breaks anyway because libfuse hardcodes dlopen.
We'd just be translating the build failure to exfat, unionfs and so on...
Regards.
Thomas Petazzoni April 13, 2013, 6:17 p.m. UTC | #3
Peter,

On Tue, 26 Feb 2013 07:16:41 -0300, Gustavo Zacarias wrote:
> Unfortunately libfuse uses dl functions exclusively so it can't be
> used for static builds so exclude it so.
> Fixes:
> http://autobuild.buildroot.net/results/a1c3d2b9c436023675c363d9d3b365c95ade0329/
> 
> Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>

I think we should apply this one. As Gustavo explained in a followup
email in this thread, libfuse doesn't support static link properly. The
build failure happened again today.

Thanks,

Thomas
Peter Korsgaard April 14, 2013, 9:12 p.m. UTC | #4
>>>>> "Gustavo" == Gustavo Zacarias <gustavo@zacarias.com.ar> writes:

 Gustavo> On 02/26/2013 01:22 PM, Peter Korsgaard wrote:
 >> Huh, that build error is just because of the hardcoded target install
 >> step (why don't we just use make install)?
 >> 
 >> Did you mean another build error?

 Gustavo> Yes, but it leads to other errors if we avoid copying
 Gustavo> libfuse*.so If you've just got libfuse.a in staging and
 Gustavo> fuse-using programs link/use it it breaks anyway because
 Gustavo> libfuse hardcodes dlopen.  We'd just be translating the build
 Gustavo> failure to exfat, unionfs and so on...  Regards.

Ok, committed - Thanks.
diff mbox

Patch

diff --git a/package/curlftpfs/Config.in b/package/curlftpfs/Config.in
index e946d0a..0d8e715 100644
--- a/package/curlftpfs/Config.in
+++ b/package/curlftpfs/Config.in
@@ -10,11 +10,12 @@  config BR2_PACKAGE_CURLFTPFS
 	depends on BR2_USE_WCHAR # glib2
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libfuse
 	depends on BR2_USE_MMU # libfuse
+	depends on !BR2_PREFER_STATIC_LIB # libfuse
 	help
 	  CurlFtpFS is a filesystem for accessing FTP hosts based on FUSE
 	  and libcurl.
 
 	  http://curlftpfs.sourceforge.net/
 
-comment "curlftpfs requires a toolchain with LARGEFILE, WCHAR and threads support"
-	depends on !BR2_LARGEFILE || !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS
+comment "curlftpfs requires a toolchain with LARGEFILE, WCHAR, threads and dynamic library support"
+	depends on !BR2_LARGEFILE || !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || BR2_PREFER_STATIC_LIB
diff --git a/package/libfuse/Config.in b/package/libfuse/Config.in
index 5d30892..e42f9e0 100644
--- a/package/libfuse/Config.in
+++ b/package/libfuse/Config.in
@@ -1,5 +1,7 @@ 
 config BR2_PACKAGE_LIBFUSE
 	bool "libfuse"
+	# Really doesn't like static, see fuse/lib/fuse.c
+	depends on !BR2_PREFER_STATIC_LIB
 	depends on BR2_LARGEFILE
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	depends on BR2_USE_MMU # fork()
@@ -8,5 +10,5 @@  config BR2_PACKAGE_LIBFUSE
 
 	  http://fuse.sourceforge.net/
 
-comment "libfuse requires a toolchain with LARGEFILE and threads support"
-        depends on !BR2_LARGEFILE || !BR2_TOOLCHAIN_HAS_THREADS
+comment "libfuse requires a toolchain with LARGEFILE, threads and dyanmic library support"
+        depends on !BR2_LARGEFILE || !BR2_TOOLCHAIN_HAS_THREADS || BR2_PREFER_STATIC_LIB
diff --git a/package/sshfs/Config.in b/package/sshfs/Config.in
index 11b6bb9..b6d5aa6 100644
--- a/package/sshfs/Config.in
+++ b/package/sshfs/Config.in
@@ -9,10 +9,11 @@  config BR2_PACKAGE_SSHFS
 	depends on BR2_USE_WCHAR # glib2
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libfuse
 	depends on BR2_USE_MMU # libfuse
+	depends on !BR2_PREFER_STATIC_LIB # libfuse
 	help
 	  FUSE filesystem client based on the SSH File Transfer Protocol.
 
 	  http://fuse.sourceforge.net/sshfs.html
 
-comment "sshfs requires a toolchain with LARGEFILE, WCHAR and threads support"
-	depends on !BR2_LARGEFILE || !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS
+comment "sshfs requires a toolchain with LARGEFILE, WCHAR, threads and dynamic library support"
+	depends on !BR2_LARGEFILE || !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || BR2_PREFER_STATIC_LIB
diff --git a/package/unionfs/Config.in b/package/unionfs/Config.in
index 2ac7be9..6ceee89 100644
--- a/package/unionfs/Config.in
+++ b/package/unionfs/Config.in
@@ -4,10 +4,11 @@  config BR2_PACKAGE_UNIONFS
 	depends on BR2_LARGEFILE
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libfuse
 	depends on BR2_USE_MMU # libfuse
+	depends on !BR2_PREFER_STATIC_LIB # libfuse
 	help
 	  A userspace unionfs implementation.
 
 	  http://podgorny.cz/moin/UnionFsFuse
 
-comment "unionfs requires a toolchain with LARGEFILE and threads support"
-	depends on !BR2_LARGEFILE || !BR2_TOOLCHAIN_HAS_THREADS
+comment "unionfs requires a toolchain with LARGEFILE, threads and dynamic library support"
+	depends on !BR2_LARGEFILE || !BR2_TOOLCHAIN_HAS_THREADS || BR2_PREFER_STATIC_LIB