开发者

How do I find the name of a target DLL or DSO from qmake?

开发者 https://www.devze.com 2023-03-16 20:14 出处:网络
I\'m using Qt 4.7.3.None of the QMAKE_TARGET or TARGET_x.y.z variables are defined. (Is the documentation wrong?)I\'m using the following workaround at the moment:

I'm using Qt 4.7.3. None of the QMAKE_TARGET or TARGET_x.y.z variables are defined. (Is the documentation wrong?) I'm using the following workaround at the moment:

Linux:

$${QMAKE开发者_高级运维_PREFIX_SHLIB}$${TARGET}.so.$${VER_MAJ}.$${VER_MIN}.$${VER_PAT}

Darwin:

$${QMAKE_PREFIX_SHLIB}$${TARGET}.$${VER_MAJ}.$${VER_MIN}.$${VER_PAT}.$${QMAKE_EXTENSION_SHLIB}

I want the string 'libName.so.1.2.3' on Linux, and 'libName.1.2.3.dylib' on OS X. These names are generated by qmake for the final product of a project, but there doesn't seem to be a single variable that contains these complete names, even though Qt's documentation implies there should be.

0

精彩评论

暂无评论...
验证码 换一张
取 消