| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
ARGV# could be defined from a parent scope.
|
| |
|
| |
|
|
|
|
|
|
| |
The matches have already been calculated and can simply be taken from
CMAKE_MATCH_n variables. This avoids multiple compilations of the same or very
similar regular expressions.
|
|\
| |
| |
| |
| | |
7beba986 Qt4Macros: Make QT4_CREATE_MOC_COMMAND a function
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QT4_CREATE_MOC_COMMAND is given a moc_flags argument that contains the
COMPILE_DEFINITIONS and a potentially large list of include directories.
Since it is a macro, the ${moc_flags} reference is replaced with this
content and sent through cmMakefile::ExpandVariablesInString (EVIS).
Since commit v3.0.0-rc1~138^2 (Qt4: Use generator expression in
COMPILE_DEFINITIONS, 2014-01-13) the COMPILE_DEFINITIONS value contains
a '$' so the EVIS fast-path is no longer used. Instead the full
cmCommandArgumentParserHelper is now used on the large input, which is
very slow (since it was originally created for hand-written code).
Change QT4_CREATE_MOC_COMMAND to a function instead of a macro to avoid
passing large content through EVIS. This makes it significantly faster.
|
|/
|
|
|
|
|
|
|
|
|
|
|
| |
Since commit v2.8.12~327^2 (Qt4Macros: Allow specifying a TARGET
in invokations of macros., 2013-02-26), a parameters file is
populated with moc arguments at generate-time.
When the compile definitions or include directories change, the
parameters file is updated but moc is not re-run in response.
Fix that by making the moc invocation depend on the parameters file.
Reported-At: https://bugreports.qt-project.org/browse/QTBUG-36970
|
|
|
|
|
|
| |
Commit v3.0.0-rc1~71^2~9 (Qt4: Use IMPORTED executable names with
custom commands., 2014-01-24) erroneusly changed this command to
use the wrong target.
|
|
|
|
|
|
| |
Finding Qt 5 can overwrite the QT_MOC_EXECUTABLE variable with the
moc from Qt 5. Use the IMPORTED target with the explicit version in
the name to avoid that.
|
| |
|
|
|
|
|
| |
-use one line for each input file and include directory
-remove duplicate include directories
|
|
|
|
|
|
|
|
| |
Run the convert-help.bash script to convert documentation:
./convert-help.bash "/path/to/CMake-build/bin"
Then remove it.
|
| |
|
| |
|
|
|
|
|
| |
This may have been added in anticipation of processing COMPILE_OPTIONS,
but as moc does not accept them, there is no need for it.
|
| |
|
|
|
|
|
| |
The QT_QMAKE_EXECUTABLE has to be passed through the cmake calls because
the executable may not be in the PATH.
|
|\
| |
| |
| |
| | |
9ce60ff Qt4Macros: Allow specifying a TARGET in invokations of macros.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
That will allow things like this:
find_package(Qt4)
qt4_generate_moc(myfile.h moc_myfile.cpp TARGET foo) # Note, foo target doesn't
# exist until below.
add_library(foo ...)
The qt4_generate_moc call would use the INCLUDE_DIRECTORIES from
the foo target using generator expressions. Currently it reads
the INCLUDE_DIRECTORIES directory property, meaning that include_directories()
is required.
Support for the TARGET is also added to qt4_wrap_cpp, but not qt4_automoc,
as that is deprecated in favor of the AUTOMOC target property.
The moc tool reports failure if the Q_INTERFACES macro is used with
an argument which has not appeared with Q_DECLARE_INTERFACE, so that is
the basis of the unit test.
The command line arguments are now always written to a file, which is
passed to moc as the @atfile. This was already the case on Windows, but
now it is used everywhere. The reason for that is that it is not currently
possible to expand the list of includes from a target directly in
a add_custom_command invokation (though that may become possible in the
future). There is not a big disadvantage to using the file anyway on
unix, so having one code path instead of two is also a motivation.
|
|/
|
|
| |
These libraries have non-conventional variable names.
|
|\
| |
| |
| |
| | |
42bfc5a Read entire Qt4 qrc file when parsing for depends info.
|
| |
| |
| |
| |
| | |
The qrc file is an xml file, not line based, so the entire 'interesting'
content to parse is not necessarily found by STRINGS and a regexp.
|
|\ \
| |/
| |
| |
| | |
3553001 Qt4Macros: Fix recently broken resource file parsing
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Commit 4be67837 (read less from version headers into variables,
2012-08-19) switched from file(READ) and string(REGEX MATCHALL) to just
file(STRINGS) to extract the list of resource <file> entries. However,
the latter extracts entire lines that match the regex, not just the part
that matches the regex, so the subsequent string(REGEX REPLACE) fails to
match and replace anything. Return to the original parsing logic but
replace file(READ) with file(STRINGS) to load a minimal part of the file
before using string(REGEX MATCHALL) as before.
|
|\ \
| |/
|/|
| |
| | |
1420691 Add new qt4_use_modules function.
|
| | |
|
|/
|
|
|
|
|
|
|
| |
Instead of reading the whole file using file(READ) and later matching on the
whole file use file(STRINGS ... REGEX) to get only those lines we are
interested in at all. This will make the list much smaller (good for debugging)
and also the regular expressions will need to match on much smaller strings.
Also unset the content variables once they are not used anymore.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ancient versions of CMake required else(), endif(), and similar block
termination commands to have arguments matching the command starting the
block. This is no longer the preferred style.
Run the following shell code:
for c in else endif endforeach endfunction endmacro endwhile; do
echo 's/\b'"$c"'\(\s*\)(.\+)/'"$c"'\1()/'
done >convert.sed &&
git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' |
egrep -z -v '^(Utilities/cm|Source/kwsys/)' |
egrep -z -v 'Tests/CMakeTests/While-Endwhile-' |
xargs -0 sed -i -f convert.sed &&
rm convert.sed
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ancient CMake versions required upper-case commands. Later command
names became case-insensitive. Now the preferred style is lower-case.
Run the following shell code:
cmake --help-command-list |
grep -v "cmake version" |
while read c; do
echo 's/\b'"$(echo $c | tr '[:lower:]' '[:upper:]')"'\(\s*\)(/'"$c"'\1(/g'
done >convert.sed &&
git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' |
egrep -z -v '^(Utilities/cm|Source/kwsys/)' |
xargs -0 sed -i -f convert.sed &&
rm convert.sed
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Our Git commit hooks disallow modification or addition of lines with
trailing whitespace. Wipe out all remnants of trailing whitespace
everywhere except third-party code.
Run the following shell code:
git ls-files -z -- \
bootstrap doxygen.config '*.readme' \
'*.c' '*.cmake' '*.cpp' '*.cxx' \
'*.el' '*.f' '*.f90' '*.h' '*.in' '*.in.l' '*.java' \
'*.mm' '*.pike' '*.py' '*.txt' '*.vim' |
egrep -z -v '^(Utilities/cm|Source/(kwsys|CursesDialog/form)/)' |
egrep -z -v '^(Modules/CPack\..*\.in)' |
xargs -0 sed -i 's/ \+$//'
|
| |
|
|
|
|
|
|
| |
-convert the filename to lowercase before the extraction, this allows this to
work even if the filename as uppercase ".XML" extension
-use get_filename_component(... NAME) to strip the path
|
|
|
|
|
|
|
|
|
|
| |
Using the QT4_ADD_RESOURCES() macro required the resource file to exist
already for dependency scanning. This prevented the use of resource
files that are generated by cmake because it needs the file before
resolving the dependency. This patch adds support for generated
resource files by not scanning the resource file for dependencies if it
doesn't exist yet. The add_custom_command() to generate the resource
file should add the dependencies on the files used by the resource file.
|
|
|
|
|
| |
Fixes bug #12644.
Thanks Bernd Lörwald for partial patch.
|
|
|
|
|
|
|
|
| |
Adding VERBATIM to the ADD_CUSTOM_COMMAND calls in the qt4 macros
ensures that paths are properly quoted when passed to the shell.
This fixes issues when building projects that contained paths with
special characters (according to /bin/sh), such as parentheses or
spaces.
|
| |
|
|
|
|
| |
Thanks A. Saratow for patch.
|
| |
|
|\
| |
| |
| |
| | |
35b91ac Fix regex for moc includes when looking for frameworks.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| | |
Fix bug 11120. Parameters files previously went into source
directory when qt4_generate_moc() was given relative paths.
Also simplified some logic for absolute paths.
|
|/ |
|
|
|
|
| |
This reverts commit 108090fde96916ba666f035d1e260f036af5b31e.
|
| |
|
|
automatically.
Qt4Macros.cmake: all the "public" macros of FindQt4.cmake
Qt4ConfigDependentSettings.cmake: the code for detecting the
Qt-configuration dependent additional libraries, e.g. when linking statically.
There should be no functional changes in this patch.
The patch reduces the length of FindQt4.cmake from 1700 lines to around 1000
lines, which is still long enough, but this should make the file a easier to
handle (and it is similar to what we do in KDE with FindKDE4Internal.cmake
and KDE4Macros.cmake)
Ok by Clinton.
Alex
|