[Qt-interest] qmake issue: getting rid of INSTALL_ROOT for install target

Mandeep Sandhu mandeepsandhu.chd at gmail.com
Tue Jun 22 16:34:20 CEST 2010


> And that you posted your question this morning. Please give it 7 days for
> people to have a change to reply.

Oops! I forgot that clause! :)
>
> I don't understand why your $PWD was added. That's why I didn't reply. I don't
> know what's wrong.

I'll make a sample app to replicate this issue and post the src here.
Lets see if its something specific to my setup alone.

Thanks as always.

Regards,
-mandeep

>
>>
>> Thanks,
>> -mandeep
>>
>>
>> On Tue, Jun 22, 2010 at 1:53 PM, Mandeep Sandhu
>>
>> <mandeepsandhu.chd at gmail.com> wrote:
>> > Hi All,
>> >
>> > I have a simple .pro firle for my lib. Here's the relevant bit:
>> >
>> > mylib.pro
>> > ========
>> > include (common.pri)
>> >
>> > TARGET = mylib
>> > ...
>> > ...
>> > INSTALLPATH     = $$INSTALLDIR/$$TARGET
>> > target.path     = $$INSTALLPATH/lib
>> > headers.path    = $$INSTALLPATH/include
>> > headers.files   = <header file names>
>> >
>> > INSTALLS       += headers target
>> >
>> >
>> > common.pri
>> > ==========
>> > ...
>> > INSTALLDIR = /home/me/test/install
>> >
>> > This generates a makefile which has a install rule, which is causing
>> > me problems. I'm posting a snippet of the header install target:
>> >
>> > install_headers: first FORCE
>> >    @$(CHK_DIR_EXISTS)
>> > $(INSTALL_ROOT)/home/me/test/mylib/src//home/me/test/install/include/
>> >
>> > || $(MKDIR)
>> > || $(INSTALL_ROOT)/home/me/test/mylib/src//home/me/test/install/include/
>> >
>> > This causes make to install stuff in the src dir (where Makefile is)
>> > and NOT under /home/me/test/install!!!
>> >
>> > Why does qmake prepend $(INSTALL_ROOT)/$(PWD) to the install target?
>> > Is there a way to alter this behavior?
>> >
>> > Basically I would like to use absolute paths for specifying my build
>> > and install dirs. If I use relative paths then it's not a problem, but
>> > then I have to prepend "../" each time I go into a subdir (which looks
>> > messy and error prone).
>> >
>> > Googling revealed a similar problem related long ago:
>> > http://lists.trolltech.com/pipermail/qt-interest/2009-February/002009.htm
>> > l (the associated issue reported -
>> > http://bugreports.qt.nokia.com/browse/QTBUG-3650)
>> >
>> > What are the other alternatives for using absolute paths for install
>> > directive using .pro file (other than altering the makefile with some
>> > external script)?
>> >
>> > Any pointers will be appreciated.
>> >
>> > Thanks,
>> > -mandeep
>
> --
> Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
>  Senior Product Manager - Nokia, Qt Development Frameworks
>      PGP/GPG: 0x6EF45358; fingerprint:
>      E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>




More information about the Qt-interest-old mailing list