M
M
mainentrypoint2020-09-18 15:10:59
C++ / C#
mainentrypoint, 2020-09-18 15:10:59

How to solve the problem with a deprecated function?

Good afternoon. There is a libpng library that I link with my program when I build it. At the linking stage, the following message appears:

/home/projects/smartbot/game/libs/libpng/lib64/libpng.so: undefined reference to `[email protected]_2.29'

I, not knowing that libraries can also request subroutines of a certain version of the library , thought that for some reason the standard library with mathematics was not connected. The build flag -lmgave a negative response:
/home/projects/smartbot/game/libs/libpng/lib64/libpng.so: undefined reference to `[email protected]_2.29'

Next, I went to check the version of glibc:
[email protected]:~$ ldd --version
ldd (Ubuntu GLIBC 2.27-3ubuntu1) 2.27

This is the latest version in the repository, so I was able to upgrade to a higher version
. From this I concluded that the version of the standard library is too low. My attempts to download and build glibc 2.29 from source have failed because of my not yet very high knowledge of working with tools and linux in general, so I decided to ask here
Maybe it's worth installing using apt ? Where to look for library files or include folders in this case ? Thank you for your attention

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
res2001, 2020-09-18
@res2001

Install libpng from the packages on your system, put a dev package for it, and use it in your project.
The packages contain the version of libpng that is compatible with your system.
glibc is tightly coupled to the kernel, so you can't just build it and change the version. It comes with the kernel.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question