enzo1982 / mp4v2

Reviving the MP4v2 project...
https://mp4v2.org
Other
140 stars 52 forks source link

Compile Error with Ubuntu 22.04LTS #23

Closed beaster99 closed 1 year ago

beaster99 commented 1 year ago

It's worth noting that I switched to cmake and the installation works on Ubuntu 22.04, after installing cmake

! being overly verbose for other users, this part worked $ sudo apt install cmake $ cmake $ make ! tried make install, here but since the installers are trying to move files to root owned folders, it errors out, switching to root. $ sudo make install


This part did not work prior to using cmake Without cmake... this is information for the dev

Compile Error when running make on xUbuntu ~ 22.04LTS build $ uname -a Linux XUBUNTU 5.15.0-58-generic #64-Ubuntu SMP Thu Jan 5 11:43:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

Tried local user, tried root user, same outcome each time.

$ ./configure $ make

trimmed

/bin/bash ./libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I./include -I./include -I. -I. -Wall -Wformat -g -O2 -fvisibility=hidden -c -o src/mp4file.lo src/mp4file.cpp libtool: compile: g++ -DHAVE_CONFIG_H -I./include -I./include -I. -I. -Wall -Wformat -g -O2 -fvisibility=hidden -c src/mp4file.cpp -fPIC -DPIC -o src/.libs/mp4file.o src/mp4file.cpp: In member function ‘char mp4v2::impl::MP4File::MakeTrackEditName(MP4TrackId, MP4EditId, const char)’: src/mp4file.cpp:4160:17: warning: ‘.edts.elst.entries[’ directive output may be truncated writing 19 bytes into a region of size between 1 and 1024 [-Wformat-truncation=] 4160 | "%s.edts.elst.entries[%u].%s", | ^~~~~~~ In file included from /usr/include/stdio.h:894, from /usr/include/c++/11/cstdio:42, from /usr/include/c++/11/ext/string_conversions.h:43, from /usr/include/c++/11/bits/basic_string.h:6608, from /usr/include/c++/11/string:55, from /usr/include/c++/11/bits/locale_classes.h:40, from /usr/include/c++/11/bits/ios_base.h:41, from /usr/include/c++/11/ios:42, from /usr/include/c++/11/istream:38, from /usr/include/c++/11/fstream:38, from ./libplatform/platform_base.h:6, from ./libplatform/platform_posix.h:31, from ./libplatform/platform.h:24, from ./src/src.h:6, from ./src/impl.h:6, from src/mp4file.cpp:31: /usr/include/x86_64-linux-gnu/bits/stdio2.h:71:35: note: ‘builtin___snprintf_chk’ output 23 or more bytes (assuming 1046) into a destination of size 1024 71 | return builtin_snprintf_chk (s, n, USE_FORTIFY_LEVEL - 1, | ~~~~~^~~~~~~~~~~ 72 | __glibc_objsize (s), fmt, | ~~~~~~~~~ 73 | __va_arg_pack ()); | ~~~~~ /bin/bash ./libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I./include -I./include -I. -I. -Wall -Wformat -g -O2 -fvisibility=hidden -c -o src/mp4file_io.lo src/mp4file_io.cpp libtool: compile: g++ -DHAVE_CONFIG_H -I./include -I./include -I. -I. -Wall -Wformat -g -O2 -fvisibility=hidden -c src/mp4file_io.cpp -fPIC -DPIC -o src/.libs/mp4file_io.o


Regardless of cmake or configure

I'm still getting errors with libmp4v2.so.2 $ mp4into --help mp4info: error while loading shared libraries: libmp4v2.so.2: cannot open shared object file: No such file or directory

enzo1982 commented 1 year ago

The compiler output is a warning, not an error, so the build should still work. The warning is now fixed in commit b8f83d7b.

mp4info: error while loading shared libraries: libmp4v2.so.2: cannot open shared object file: No such file or directory

You probably just need to run ldconfig to make the installed libraries known to the system. That's normal after installing new libraries and not an issue with MP4v2.