QtAutogen: Add source files to target when only AUTORCC is used.

Add missing entry to if condition.
This commit is contained in:
Stephen Kelly 2014-09-10 16:20:43 +02:00
parent 71a11252e9
commit b8877b1d62
3 changed files with 14 additions and 1 deletions

View File

@ -392,7 +392,8 @@ void cmQtAutoGenerators::SetupAutoGenerateTarget(cmTarget const* target)
std::map<std::string, std::string> configUicOptions;
if (target->GetPropertyAsBool("AUTOMOC")
|| target->GetPropertyAsBool("AUTOUIC"))
|| target->GetPropertyAsBool("AUTOUIC")
|| target->GetPropertyAsBool("AUTORCC"))
{
this->SetupSourceFiles(target);
}

View File

@ -37,6 +37,9 @@ else()
endif()
add_executable(rcconly rcconly.cpp second_resource.qrc)
set_property(TARGET rcconly PROPERTY AUTORCC ON)
target_link_libraries(rcconly ${QT_QTCORE_TARGET})
include_directories(${CMAKE_CURRENT_BINARY_DIR})

View File

@ -0,0 +1,9 @@
extern int qInitResources_second_resource();
int main(int, char**)
{
// Fails to link if the symbol is not present.
qInitResources_second_resource();
return 0;
}