The dynamic library directory specified by gPP-L does not work.

compile: gPP-w-g-o. / bin/linux/main main.cpp-I. / include/-I. / voice/-L. / bin/linux/-L.. / lib/linux/-ldataBaseInterface-lmysqlclient-lhpr-llogsystem-ljson-lcurl-lmsc-lvoiceInterface-lxml

there is no exception in the compilation process, and the dynamic library cannot be found when executing main: . /.. / bin/linux/main: error while loading shared libraries: libhpr.so: cannot open shared object file: No such file or directory
if the terminal uses export or adds a dynamic library path to / etc/ld.so.conf, it can run normally.-L only works at compile time, or do you have to specify an additional dynamic library directory at run time?

< hr >

know that the runtime library directory needs to be specified extra-Wl,--rpath

Mar.21,2021

-L only works at compile time.

generally don't use rpath, because it won't work with another machine.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e7f7dd-a61.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e7f7dd-a61.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?