Master link error on Ubuntu 22.04/24.04

Lodev lodev at ossii.com.tw
Wed Jul 23 05:24:57 UTC 2025


Hi,


We experienced some errors when compiling LibreOffice core (master).

We pulled the latest code from master branch.  Running ./autogen.sh 
with-distro=LibreOfficeLinux --disable-online-update --disable-breakpad

Until this error messages:


[build MOD] sal
/usr/bin/ld: /tmp/lto-llvm-4818d7.o: in function 
`jpeg_common_create_decompress':
jpeg_common.c:(.text.jpeg_common_create_decompress+0x23): undefined 
reference to `jpeg_CreateDecompress'
/usr/bin/ld: /tmp/lto-llvm-4818d7.o: in function 
`jpeg_common_destroy_decompress':
jpeg_common.c:(.text.jpeg_common_destroy_decompress+0x8): undefined 
reference to `jpeg_destroy_decompress'
/usr/bin/ld: /tmp/lto-llvm-4818d7.o: in function 
`jpeg_common_start_decompress':
jpeg_common.c:(.text.jpeg_common_start_decompress+0x19): undefined 
reference to `jpeg_start_decompress'
/usr/bin/ld: /tmp/lto-llvm-4818d7.o: in function `jpeg_common_read_header':
jpeg_common.c:(.text.jpeg_common_read_header+0x20): undefined reference 
to `jpeg_read_header'
/usr/bin/ld: /tmp/lto-llvm-4818d7.o: in function 
`jpeg_common_read_scanlines':
jpeg_common.c:(.text.jpeg_common_read_scanlines+0x27): undefined 
reference to `jpeg_read_scanlines'
/usr/bin/ld: /tmp/lto-llvm-1970ae.o: in function 
`fxcodec::JpegModule::CreateDecoder(pdfium::span<unsigned char const
, 18446744073709551615ul, unsigned char const*>, unsigned int, unsigned 
int, int, bool)':
jpegmodule.cpp:(.text._ZN7fxcodec10JpegModule13CreateDecoderEN6pdfium4spanIKhLm18446744073709551615EPS3_EEjjib+0x217)
: undefined reference to `jpeg_destroy_decompress'
/usr/bin/ld: /tmp/lto-llvm-1970ae.o: in function 
`std::unique_ptr<fxcodec::(anonymous namespace)::JpegDecoder, std::d
efault_delete<fxcodec::(anonymous namespace)::JpegDecoder> 
 >::~unique_ptr()':
jpegmodule.cpp:(.text._ZNSt10unique_ptrIN7fxcodec12_GLOBAL__N_111JpegDecoderESt14default_deleteIS2_EED2Ev+0x21): 
unde
fined reference to `jpeg_destroy_decompress'
/usr/bin/ld: /tmp/lto-llvm-1970ae.o: in function 
`fxcodec::JpegModule::LoadInfo(pdfium::span<unsigned char const, 184
46744073709551615ul, unsigned char const*>)':
jpegmodule.cpp:(.text._ZN7fxcodec10JpegModule8LoadInfoEN6pdfium4spanIKhLm18446744073709551615EPS3_EE+0x184): 
undefine
d reference to `jpeg_destroy_decompress'
/usr/bin/ld: 
jpegmodule.cpp:(.text._ZN7fxcodec10JpegModule8LoadInfoEN6pdfium4spanIKhLm18446744073709551615EPS3_EE+0x1
a5): undefined reference to `jpeg_destroy_decompress'
/usr/bin/ld: /tmp/lto-llvm-1970ae.o: in function `fxcodec::(anonymous 
namespace)::JpegDecoder::InitDecode(bool)':
jpegmodule.cpp:(.text._ZN7fxcodec12_GLOBAL__N_111JpegDecoder10InitDecodeEb+0x1d2): 
undefined reference to `jpeg_destr
oy_decompress'
/usr/bin/ld: 
/tmp/lto-llvm-1970ae.o:jpegmodule.cpp:(.text._ZN7fxcodec12_GLOBAL__N_111JpegDecoder10InitDecodeEb+0x264)
: more undefined references to `jpeg_destroy_decompress' follow
[build MOD] salhelper
[build MOD] scp2
clang++: error: linker command failed with exit code 1 (use -v to see 
invocation)
make[1]: *** 
[/opt/git/libreoffice.core/external/pdfium/Library_pdfium.mk:10: 
/opt/git/libreoffice.core/instdir/progr
am/libpdfiumlo.so] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:301: build] Error 2

The version of libjpeg and libjpeg-turbo in my system is:


ii  libjpeg-dev:amd64                       8c-2ubuntu11 
                         amd64        Independent JPEG Group'
s JPEG runtime library (dependency package)
ii  libjpeg-turbo8:amd64                    2.1.5-2ubuntu2 
                       amd64        libjpeg-turbo JPEG runt
ime library
ii  libjpeg-turbo8-dev:amd64                2.1.5-2ubuntu2 
                       amd64        Development files for t
he libjpeg-turbo JPEG library
ii  libjpeg8:amd64                          8c-2ubuntu11 
                         amd64        Independent JPEG Group'
s JPEG runtime library (dependency package)
ii  libjpeg8-dev:amd64                      8c-2ubuntu11 
                         amd64        Independent JPEG Group'
s JPEG runtime library (dependency package)

Is there any way to solve this?


Thanks, Dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice/attachments/20250723/3d710639/attachment.htm>


More information about the LibreOffice mailing list