On 2024/12/13 15:24, ComixHe wrote:

On 12/13/24 14:39, Gao Xiang wrote:
Hi Comix,

On 2024/12/13 14:32, ComixHe wrote:
Some of the symbols required by erofsfuse are provided by liberofs.
When option 'enable-static-fuse' is set, all these object file should be
exported to liberofsfuse.a

Could you give more hints why `lib_LIBRARIES` doesn't work?
Certainly.

Today, I attempted to build the latest stable version of erofs-utils and
export liberofsfuse.a.

However, when using liberofsfuse.a, the linker there reported several
errors:

(.text+0xff): undefined reference to `g_sbi'
/usr/bin/ld: (.text+0x110): undefined reference to `g_sbi'
/usr/bin/ld: (.text+0x116): undefined reference to `cfg'
/usr/bin/ld: (.text+0x12d): undefined reference to
`erofs_read_inode_from_disk'
/usr/bin/ld: (.text+0x146): undefined reference to `erofs_listxattr'
/usr/bin/ld: (.text+0x1ae): undefined reference to `erofs_listxattr'
/usr/bin/ld: (.text+0x1e5): undefined reference to `erofs_msg'
/usr/bin/ld: (.text+0x1ed): undefined reference to
`erofs_read_inode_from_disk'

I adjusted the build script according to the patch content, then rebuilt
both erofs-utils and my project.

After these fixes, everything worked as expected.

Ok, thanks.  Maybe I think it should be called
ENABLE_LIBEROFSFUSE since I guess it could produce
a dynamic library with libtool too?

Anyway, it's not a case for general end users, as
long as it resolves your issue.  I will apply.

Thanks,
Gao Xiang


I fail to get the point why `lib_LTLIBRARIES` is needed for
static libraries...

https://www.gnu.org/software/automake/manual/1.7.2/html_node/A-Library.html


Thanks,
Gao Xiang

Reply via email to