PDA

View Full Version : QMake Target extension



gregg
25th February 2011, 23:50
Hi everyone :)

I compile plugins using Qt
my pro file for qmake is basic:

TARGET = mytarget
TEMPLATE = lib

it creates dylib files on a mac, dll on win, etc... everything works fine
but I want to have a custom extension file for all platforms !!
and also don't want all the created files/symlinks on mac for example:

mytarget.1.0.0.dylib
mytarget.1.0.dylib
mytarget.1.dylib
mytarget.dylib

I just want: mytarget.myext
I found that there is a variable in Qmake called TARGET_EXT, so I added in my pro file:
TARGET_EXT = .myext

but nothing changes, same without the dot...
what should I do ?

thanks, greg

wysota
27th February 2011, 08:08
Did you remember about CONFIG+=plugin? Changing the extension is probably a bad idea, by the way. You can override it with QMAKE_EXTENSION_SHLIB if you really want to.

gregg
28th February 2011, 18:18
Thank you, it works with QMAKE_EXTENSION_SHLIB :)