Commit Graph

149 Commits

Author SHA1 Message Date
Joerg Bornemann
f9ebe26aae support include paths for the Windows resource compiler
In RC_INCLUDEPATH one can add include paths for the Windows resource
compiler.

Task-number: QTBUG-13776

Change-Id: If1d9ed44097adb7789df03e4ccd4e3b7df9e8d08
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-12-10 10:17:25 +01:00
Joerg Bornemann
e23e224498 qmake: fix extra compilers in vcxprojs for single config mode
In single config mode extra compilers were not written to Visual
Studio project files, because they were not added to the fake project
object we're using to write a single config project.

Task-number: QTBUG-27505

Change-Id: Ie57b648861573496252f1383dc77e0729e244947
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-12-10 10:17:17 +01:00
Joerg Bornemann
a79b898299 qmake: add ProductVersion to automatically generated resource
ProductVersion is set to the same value as FileVersion.

Task-number: QTBUG-27428

Change-Id: Ia01e14112d3a0e74b9fbe5fc8d9c4f9ae690db34
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-12-06 16:46:03 +01:00
Joerg Bornemann
b4b02fe876 MSVC: don't use the variable name LINK in generated makefiles
Rename LINK to LINKER. The MSVC linker uses the environment
variable LINK to pass additional command line arguments.
We must not hide this variable.

Task-number: QTBUG-28332

Change-Id: Id78476d1cf4a73175b9f47292c67f38a43ae5ba4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-12-06 14:46:13 +01:00
Miikka Heikkinen
d31dbe1efe Remove duplicate libraries added via prl files in Windows
The LIBS statement generated into Makefiles contained duplicate
libraries when application was linking static libraries.

Fixed by adapting the logic from unixmake.cpp's version of
processPrlFiles() to remove duplicates.

Change-Id: I12e152900233d0376b7d7ac6cd18a92850a6d640
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-11-30 08:22:35 +01:00
Kai Koehne
36270e4505 MinGW: Don't add version number '0' to the library name
This fixes linking on MinGW after the library renaming, and is also
in line with the logic in the nmake generator.

Change-Id: Ie25ce6c1d2b8f292c4e454db1cad9bcbbee7a05d
Suggested-by: Erik van Pienbroek
Task-number: QTBUG-27137
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-11-19 13:35:27 +01:00
Thiago Macieira
565b6bd635 Make it possible to suppress the automatic version number in DLLs
qmake automatically appends the library's major version number to the
DLL file name on Windows, as DLL naming doesn't include the version
number on a suffix like on Unix systems.

This flag makes it so qmake skips adding. This will allow us to insert
Qt's major version number at a different position.

Change-Id: I25d471038841fb0c5a34ef6b3bd6266aa33cebd1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-11-06 23:52:47 +01:00
Joerg Bornemann
ec5ce61b4a qmake: fix reversed defines in vcxproj files
Change-Id: I9fbb4b563428bb23974d59050f4c71e8d1983ff3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-10-13 05:51:19 +02:00
J-P Nurmi
3c05a0f3e7 qmake: fix .pc install target dir separators on windows
Task-number: QTBUG-26455
Change-Id: I578345b1676d0d2e812e0ab2e48468b4a8013ee9
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-10-10 08:45:22 +02:00
Andreas Holzammer
7ba31ff5a4 Fail when Windows CE SDK not found
Add failing when crosscompile for Windows CE
and no matching SDK is found.

Change-Id: I359e792fe46bab46729788666679a16cb94f340e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-09-27 06:07:29 +02:00
Andy Shaw
bad1384102 Bring subproject dependencies in line with Makefile generators
When generating the solution file it should extract the
dependencies from the pro file as this will bring it in
line with the Makefile generators.

Task-number: QTBUG-22561
Change-Id: I8d5b6607712f2c77c87ef093480e64b9633817d8
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-27 06:07:19 +02:00
Joerg Bornemann
9e9911715c qmake: fix overescaped defines in vcxproj files
Task-number: QTBUG-27345

Change-Id: I00848d611163afb549191f41adff628622a899e0
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-26 19:12:31 +02:00
Kai Koehne
7ec788705f qmake: Fix gcc warning about anonymous type linkage
Fix "warning: anonymous type with no linkage used to declare variable
'<anonymous struct> dotNetCombo []' with linkage".

Change-Id: Iaff0d460df53fd6d0732d39bf633688805f5c653
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-09-26 10:08:59 +02:00
Joerg Bornemann
461a01c1df qmake: support for Visual Studio 2012 project files added
The differences to VS 2010 project files are the
version number (surprise!) and the PlatformToolSet tag which
sets the version of the toolchain.

Change-Id: If26f08fad1a69d7e6cd28cc5e860ff964f19b264
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-25 07:26:37 +02:00
Iikka Eklund
be15856f61 Change copyrights from Nokia to Digia
Change copyrights and license headers from Nokia to Digia

Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
2012-09-22 19:20:11 +02:00
Marc Mutz
f4d47945ba Use QStringList::join(QChar) overload where applicable [qmake]
This is an automated change performing the following replacements:
                    join\("(.)"\) -> join('\1')
  join\(QLatin1String\("(.)"\)\)  -> join(QLatin1Char('\1'))
  join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))

Change-Id: I9c9964703dedfdab6e7bfac80be22bd5570e2e49
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-09-21 02:44:22 +02:00
Oswald Buddenhagen
1b569fe455 fix QMAKE_MANIFEST for shadow builds
Change-Id: Iea71f4a4d483e9465b3a7f0ce4560b2e9fa6cd63
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-18 00:59:08 +02:00
Oswald Buddenhagen
53ab67cdfe properly C-quote the manifest file name in the rc file
Change-Id: I8c8eb85d412becc8c4029c2aa393abf6f8e949b6
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-18 00:59:08 +02:00
Oswald Buddenhagen
d113faefb8 rewrite *_manifest.rc unconditionally
the file has no dependency tracking, so changes to the source would get
missed and cause hard to debug build issues.
and as nothing does dependency tracking on that file, this change
doesn't even cause a noticable performance regression.

Change-Id: I108b490b71a43018e0c7ef5d7c0b11d79a8e726b
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2012-09-18 00:59:08 +02:00
Sergio Ahumada
89b12da2ef qmake: Include own header first
cpp files should include their own headers first (but below config.h)

Change-Id: I10ef37854843ae6438d68f96ce5ee83eede33db5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2012-09-17 22:14:18 +02:00
Oswald Buddenhagen
8df98b43be compile without CamelCase headers
for faster bootstrapping without a full syncqt run

Change-Id: I648f0a8fb09be021590c46e8e5e15667a316c817
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-11 17:23:23 +02:00
Oswald Buddenhagen
0e78e50802 port qmake to qt creator's qmake language evaluator
this is a monster commit which does the following things:
- import the evaluator as-is from qt creator into qmake/library/
  - integrate it into qmake's makefiles
  - overwrite proitems.h with actual special types
- remove the parts of Option which are redundant with QMakeGlobals
- make QMakeProperty a singleton owned by Option::globals. the dynamic
  handling so far made no sense.
- make QMakeProject a subclass of QMakeEvaluator, with relatively few
  extensions

the changes to existing qmake code outside project.* and option.* are
minor. implementing the changes gradually would mean changing a lot of
code which will be just replaced in the next commit, so i'm not wasting
my time on it.

Change-Id: I9746650423b8c5b3fbd8c3979a73228982a46195
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-11 00:13:01 +02:00
Simon Hausmann
0c0c04b405 Fix semantics of the src dir in the include search paths with MinGW
This issue originates from https://bugs.webkit.org/show_bug.cgi?id=95736

Suppose we have
    main.cpp
    somedirectory/someheader.h -- which has #include "anotherheader.h"
    anotherheader.h

With unix generator, the directory where main.cpp is located is included,
unless no_include_pwd is set. Hence the look-up of anotherheader.h from
within someheader.h will work.

With MSVC this works because MSVC looks "in the directories of any
previously opened include files in the reverse order in which they were
opened." (from http://msdn.microsoft.com/en-us/library/36k2cdd4.aspx)

Unfortunately the build breaks with MinGW, because it lacks support for
including the source directory in the include search path just like the
unix generator does.

This patch adds the same functionality to the MinGW generator as well as
an auto-test.

Change-Id: Iea8bb06e34862c51b8fd4eca2ee26668e24a319a
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
Reviewed-by: Jonathan Liu <net147@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-09-10 14:09:45 +02:00
Oswald Buddenhagen
df175f190d introduce qmake variable abstractions
this is preparation for adapting to a new evaluator.

Change-Id: I6fc59f5525735754a00afa6629fbfe257e84db97
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-07 15:39:31 +02:00
Oswald Buddenhagen
791cb02463 make QMakeMetaInfo a little less inefficient with libtool .la files
don't read the spec from scratch for every library just to get
QMAKE_LFLAGS_RPATH. we can perfectly use our current project for that
purpose.

Change-Id: I4e408b3fd5de81652181df032aa53cd8f2f8f806
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-05 03:03:10 +02:00
Oswald Buddenhagen
6efec23b10 remove handling of QMAKE_FILETAGS
it was unused for a decade. and broken, of course.

Change-Id: I9713d595d95c5b074ef96dfe9b1c314b9198bd7e
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-03 19:39:02 +02:00
Oswald Buddenhagen
b2d574e83f remove unnecessary QMAKESPEC fallback code
QMAKESPEC is now always set

Change-Id: Ib3f7356a9260d42315747095e28db6604b2dcfe9
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-03 19:38:58 +02:00
Oswald Buddenhagen
aeebe1db79 fix assignment of MSVCPROJ_TARGET
i'm only guessing what was intended here.

Change-Id: I72bfa3b5fad63f5b144d34762152e4dd851197ac
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-09-03 19:36:03 +02:00
Oswald Buddenhagen
996bbcd78b micro-optimize: use POD-initializable lists of variable names
Change-Id: I3732fef509b358949ef90002dbfc1960360afef8
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
2012-08-28 20:48:07 +02:00
Oswald Buddenhagen
7033560e54 remove dead variable assignments
Change-Id: I032e9116ca1b7250497f56ea26103f2173f0fc09
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-28 20:47:55 +02:00
Joerg Bornemann
8633f7ac0d qmake: fix manifest resource for non-trivial target names
The Microsoft Resource Compiler bails out if the rc file contains
non-trivial file name references. In particular it doesn't like
dashes in file names. We're now always quoting the file name.

Change-Id: I67b8d2c13010a0b2ec26cac915ebd1be95f1c274
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-23 15:54:02 +02:00
Joerg Bornemann
d45ef22158 qmake: fix embedding of generated manifests in debug mode
The existence of the manifest backup is used as a marker to decide
whether to embed the manifest in a second link step or not.
If it's present, the embedding took place in the first link step.
If it's not present, we must link again incrementally.
That logic was implemented faulty.

Change-Id: I10154dbbbe70c7981795ac66d46a166907ba13ec
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-22 18:40:17 +02:00
Joerg Bornemann
0330798037 qmake: fix generated rc file for embedding manifests
The rc file is in the same directory as the manifest file.
Therefore the include must consist of the filename and must not include
the file's path.

Change-Id: I4f5ac11b131f39ea8c425aca93fcf82d150c0204
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-22 18:40:17 +02:00
Oswald Buddenhagen
af2847260c unbreak "aux" template for mingw & msvc
we cannot just completely stub it out, as then there are no dependencies
on whatever targets we actually *want* to be built.

Change-Id: I32a92fa937d099c153a0082feae5d23e3998ba48
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-08-17 12:27:05 +02:00
Joerg Bornemann
c9406bcffe qmake: support incremental linking when embedding manifests
When embedding manifests we modified the EXE/DLL after linking using
the manifest tool. This breaks the incremental linking feature of MSVC.

The MS way to embed a manifest without breaking incremental linking is:
   - let the linker create the manifest file,
   - create a resource that contains the manifest file,
   - invoke the linker again to embed the resource.

The embed_manifest_{exe|dll}.prf files have been removed.
All manifest logic is now in qmake's nmake makefile generator.

With QMAKE_MANIFEST one can specify a custom manifest file that gets
embedded without disturbing incremental linking.

Task-number: QTBUG-22718
Change-Id: Idb9d2644a0577b2002cbdd2d62b695b9171b1bd5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-16 08:26:24 +02:00
Joerg Bornemann
e81d7fd1e5 qmake vcxproj generator: map TARGET_EXT to $(TargetExt)
Task-number: QTBUG-26782

Change-Id: Ib143fa6b8674c4d09d798a9301bb209b886e791d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-08-07 18:55:43 +02:00
Joerg Bornemann
b4ae57c881 qmake: un-copy-and-pastify vcxproj generator a bit
Reusing already built strings improves readability and performance.

Change-Id: I8555fb860561ff214ae123efeda78fc770b6459f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-07 18:55:43 +02:00
Andy Shaw
372cc6b506 Add the filters for extra compilers for vcxproj files
The files were grouped into the relevant filters but the filters
themselves were not added.  This now ensures the filters are added to the
vcxproj files so they appear grouped correctly.

Task-number: QTBUG-26755

Change-Id: I7d2c6fa96dcbb0496fd9d1bb1d01e7dd660052f4
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-08-07 18:55:43 +02:00
Andy Shaw
44a7330d67 Remove references to Borland and bmake
Remove references to an old compiler that has not been
supported for a long time.  Also remove Borland specific
configuration flags which have no meaning elsewhere.

Change-Id: I3634a52b78f737ea972073e14c2b6669dcd0ae63
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-08-01 12:39:39 +02:00
Oswald Buddenhagen
c595405124 run processPrlFiles() over QMAKE_LIBS_PRIVATE as well
there is no reason why private libs should not have prls resolved.

the two variables are resolved independently, so it's possible that
(even more) libraries will appear duplicated on the linker command line,
but that seems easiest for the time being.

Change-Id: I9070ba53808a0661fa72949db8111106b7aca487
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-31 11:17:43 +02:00
Oswald Buddenhagen
f71a5c8cde make the windows prl processing more like the unix variant
it's more elegant, and more similar code is better.

Change-Id: I2b8b036cb70a932fd171e23cf7d3389188401924
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-31 11:17:37 +02:00
Oswald Buddenhagen
202f08dc09 remove apparently useless code
it wouldn't actually *do* anything, as l is not a reference. i cannot
figure out the original intention, so let's just drop it.

Change-Id: Ic0a3457a1872cde827259ee5530959120456e934
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-31 11:17:34 +02:00
Oswald Buddenhagen
022f8ebd13 merge QMAKE_LIBDIR into QMAKE_LIBS early
dealing with the directories separately doesn't buy us anything. it's
easier to mix them into the libs, as that contains some paths, too, both
in projects and in prl files.

this brings the windows generators in line with the unix ones.

Change-Id: I1f58f7edd8e21d28bfabf04384bac2e315aaf446
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-27 16:29:38 +02:00
Oswald Buddenhagen
10fba42d71 unifiy initialization of QMAKE_LIBS{,_PRIVATE} among windows generators
Change-Id: Ib24ec6e290bfb277232c2483768c1b863f961462
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-27 16:29:34 +02:00
Oswald Buddenhagen
b053aaa9ef clean up fixTargetExt()
there doesn't appear to be a point in having the function virtual; the
part in the mingw generator can be inlined somewhere else just fine.

Change-Id: I50d66d505095b43fce601928c6240a684389a4b7
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-27 16:29:29 +02:00
Oswald Buddenhagen
a102f1abf2 de-virtualize some more functions
they are not re-implemented anywhere

Change-Id: I444a967bb39ec6b5994747c9fa3f605b4c53ce4f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-27 16:29:23 +02:00
Oswald Buddenhagen
1a470256e1 remove support for rvct_linker config from MinGW generator again
yet another symbian remnant (building windows arm executables for the
simulator).
This reverts commit 5c88141ed0b25d8ab9318bf4cb5dda54b90b2ce1.

Change-Id: I6eb147c0e2710eba09a4339fa4a08a5b08f8dab3
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-07-24 12:45:02 +02:00
Oswald Buddenhagen
8fa9249acc $$QMAKE_LIBDIR contents belong into $(LIBS), not $(LFLAGS)
unlike for the unix linker, this does not matter for the windows linker,
but keeping it consistent has advantages.

Change-Id: Ib9b9efa18c31d87c026d3cac5a8737f4612ad1c0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-07-24 12:45:02 +02:00
Oswald Buddenhagen
e5b203dbc7 dispose of MSVCPROJ_LIBS
this way QMAKE_LIBS{,_PRIVATE} can be treated the same as in all other
generators, which allows us to:
- make the windows generators' findLibraries() be more like the unix
  version
- dispose of QMAKE_INTERNAL_PRL_LIBS handling while reading prl files
  (because the output always goes to QMAKE_LIBS)
- as a side effect, QMAKE_LIBS_PRIVATE are not subjected to prl file
  resolution any more, which is again consistent with unix - the
  correctness of that needs to be assessed separately.

Change-Id: Ie9bc04d117eff6a7cde846677f98acf3c64aa6ee
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-07-24 12:45:02 +02:00
Oswald Buddenhagen
c1056c80fb remove apparently pointless call to findLibraries()
the function was already called long before. if it really needs to be
called again, it's a) probably affecting the other windows generators as
well and b) the actual problem should be fixed instead.

This reverts commit d50c3c6624b2343e42d0df4b72212d9ced8f3682.

Change-Id: Iaa2007640fbc9acdc50ba3b0681efeb0d184f224
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-07-24 12:45:02 +02:00
Oswald Buddenhagen
80749d946b use QT_INSTALL_LIBS directly instead of messing with QMAKE_LIBDIR
this is what this code assumes anyway

Change-Id: I667412b101c18325321a568cc22d25ef07418ffb
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-18 22:35:10 +02:00
Oswald Buddenhagen
a89bd2d2fb remove QTDLL_POSTFIX stuff
the libinfix provides a way cleaner solution to that. i don't expect it
to be still actually used anyway.

Change-Id: I051522ec3abb3d92c529b5462b8514a706aa2ba1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
2012-07-18 22:34:49 +02:00
Oswald Buddenhagen
9651738f2d automatically fix separators in QMAKE_{DIST,}CLEAN
it's a tad insane to expect the user to do that

Change-Id: I75c68f2a28656c9ba2e3fabcc79718b899b29ce7
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-07-16 01:06:51 +02:00
Bjoern Breitmeyer
e7b28bce3b fixed ce makefileenvironment
XQMakeSpec is not available after configure
but the QMakeSpec contains the correct value

Change-Id: I6cd4da8b0d6c95565f31842c17611ffd361bc010
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-07-06 13:58:21 +02:00
Oswald Buddenhagen
2b4ae9651f don't use a different de-duplication algo for the library list in mingw prl files
i have no idea why that was done (the commit message says "not sure why
it works elsewhere"), but it makes no sense whatsoever, specifically
doing it only on mingw. probably some workaround, as usual. the
de-duplication is broken by design anyway.

This reverts commit 7a6302c2baf6861fdaf65992b71a7676859860c2.

Change-Id: I6edecaa062570e59eccd24d50919ba132e65a403
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-07-05 21:10:40 +02:00
Joerg Bornemann
ee4f32acfa qmake: remove support for X.sources in DEPLOYMENT variables
This has been deprecated in Qt 4.8.0. Use X.files instead.

Task-number: QTBUG-3216
Task-number: QTBUG-25106

Change-Id: I581321591291118a13403e92da5997497e12c3fd
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-07-03 00:44:55 +02:00
Oswald Buddenhagen
a47c6e5ea0 dispose of Option::shellPath
use isWindowsShell() in the one remaining case.

Change-Id: I25eab398ef50df5a7f4ec808279b83ca900e3c58
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2012-06-27 14:35:32 +02:00
Oswald Buddenhagen
e18ceca47e assume windows shell iff dir separator is backslash
Change-Id: I411a4d6691e18b818ee7d1ced7f126f97af0902f
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2012-06-27 14:35:31 +02:00
Oswald Buddenhagen
104ee69216 purge "dumping all variables" debug loops
the as-we-go dump is sufficient (and usually necessary to actually find
the problem). if only the summary is interesting, the -E option can be
used now.

Change-Id: I9e34c6db9dcb99b38013c4d0cb80b8cb88ca36b5
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2012-06-27 14:35:31 +02:00
Oswald Buddenhagen
aac040b188 const correctness for variables()
Change-Id: Id11453ccbae3ffa32580badadada945d342d727a
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2012-06-27 14:35:30 +02:00
Oswald Buddenhagen
6957cb26b3 don't overuse variables()
Change-Id: Ib2da88e5e29c0bfecc39a9c06e82a34a4bd0b1e6
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-06-27 14:35:29 +02:00
Oswald Buddenhagen
f85292ab20 const correctness for values() calls
Change-Id: I1476ae8d3fb7364686398c5650729dee94a8e933
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
2012-06-27 14:35:29 +02:00
Bjoern Breitmeyer
00f9ac93c2 Fixed Wince Makefile environment
Integrated the checksdk tool into qmake and made
the makefiles selfcontained, so configure make, is now
enough to build qt for wince

Change-Id: I29076702eca2ec23d4d06bb3d5c5cef9d4f95161
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-06-19 16:46:09 +02:00
Oswald Buddenhagen
ab0d55e361 purge unused VcprojGenerator::findTemplate()
it looked fishy for years. now i know why. ;)

Change-Id: I822cadecaf8d914f383f9f907b92507852e434b4
2012-06-19 16:39:58 +02:00
Oswald Buddenhagen
14bbab09c1 introduce ability to build projects for the host system
when qmake runs into the new option(host_build) command, it will restart
the project evaluation with a host spec.

the new default host spec is called default-host (gasp!). it is
overridden with the pre-exising -spec / -platform option, while the new
-xspec / -xplatform option overrides the pre-existing default spec.
specifying -spec but not -xspec will set the xspec, too, so the behavior
is backwards-compatible. same for the XQMAKESPEC override read from
.qmake.cache and the environment variable.
the cleaner solution would be adding -hostspec, to be symmetrical with
the override semantics, but that would deviate from configure in turn.

Change-Id: I4297c873780af16ab7928421b434ce0f1d3820da
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-06-19 16:37:49 +02:00
Joerg Bornemann
ac7dd2782f qmake vc(x)proj generator: don't create bogus directories
When creating the temporary project object,
Option::output_dir must be adjusted temporarily.

Task-number: QTBUG-22788
Change-Id: Ibf8897a46b63f48b9e33d7e2168b09e559cecec7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-04-17 03:26:32 +02:00
Joerg Bornemann
8987e5d2cb qmake/Win: fix incomplete generated version resource
Since Windows Vista the resource language must be included to
make the version information visible in Windows Explorer.

Two new variables have been introduced:
RC_LANG (default: 1033) - resource language
RC_CODEPAGE (default: 1200) - resource codepage

Task-number: QTBUG-23218
Change-Id: I29e102d19501e3b7a43d5096fc4806bc38a4d846
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-04-17 03:26:32 +02:00
Joerg Bornemann
31cfe5ca1b qmake vcxproj generator: fix handling of /MANIFEST:NO linker option
Task-number: QTBUG-23513

Change-Id: I5dd6fb6fd7910e43acd28057133a3ad6613cfc1a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-04-17 03:26:32 +02:00
Joerg Bornemann
65425be8fe qmake vcproj generator: unused variable removed
Change-Id: Iaf8bb1772846001297e1a421c3860f5e4d090a35
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-04-17 03:26:32 +02:00
Joerg Bornemann
99a2074369 qmake vc(x)project generator: fix VC++ Express detection
If VC++ 2010 Express and VC# 2010 Express are installed, then the
installation path is written in two places into the registry.
We're now filtering detected installations with the same installation
path.

Task-number: QTBUG-24956

Change-Id: I401430e7aa81d96c523d8172d2a2e9d40ebdb3ce
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-04-12 04:15:05 +02:00
Yuchen Deng
c7f8f459bd Fix build all failed for 'TEMPLATE = aux'
NMAKE : fatal error U1073: don't know how to make 'all'
Stop.

Change-Id: I387a417d37e38811706a1ff460df8ee581c6a33f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-04-02 12:41:32 +02:00
Oswald Buddenhagen
2640b71be4 remove support for QMAKE_PLATFORM_DIR
this was a somewhat magic support for sysroots, automatically rewriting
a number of path-holding variables. this was (as usual) completely
undocumented, extremely fragile, and we are coming up with something
better now anyway.

Change-Id: I045910f532cb3efc839ea81c7a48f8db695e4092
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2012-03-08 23:52:34 +01:00
Max Desyatov
9d5e721e96 escape *_script_file usages in MingwMakefileGenerator::writeObjectsPart
Task-number: QTBUG-24595
Change-Id: I1e78a6015247b9e41ae2b05b50fdedf0613f00f1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-03-06 12:28:26 +01:00
Lars Knoll
96232be146 Merge remote-tracking branch 'origin/api_changes'
Conflicts:
	dist/changes-5.0.0
	mkspecs/features/qt_module_config.prf
	qmake/project.cpp
	qmake/property.cpp

Change-Id: I6e4af40743a9aeff8ed18533a48036e332acc296
2012-03-04 21:45:05 +01:00
Oswald Buddenhagen
012f799254 revamp -sysroot and -hostprefix handling
instead of being a variable added to the makespec (via qconfig.pri),
QT_SYSROOT is now a property.

the QT_INSTALL_... properties are now automatically prefixed with the
sysroot; the raw values are available as QT_RAW_INSTALL_... - this is
expected to cause the least migration effort for existing projects.

-hostprefix and the new -hostbindir & -hostdatadir now feed the new
QT_HOST_... properties.

adapted the qmake feature files and the qtbase build system accordingly.

Change-Id: Iaa9b65bc10d9fe9c4988d620c70a8ce72177f8d4
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-03-01 23:18:23 +01:00
Rohan McGovern
98dd1781d9 Merge master -> api_changes
Includes fixes for tst_qfiledialog2, tst_qtextedit autotests on mac.

Change-Id: I49cac26894d31291a8339ccc1eb80b6a940f0827
2012-02-29 09:23:14 +10:00
Hib Eris
78faefdbb1 Implement missing replacements when installing .pc files for win32
This implements replacements for win32 makefile generators similar
to the replacement functionality in unix makefile generators.

To enable Makefile code generation for replacements in win32 makefile
generators, you must set QMAKE_STREAM_EDITOR to e.g. sed.

When building for win32, sed is normally only available in the
mingw/msys build environment and when cross compiling on unix.
In these cases QMAKE_STREAM_EDITOR is set to sed in qmake.conf.

For other win32 build environments QMAKE_STREAM_EDITOR is not set
in qmake.conf and the replacements Makefile code is not generated.

Change-Id: Ie5de5d517eafaeaa2544f1e972aec3fe11d0a6f1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-02-29 00:05:38 +01:00
Marc Mutz
8397a44bed QByteArray: deprecate QT_NO_CAST_FROM_BYTEARRAY-protected operators
The QByteArray::operator const {char,void}*() implicit
conversions are a source of subtle bugs, so they right-
fully can be disabled with QT_NO_CAST_FROM_BYTEARRAY.

  const char *d = qstring.toLatin1(); // implicit conversion
  while ( d ) // oops: d points to freed memory
     // ...

But almost no-one ever enabled this macros in the wild
and many were bitten by these implicit conversions, so
this patch deprecates them.

I would have liked to remove them completely, but there
are just too many occurrences even in Qt itself to hope
to find all conditionally-compiled code that uses these.

Also fixes all code that needs to compile under
QT_NO_DEPRECATED (in qmake/, src/tools/).

I984706452db7d0841620a0f64e179906123f3849 separately
deals with the bulk of changes in src/ and examples/.

Depends on I5ea1ad3c96d9e64167be53c0c418c7b7dba51f68.

Change-Id: I8d47e6c293c80f61c6288c9f8d42fda41afe2267
Reviewed-by: David Faure <faure@kde.org>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-02-26 09:14:11 +01:00
Hib Eris
cbf8f03cf4 Create target pkgconfig dir in qmake generated Windows Makefiles
Change-Id: Icea70987ee3c6040ca3ba278a578849cb74156f4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-02-24 11:29:43 +01:00
Andreas Holzammer
e5830479d6 Escape Dependencies of precompiled header right.
Change-Id: I847c85250b78a934bd29e09250d209d9ef412f7f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-02-10 11:24:48 +01:00
Friedemann Kleint
9f54846d95 qmake: Work around MSVC compiler bug.
Disable optimization for getProjectUUID() as it triggers
ASSERT: "&other != this" at qstring.h:720 with -O2.

Change-Id: I51b31d4318ba9be187c186623099171d8f48235b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-02-05 19:03:18 +01:00
Jason McDonald
5635823e17 Remove "All rights reserved" line from license headers.
As in the past, to avoid rewriting various autotests that contain
line-number information, an extra blank line has been inserted at the
end of the license text to ensure that this commit does not change the
total number of lines in the license header.

Change-Id: I311e001373776812699d6efc045b5f742890c689
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-30 03:54:59 +01:00
Jason McDonald
629d6eda5c Update contact information in license headers.
Replace Nokia contact email address with Qt Project website.

Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-23 04:04:33 +01:00
Oswald Buddenhagen
3e4f7ed5ed QMap => QHash
this should make the evaluator quite a lot faster. the total win for
qtbase/src is only 6%, though.

i made some effort to avoid that output files get randomized. however, i
didn't bother to keep debug output sorted.

Change-Id: Id9cef4674c0153c11ebbb65cb63bf8c229eb56e3
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-01-10 16:16:34 +01:00
Joerg Bornemann
ece75a8adf qmake: fix default value for C++ optimization in vcxproj files
For the debug configuration the optimization should be turned off.

Task-number: QTBUG-23421

Change-Id: Ib63e0c51f9ab31180ff8ee01a1f6c57ab77e390e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-01-08 18:21:00 +01:00
Joerg Bornemann
c85121989f qmake: fix /MP option for VS 2010
Setting QMAKE_CFLAGS+=/MP in a project file did not work for VS 2010.

Task-number: QTBUG-23490

Change-Id: I39c349bf8dc2a4add2f32a430a245a20cc54147e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-01-08 18:20:54 +01:00
Friedemann Kleint
1ff1288c04 Make QUuid a class.
Silence MSVC warnings about forward-declarations as class
in the metatype system.

Change-Id: I676662e5919585e98c87413fd8360d6f41f73631
Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
2012-01-06 19:24:23 +01:00
Jason McDonald
1fdfc2abfe Update copyright year in license headers.
Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-01-05 06:36:56 +01:00
Bradley T. Hughes
7ae1e39455 Silence warnings from clang
Many enumerator values were not handled in msbuild_objectmodel.cpp. For
each unhandled value, add a case statement that simply breaks.

Change-Id: I018fc5e641200568c88ccc6acb3f5b6ee6b3fd6f
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2011-11-09 09:42:20 +01:00
Joerg Bornemann
981dd3b314 qmake: remove symbian support
Change-Id: I1db834500921681676a6f46e7750bdd81bf0093d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-11-07 13:26:41 +01:00
Friedemann Kleint
456236b8c8 qmake: vcproj ignores subdirs that do "no_default_target".
It's nicer to do:
    SUBDIRS += foo
    foo.CONFIG = no_default_target no_default_install
then to omit foo from SUBDIRS because a Makefile is still produced
but "make" and "make install" don't descend automatically.

The vcproj generator doesn't know about this. This patch gets it to
check for no_default_target and then it simply ignores the directory.

Change-Id: I127bea79143c101612afb0e9c6603d3b065c7c56
Reviewed-by: Oliver Wolff <oliver.wolff@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2011-11-04 17:46:49 +01:00
Joerg Bornemann
d1ff829072 qmake: fix incrementalLinker option writing for vcxproj
Change-Id: I7d3b33a3a2e2f7c89ea956cd1304e7d2e365151f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-10-14 19:42:32 +02:00
Joerg Bornemann
13908a560b qmake vcxproj generator: fix XML conversion for build events
Task-number: QTBUG-20419

Change-Id: I52069e0beb2b39ec4a67e83de583efd2926c6611
Reviewed-on: http://codereview.qt-project.org/4484
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
2011-09-08 19:50:28 +02:00
Jyri Tahtela
f9f395c28b Update licenseheader text in source files for qtbase Qt module
Updated version of LGPL and FDL licenseheaders.
Apply release phase licenseheaders for all source files.

Reviewed-by: Trust Me
2011-05-24 12:34:08 +03:00
Christian Kandeler
bc88f528dc qmake: Introduce new template type
The template type "aux" is intended for projects that do not require building anything, but may need to install stuff (e.g. applications with QML entry point).

Reviewed-by: Joerg Bornemann
(cherry picked from commit 56443421cb5e537e60abd7ced42c9ebf587683fe)
2011-05-10 12:54:55 +02:00
Joerg Bornemann
61e6639c82 qmake vc(x)proj generator: support x64 Qt builds
Task-number: QTBUG-17911
Reviewed-by: ossi
2011-05-06 11:50:15 +02:00
Joerg Bornemann
c6fc5395ad qmake: remove dead code from VcxprojGenerator
Reviewed-by: ossi
2011-05-06 11:50:03 +02:00
Joerg Bornemann
c04b7a55d1 qmake nmake generator: pass MAKEFLAGS to sub-make calls
Unlike other make tools nmake doesn't do this automatically.

Reviewed-by: ossi
2011-05-03 13:31:12 +02:00
Qt by Nokia
38be0d1383 Initial import from the monolithic Qt.
This is the beginning of revision history for this module. If you
want to look at revision history older than this, please refer to the
Qt Git wiki for how to use Git history grafting. At the time of
writing, this wiki is located here:

http://qt.gitorious.org/qt/pages/GitIntroductionWithQt

If you have already performed the grafting and you don't see any
history beyond this commit, try running "git log" with the "--follow"
argument.

Branched from the monolithic repo, Qt master branch, at commit
896db169ea224deb96c59ce8af800d019de63f12
2011-04-27 12:05:43 +02:00