[Interest] Non-movable Qt build
K. Frank
kfrank29.c at gmail.com
Wed Dec 26 20:58:03 CET 2012
Hi Yves!
On Wed, Dec 26, 2012 at 11:15 AM, Yves Bailly <yves ...> wrote:
> Le 26/12/2012 17:05, Bob Hood a écrit :
>> On 12/26/2012 8:14 AM, Yves Bailly wrote:
>>> Is there a way to tell qmake to use something else than those hard-coded paths?
>>
>> http://doc.qt.digia.com/qt/qt-conf.html
>
> Has already stated, this doesn't work - as if "qmake" was not reading at all this file.
> ...
First note, my experience is with older versions, not Qt 5.
As I understand it, it is not practical to move a Qt installation away
from where it is built.
(There is supposedly some tool that you can use to rewrite the
hard-coded paths embedded in the executables. I'm don't know
for sure whether such a tool exists, if it does, I'm not sure it works,
and if it did work, it would still be an incredible hack.)
This has been stated to be by design, and a feature, not a bug.
This makes no sense to me of course. I have had to rebuild Qt
a couple of times in order to relocate an otherwise non-relocatable
Qt installation (and the build process is slow).
Sure, it's okay to have hard-coded absolute paths in the executables,
but they should be used only as a last resort, and should normally
be superseded by a QT_HOME environment variable or the location
of the executable being run or some other such trivially relocatable
mechanism.
But, as I understand it, this battle has been fought already in the past,
and, unfortunately, lost.
Happy (Non-Relocatable) Hacking!
K. Frank
More information about the Interest
mailing list