while we evaluate the features themselves in precise mode (which is the
reason why they can error out), we do not want them to terminate
cumulative project evaluation.
Change-Id: I70f3e1bcb2ca04a70c74ff484749ca92c1cf6372
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
(cherry picked from qttools/90ee4094161b427c32581bca2f5286edb4fffdb1)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
After 90e7cc172a, QStringList no longer
includes QDataStream.
This also reverts commit c1be0fbe7d, which
did the same in a worse way.
Change-Id: Ib10622b0da3b3450d29fc65dc5356fde75444a8f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
(cherry picked from qttools/376501ae5a86859821c0e89b2e8fbc9906d11e07)
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
As for the #include-parser, the moc-detector's minimal C preprocessor
could be confused by a raw string into ignoring large chunks of code.
Change-Id: Id688e9a1f04628ce75a51a7d15269078c734288e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
If a / wasn't part of a comment-start, it and the character after it
were none the less stepped over. If the character after started an
enclosure, this would duly be missed, leading to mis-parsing of the
subsequent text. As for similar bug recently fixed in findDeps().
Change-Id: Ie5329ec633c23a554b42a6351723c980e27fb9a9
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The C preprocessor allows backslash-newline anywhere and allows
comments anywhere it allows space. Testing wilfully perverse
applications of that revealed qmake's parsing of #include directives
wasn't very robust. So rework to actually follow the rules and add
those tests.
Change-Id: If5cc7bfb65f9994e9ab9ed216dd1ee7285c63934
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The parser in QMakeSourceFileInfo::findDeps() would step over the
closing quote of a string, only to have a for loop then step over the
character just after that closing quote, which was thus never studied;
this could lead to problems in various ways. Fixed that and expanded
findDeps() test to catch regressions.
Task-number: QTBUG-17533
Change-Id: I7dec5222e38fa188495b39376ffee70bc7bbc87f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
This information is outdated.
Change-Id: Ic2e10f7c858eed6f1b7c550995cb29004b4bd280
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Can't sensibly test unless the compiler does support raw strings,
since any test that would catch qmake's (prior) inability to parse raw
strings would necessarily confuse the C++ compiler in the same way.
This even applies (in test app code) to any #if-ery around the raw
string, since tokenization happens before preprocessor directives are
resolved. So the #if-ery on Q_COMPILER_RAW_STRINGS has to be in
tst_qmake.cpp, not the test app it builds.
Change-Id: I4a461f515adff288b54fb273fd9996f9b906d11c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The Visual Studio registry keys are stored in the 32 bit view.
Extend qt_readRegistryKey with an option that enables the caller to
choose the 32 bit or 64 bit registry view.
We now read the Visual Studio registry keys from the 32 bit registry
view even in a 64 bit build.
Adding the next Visual Studio version will become a bit easier.
Change-Id: I7300b992be6058f30a422e3f1fe0bafade6eea54
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
For some reason, the solution generator was looking for the vcproj
files in the source tree. It should look for them in the output tree
instead (suggested by Joerg Bornemann). This should handle both
in-source and out-of-source builds, and the special-case code for
handling out-of-source builds (which had a bug) can be removed.
Task-number: QTBUG-49665
Change-Id: I40b5c5907c52ffb074ccb8f297bb5924eacc1cb0
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
We need to remember where the included file's name starts anyway; if
we move this to before the search for the end, we don't need a
separate variable to keep track of its length.
Change-Id: Ia8d72839ac3fa32f2e748a21ee70dcab614562f4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
When looking for the keyword in a preprocessor directive, we were
checking for non-word characters to find its end. If that check
failed (i.e. we had a word character) we would then check for EOL
(which necessarily failed, on a word character). That made no sense.
However, we genuinely have no interest in a directive with nothing
after the keyword, so do check for EOL after the loop (once we've
skipped spaces after the keyword).
The loop itself was made needlessly complicated by, on finding the end
of the keyword, skipping over later space inside the loop. Moved this
outside the loop.
Change-Id: Iccc2d445bf44deb75604e7fa60f2464e7397d8ed
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The C preprocessor does believe in a # [nothing] line; and we may as
well give up before checking for keywords if we've run out of buffer.
Change-Id: I64dc3ad2808435389d0d7b56dcbc9d92ae72aa6e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
A loop to skip space and comments was meant to break on anything else
but would have not broken on a division operator (where it should) due
to it getting caught in the check for a comment-start, without falling
back suitably when it didn't complete that check.
Managed to contrive a suitably twisted change to findDeps test to
reveal the bug; broken previously, now fixed. Not ideal, as it relied
on another bug to fail previously - backslash-newline shouldn't end a
preprocessing directive line - but it should still pass once that's
fixed, too. Exercising a bug in qmake usually involves code that
won't compile anyway, making it tricky to write a test that reveals
the bug but that passes once it's fixed.
Change-Id: I08a1d7cc5e3d7fd1ac0a48e5c09dfdfbb7580b11
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Principally *(buffer + expr) -> buffer[expr] changes, with some hspace
normalization on affected lines. Made some empty loops more visible.
Pulled out a repeated character class test as a function.
Change-Id: I03d1b633550ad1814fa383d69ea04138dd0f82cd
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
No-one is known to use it - we don't even have a test for it. It
plays poorly with the real preprocessor and it has not produced any
output since at least Qt 4.0 (unless qmake is invoked with at least
one -d flag, drowning the output in level 1 debug output).
This incidentally means no preprocessor directive we care about has an
underscore in its keyword.
Task-number: QTBUG-49487
Change-Id: I123a945c1dfe29d1d3ceee1129cfedc043f2e7d4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Only VcprojGenerator over-rode it; and did so with a replacement
identical to the one on the base, so there was no point to it.
Change-Id: I5b899372247809c82b1cae25817e06c5849cd10d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The Xcode generator iterates trought all libraries and replaces
their suffix (e.g "_debug") with a placeholder that lets Xcode
switch between different library versions depending on the target.
The current way we do this fails when the name of a library happens
to contain the string "_debug" (e.g "qmldbg_debugger"). Since we
replace every occurrence of suffix in the path, we end up
replacing that part as well. The result will be linking errors.
This patch ensures that we only replace the last occurrence of the
suffix in the file path.
Task-number: QTBUG-48961
Change-Id: I9fafbe0ea0ad8b9cfd13448d6b28801106e645ec
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Commit 4bb004de94 broke the linker
options in generated Visual Studio projects.
We need to call fixLibFlags on QMAKE_LIBS and QMAKE_LIBS_PRIVATE.
Task-number: QTBUG-48936
Change-Id: I2f12bf0117d27104cd34f2f43fdeb7b948fa375e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Use indexOf() to match individual characters, which is a lot faster than
QRegExp. As a side effect, don't try to expand what we just inserted.
Change-Id: I964fbd92055f2f2649e7d8ed5739cf1fc7cae927
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
(cherry picked from qtcreator/2cc17a61eb6d0fee80fd388fcc5be03a59e4f2b5)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Qt 5.3 is the minimum requirement these days. Remove all fallback code
from sources and project files.
Change-Id: If6188a471197acadda4d6baee71804ba1a8026c6
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
(cherry picked from qtcreator/847f10e9ccc8c3541782a790e04c85c6b4c701da)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Less typing and less cycles than join(QString) where appropriate
Change-Id: I6ebc0e17e4d7fd9845864dd95b7de4ba4dad6906
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
(cherry picked from qtcreator/6431ab2c799553623ec3fe6a79f1e85484558dd6)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
this fixes an assertion failure with qt4 mingw specs when PATH contains
a "." element.
Task-number: QTCREATORBUG-12528
Change-Id: I2b6b7e02cf38881d40bd78bb0d705f7d58d0736c
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
(cherry picked from qtcreator/d0428a05220ed0550dd84cdb8299a1fb37b0fe72)
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
assigning a relative path to QMAKESPEC or QMAKESPEC_ORIGINAL (in the qt4
windows legacy code) would lead to an assert further down the line.
just ignore such attempts silently.
Task-number: QTCREATORBUG-8477
Change-Id: Ie53d0ef004c743284b85de4e89f112e0161ff4b7
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
(cherry picked from qtcreator/e017a1dc8b2030e509d6198315e9f6a9869667e7)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
just syncing up with qtcreator.
Change-Id: I2bda6961f6f1164bdc58acd78fa3d2221977f0cf
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
(cherry picked from qtcreator/765ad6c3d28813d4baa0aeafd03076ba76557d3d)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
it could be only triggered by abusing the function (no expansion
actually done), and nobody is using this to start with, but still ...
Change-Id: I3d4a23ae4d1eea07955572d8213094e0dc218f6d
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
(cherry picked from qtcreator/cdc2a0f72334268684e0407e9b04b3188e00d4bf)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
This prevents an access to free'd memory when opening qtcreator.pro.
Looks like qml2puppet.pro gets added to that cache in QMakeVfs::writeFile
with part of the including pro-file's filename in it. That part gets
cleaned when that containing ProFile goes out of scope, leaving a key in
QMakeVfs::m_files free'd but accessible.
Change-Id: I80b43d2fbb66c214647497ea97e6e3a587e274d6
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
(cherry picked from qtcreator/336c3159617cdb3edd35021b5fb312d4d43f9a84)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
QProcessEnvironment caches keys, so we must not pass it QStrings created with
fromRawData()
Task-number: QTCREATORBUG-9142
Change-Id: I29fade02f3bc4110fafb1b04d44f2e653951a2ae
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
(cherry picked from qtcreator/99f15f1706868c4b2f84bc4164451bd69b3b8188)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
we execute foreach loops now. this is (mostly) safe nowadays, because
a previous change added precautions against exponential value list
growth, so it's unlikely that two nested loops would keep the cpu busy
for a day as before.
we continue to exclude forever loops and loops with excessive integer
counts.
Task-number: QTBUG-8550
Change-Id: Iaa116086986cc7fd5023834753f791dd205102e5
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
(cherry picked from qttools/dd4d594c787a62fa8aa12695c5d115c71b59bacd)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
ProFileCacheManager::discardFile(s) may remove an entry from
the ProfileCache only when it is unused (which is the case iff
ent->locker is zero).
Change-Id: I9df2079087af6bd0d35dd121db6222e8a6ec9389
Task-number: QTCREATORBUG-14730
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
(cherry picked from qtcreator/dedcd25924743e494055c1e0195aeef0f3983a1d)
(cherry picked from qtcreator/b335b2a083e456e2b44b1e9454a0f4cd41e2a397)
(cherry picked from qtcreator/a027cbcd7051c634a51b6029dcb8a5b4bfe8b046)
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
... and make use of it in qt.prf.
[ChangeLog][qmake][Unix] Added support for relative paths in
QMAKE_RPATHDIR.
Note that this technically breaks backwards compatibility, as relative
paths were previously silently resolved against $$_PRO_FILE_PWD_. This
was not documented and seems rather useless, so i'm not worried.
Change-Id: I855042a8962ab34ad4617899a5b9825af0087f8a
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
msvc-desktop.conf does disable the exception warning for building all
modules, so use the same set of compiler flags for building qmake.
Change-Id: I97026f3cb78e656e8de76e1c8afe19cec6501499
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
It's easier to parse than qglobal.h. The objective is actually to have
macros with parts of the version number, so the major or minor numbers
could be used in other preprocessor macros.
Change-Id: I42e7ef1a481840699a8dffff1404eda1dd5c308d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
the library inside a bundle doesn't have an extension.
this doesn't really fix anything except suppressing the error message,
as we discard the result of the operation anyway.
Change-Id: Idfe3d1714dedb59d9d3e86a65f074e516c431389
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
at least the mingw version we use now interprets the sequence \# as a
literal hashmark, which completely defeats the previous hack.
the new hack escapes the backslash with another backslash, which appears
to work. however, make does *not* remove the additional backslash, so
the result is a bit ugly.
Change-Id: I591a2be443880b162094d04e5a5e624216b59311
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Suffix rules are the old-fashioned way of defining implicit rules for make.
We don't need them as we generate explicit rules for all sources we build.
[ChangeLog][qmake] Makefile output no longer contains implicit
suffix rules, as all sources are built using explicit rules.
Change-Id: I4ecfa5b80c8ae33aea8730836f3baf99dd4951dd
Task-number: QTBUG-30813
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Instead of lumping both Objective-C (.m) and Objective-C++ (.mm) sources
into the same pile, passing them on to the same compiler as for C++ (CXX),
with the C++ flags (CXXFLAGS), we follow Apple's lead and treat them as
variants of the C and C++ languages separately, so that Objective-C
sources are built with CC and with CFLAGS, and Objective-C++ sources
with CXX, and CXXFLAGS.
This lets us remove a lot of duplicated flags and definitions from the
QMAKE_OBJECTIVE_CFLAGS variable, which in 99% of the cases just matched
the C++ equivalent. The remaining Objective-C/C++ flags are added to
CFLAGS/CXXFLAGS, as the compiler will just ignore them when running in
C/C++ mode. This matches Xcode, which also doesn't have a separate build
setting for Objective-C/C++ flags.
The Makefile qmake generator has been rewritten to support Objective-C/C++
fully, by not assuming that we're just iterating over the C and C++
extensions when dealing with compilation rules, precompiled headers, etc.
There's some duplicated logic in this code, as inherent by qmake's already
duplicated code paths, but this can be cleaned up when C++11 support is
mandatory and we can use lambda functions.
Task-number: QTBUG-36575
Change-Id: I4f06576d5f49e939333a2e03d965da54119e5e31
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
as a side effect, this makes the extensions used for searching libraries
configurable under windows (QMAKE_LIB_EXTENSIONS).
Change-Id: I3e64304fcadbfe74d601b50a70a73180c894503e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
first, store the library's full name in the .prl file, like we do on
unix. this is not expected to have any side effects, as QMAKE_PRL_TARGET
was entirely unused under windows so far.
then, rewrite the mingw library handling: instead of letting the linker
resolve the actual libraries, do it ourselves like we do for msvc. we
could not do that before due to the partial file names in the .prl
files: if the library didn't exist at qmake execution time, we'd have to
guess the file extension (the msvc generators never had that problem, as
they know about only one possible extension for libraries anyway).
make use of processPrlFile()'s ability to replace the reference to
the .prl file with the actual library. that way we don't need to
re-assemble the file name from pieces, which was fragile and
inefficient.
QMAKE_*_VERSION_OVERRIDE does not affect libraries coming with .prl
files any more. additionally, it is now used literally (not
numerically), and values less or equal to zero lost their special
meaning as "none" - this isn't a problem, because that's the default
anyway, and there is no need to override bogus versions from .prl files
any more.
no changelog for that, as i found no public traces of that feature
outside qtbase.
[ChangeLog][qmake][Windows] Libraries coming with .prl files can now
have non-standard file extensions and a major version of zero.
[ChangeLog][qmake][Windows][Important Behavior Changes] The .prl files
written by earlier versions of Qt cannot be used any more. This will
affect you if you depend on 3rd party libraries which come with .prl
files. Patch up QMAKE_PRL_TARGET to contain the complete file name of
the library, and replace any /LIBPATH: in QMAKE_PRL_LIBS with -L.
(the part about /LIBPATH: actually refers to the next commit.)
Change-Id: I07399341bff0609cb6db9660cbc62b141fb2ad96
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
don't look up the files and normalize the paths multiple times, as this
is inefficient and hard to understand.
on the way, processPrlFile() got unnested, and libExists() got nuked.
note that a missing QMAKE_PRL_TARGET will be now complained about, which
really should never happen.
Change-Id: Ibcd77a7f963204c013548496ecd2d635e1a4baba
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
don't prepend the normalized path to the target name, but replace only
the filename in the original string. this ensures that any variables in
the path are preserved.
Change-Id: I58c2b54b7114bfdbf659e6a6ce3e02c2611900d4
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
the dependency doesn't seem to make any sense.
while the deduplication is a bit naive and thus dangerous, it was
already enabled by default anyway by virtue of link_prl being enabled by
default, so this amounts to a non-change for by far most projects.
use no_lflags_merge to disable it.
Change-Id: Ia441931ddbc41ed617aee21e6fe8821e3448d2bc
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
seems pointless to tear apart the functions, on the way duplicating some
boilerplate.
Change-Id: Ide3697ca1c931e8de607ac48c21cecce4781fe13
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
A \target whose purpose is to link to the top of a
page (and not to a section within a page) works better
as a \keyword, because \target generates a
new html anchor which, in this case, is not tied to
any title element on the page.
A \keyword links to the page itself, as expected.
Task-number: QTBUG-48482
Change-Id: I957551edd0eb7e665358d04b37dab41e2686b851
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
this feature was added with a dubious commit message a decade ago, was
undocumented, and there are no public traces of it being used.
if i had to guess what it was meant for: to be able to consistently use
-lfoo throughout a project and centrally (e.g., in .qmake.cache) choose
to use foo<bar> (bar possibly being "d") instead. however, more explicit
methods are being used instead, including in qt itself.
Change-Id: Ic3a98dc3aec59876f26909fbf9f7aba32baa05bf
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
"why not use libtool?" -- sam
"srsly dude?!" -- ossi
[ChangeLog][qmake] Support for CONFIG+=compile_libtool was removed. Use
CONFIG+=create_libtool and/or custom compilers instead.
in addition to its utter insanity and superfluousness, this feature was
apparently quite broken anyway (QTBUG-35745).
Change-Id: I8147a2953f5f065735ae3a2206cd5d33a7c1809a
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
this code would get enabled when *not* compiling with libtool, and would
try to use the real library in .libs/ when one tried to link the .la
file (i.e., it would reproduce libtool's functionality). that directory
structure is found only in build directories, so this code was
apparently meant to support mixed projects. that doesn't sound useful.
on top of that, the other code paths that were supposed to treat .la
files like .prl files were disabled before initial release (because
Somebody (TM) noticed that their code "doesn't behave well"). this code
here did the same thing, but at the wrong abstraction level.
as a side effect, this removes an infinite recursion problem in that
code.
Task-number: QTBUG-46910
Change-Id: If5291f5ff42c1412075c195753162c54598a250e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
there is no need to consider the "-framework foo" syntax, as we fully
control the list and insert elements exclusively as "-framework" "foo" a
few lines down.
Change-Id: I95fa8b46f53673ea3df1a67a2a44d11f7d679cc6
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
the code had a dead variable assignment and no side effects.
Change-Id: I9add8f1776f23a29c103b46dc725b9f386a4495a
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
each instance of the class is used only once.
Change-Id: I33e01537ee3a731c0f9758ec65c74938e4bec28c
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
it appears to have been some weird attempt at back-mapping file names to
-l arguments, which has been made ineffective with the partial #if 0.
i can't even describe what it did at this point.
Change-Id: Ie31cbbe7fab8b21b039bfff5877397af07731f1b
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
in retrospect, we were too conservative in 925fd32a2d making the
"feature" optional - it simply makes no sense to have qmake
automatically find the highest major (!) version of a library based on
a loosely defined platform-specific convention (not standard, unlike
ELF's .so versioning) with side effects.
Change-Id: Iba92df433b199a9fbff88358f6e0f6835f2e813d
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
the assumption is that if somebody bothers to actually specify a file
name, they'll most probably go all the way to specify the *correct* file
name. otherwise, they'll use -L/-l flags to specify the libs in a
cross-platform way and rely on qmake's magic.
this code was initially added for the purpose of invoking
findHighestVersion() under windows. this has been off by default for a
while now.
at some point, the code did also swap qt for qt-mt and vice versa if the
specified one was missing. this is obviously gone for a while as well.
the unix code was pretty much broken since day one: there was a regex
match on lib<stub>.* against <stub> itself, which obviously could not
have ever succeeded. consequently, the subsequent code ran into a path
that tried the file name with a trailing dot (instead of a new
extension), which never produced anything meaningful.
[ChangeLog][qmake][Important Behavior Changes] The library lookup has
been simplified. It may be necessary to be more explicit in some edge
cases now.
Change-Id: I5804943f1f7a16d38932b31675caabbda33eada7
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
make sure that all specs define QMAKE_{PREFIX,EXTENSION}_{SH,STATIC}LIB,
and adjust the code to make halfways consistent use of these variables,
in particular on windows; Win32MakefileGenerator::getLibTarget() is gone
as a result, as is QMAKE_CYGWIN_SHLIB. still, tons of hardcoded "lib"
references remain in the unix generator, because no-one cares.
Change-Id: I6ccf37cc562f6584221c94fa27b2834412e4e4ca
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
it would cause the unix generator to set TARGET_EXT, but that wasn't
used anywhere. so remove the dead code. if it ever gets re-introduced,
it will be as QMAKE_EXTENSION_EXE.
Change-Id: I44ce3e612651fd229177e37ab6c8879cd8c474b7
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
it was used only once, and virtual for no reason whatsoever.
Change-Id: I99411be3dac93d8a129441f656b2443d09108564
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
rvct and armcc support are remnants from symbian, while the ti linker
support was never completed in the first place.
Change-Id: I5c9d7f0ce67de24c348cbee4af618a499fe06f16
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
there is no reason to expect the various list elements to be
space-encumbered, or to tolerate it if they were.
Change-Id: I1a2e5c8d30456b640408503334c55f9262792db5
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
there should be no flags other than /LIBPATH: in LIBS (and the variables
that end up in it) - these belong into QMAKE_LFLAGS.
while not very important, this change enables the use of drive-relative
paths using unix path separators.
note that on unix, arbitrary flags must be supported in LIBS due to GNU
ld's --push-state and related position-dependent flags (-whole-archive
in particular). luckily, on unix, flags start with a dash, not a slash.
Started-by: Dyami Caliri <dyami@dragonframe.com>
Change-Id: Ie5764f14d34ad13020ca010499594eed8c69a4a1
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
On OS X with a framework-based build of Qt, the 'Libs:' line of the
.pc files generated by `qmake` references the framework. This requires
two separate arguments to the linker: The fixed string '-framework' and
the name of the framework (e.g. 'QtCore'). Only the latter might need
quoting. Prior to this fix, they were treated as a single argument (e.g.
'-framework QtCore'), thus always quoted because of the contained space,
and later lead to errors when trying to link a Qt framework discovered
via `pkg-config`.
Change-Id: I5c11ee651048832007e2ee4ebcbcf2e3212c8f48
Task-number: QTBUG-47162
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Consider a debug_and_release build of a static library.
Set DESTDIR to different values for debug/release.
Let TARGET be the same for debug/release.
Now qmake would generate code in Unix Makefiles like this:
rm mylib.a
ar mylib.a ...objects...
rm debug/mylib.a
mv mylib.a debug/mylib.a
and for release analogous. This clashes when building in parallel.
This patch resolves this conflict by reducing the commands to:
rm debug/mylib.a
ar debug/mylib.a ...objects...
We believe that every ar implementation that's in use for Qt
is able to operate on files in subdirectories.
[ChangeLog][Important Behavior Changes][qmake][Unix] QMAKE_POST_LINK
steps of static libraries are now required to operate on $(TARGET) in
$(DESTDIR) instead of $$OUT_PWD. This matches the Windows backends.
Task-number: QTBUG-48287
Change-Id: I192f488ed74c56bc32862426d9e9d4237d9b8135
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Set defaults before parsing compiler options.
UsePrecompiledHeader, CompileAsWinRT and GenerateWindowsMetadata
options were overwritten after parsing the options.
Task-number: QTBUG-46978
Change-Id: I8c4e423cd13f575fa679b114108b693937908549
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
$ORIGIN (or $LIB) needs to be escaped to survive the trip through
make and the shell.
this shouldn't break anything, as there was simply no way to get it
right so far.
Change-Id: I86337c5994d10dae2e80dd2f858f74874b14bca7
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
While generating Visual Studio 2015 solution files for a project using
the subdirs template qmake writes out both the header for version 2015
and version 2013. The problem is a case fall-through.
Task-number: QTBUG-48110
Change-Id: Ib6ddc1ceb306be9b3098d7b7c66a8ffabbd86481
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Valid characters are (A-Z,a-z,0-9,-,.).
It is unlikely that we will see anything more exotic
than '_' in bundle/library names, go ahead and replace
that character only.
Task-number: QTBUG-46824
Change-Id: Ia97b7cd6247f40a970b4919363ffb66fb347186c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
unlike everywhere else in this file, destdir is not pre-quoted here.
Task-number: QTBUG-47775
Change-Id: Ia5b0c56bbdd3eb095f81b0f615d68a338ffa52c5
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
- ApplicationTypeRevision has been updated to 10.0 in the final VS2015
release
- For Universal App project one needs to specify
WindowsTargetPlatformVersion and WindowsTargetPlatformMinVersion
- Disable adding Qt libraries to the DeploymentFiles variable for
Universal Apps. Before an error occurred during build as windeployqt
asked to package the very same files. However, windeployqt also takes
care of plugins and hence we prefer to rely on windeployqt and disable
the link step parsing.
Change-Id: I5180519cabde60dbc7786ef27a6fbe0ef2ac44f3
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
The SDK Version has been updated, hence include and lib directories were
wrong. Luckily, Microsoft introduced an environment variable in the
final VS2015 release to identify the location. Also has the benefit to
reduce hardcoded paths.
Change-Id: I9726db031d87d119bc7326154b24554c4b685d57
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
Reviewed-by: Mika Lindqvist <postmaster@raasu.org>
Instead of going to qmake to generate the makefile that we want, we write
the makefile directly and include it from the generated makefile. This
leaves us with a single top level makefile for handling exclusive builds
through xcodebuild, and covers all the various build configurations in
a unified manner. It also allows for improved test device handling.
Change-Id: I66851f181ac4da2c8938645e0aa95ffa0fee33c7
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Add a link to the topic that lists all Qt modules with links to
their documentation.
Change-Id: I0f488ea8c2f3479c7bace6ffbdbb7a70324c1649
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
SDKs generated from VS2013 use a different folder for
build settings than those generated from VS2012.
Check both folders, before rejecting a potential
SDK.
Change-Id: I5bee5cc3771352adaab07d39ebbc350618f6c573
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
... by marking the ctors (if any) explicit and the
function-call operator const.
Change-Id: Ia65fbad0dfdccbb31d630a5501c4d6f0f5aa3623
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>