diff options
author | Oswald Buddenhagen <oswald.buddenhagen@qt.io> | 2018-08-23 20:21:24 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@qt.io> | 2018-08-30 05:30:17 +0000 |
commit | 999d4d5777b098f9c1f311af4addad910e44ab62 (patch) | |
tree | 0a65c22bf5b46b60089e9a9f7551174680bb87bd /qmake/generators/unix/unixmake2.cpp | |
parent | 19b12ac9c21f4dd079e482c4ed926f51c1776e52 (diff) |
qmake: rework .prl filename construction
instead of trying to reverse-engineer it from the final target including
extension and possible bundle path, construct the basename explicitly.
this avoids that we mangle the filename if the actual target contains a
period for some reason.
Task-number: QTBUG-70097
Change-Id: I0bae9f010ab82e258680830250f8e28656f09d67
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'qmake/generators/unix/unixmake2.cpp')
-rw-r--r-- | qmake/generators/unix/unixmake2.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/qmake/generators/unix/unixmake2.cpp b/qmake/generators/unix/unixmake2.cpp index 2ed1866584..ab946fa439 100644 --- a/qmake/generators/unix/unixmake2.cpp +++ b/qmake/generators/unix/unixmake2.cpp @@ -1244,7 +1244,8 @@ void UnixMakefileGenerator::init2() if(!project->isEmpty("TARGET")) project->values("TARGET").first().prepend(project->first("DESTDIR")); } else if (project->isActiveConfig("staticlib")) { - project->values("TARGET").first().prepend(project->first("QMAKE_PREFIX_STATICLIB")); + project->values("PRL_TARGET") = + project->values("TARGET").first().prepend(project->first("QMAKE_PREFIX_STATICLIB")); project->values("TARGET").first() += "." + project->first("QMAKE_EXTENSION_STATICLIB"); if(project->values("QMAKE_AR_CMD").isEmpty()) project->values("QMAKE_AR_CMD").append("$(AR) $(DESTDIR)$(TARGET) $(OBJECTS)"); @@ -1278,6 +1279,7 @@ void UnixMakefileGenerator::init2() QString prefix; if(!project->isActiveConfig("no_plugin_name_prefix")) prefix = "lib"; + project->values("PRL_TARGET").prepend(prefix + project->first("TARGET")); project->values("TARGET_x.y.z").append(prefix + project->first("TARGET") + "." + project->first("QMAKE_EXTENSION_PLUGIN")); @@ -1291,6 +1293,7 @@ void UnixMakefileGenerator::init2() "." + project->first("VER_MAJ")); project->values("TARGET") = project->values("TARGET_x.y.z"); } else if (!project->isEmpty("QMAKE_HPUX_SHLIB")) { + project->values("PRL_TARGET").prepend("lib" + project->first("TARGET")); project->values("TARGET_").append("lib" + project->first("TARGET") + ".sl"); if(project->isActiveConfig("lib_version_first")) project->values("TARGET_x").append("lib" + project->first("VER_MAJ") + "." + @@ -1300,6 +1303,7 @@ void UnixMakefileGenerator::init2() project->first("VER_MAJ")); project->values("TARGET") = project->values("TARGET_x"); } else if (!project->isEmpty("QMAKE_AIX_SHLIB")) { + project->values("PRL_TARGET").prepend("lib" + project->first("TARGET")); project->values("TARGET_").append(project->first("QMAKE_PREFIX_STATICLIB") + project->first("TARGET") + "." + project->first("QMAKE_EXTENSION_STATICLIB")); if(project->isActiveConfig("lib_version_first")) { @@ -1331,6 +1335,7 @@ void UnixMakefileGenerator::init2() } project->values("TARGET") = project->values("TARGET_x.y.z"); } else { + project->values("PRL_TARGET").prepend("lib" + project->first("TARGET")); project->values("TARGET_").append("lib" + project->first("TARGET") + "." + project->first("QMAKE_EXTENSION_SHLIB")); if(project->isActiveConfig("lib_version_first")) { |